build: Fix build on macOS

macOS does not have librt.

Signed-off-by: Mohamed Akram <mohd.akram@outlook.com>
This commit is contained in:
Mohamed Akram 2025-05-07 15:09:55 +04:00 committed by Frediano Ziglio
parent b0374ff7da
commit 4f659065b3
2 changed files with 2 additions and 1 deletions

View File

@ -94,5 +94,6 @@ Patches also contributed by
Michael Scherle <michael.scherle@rz.uni-freiburg.de>
Weishi Li <liweishi@kylinos.cn>
Qiang Yu <yuq825@gmail.com>
Mohamed Akram <mohd.akram@outlook.com>
....send patches to get your name here...

View File

@ -108,7 +108,7 @@ endforeach
if host_machine.system() != 'windows'
foreach dep : ['rt', 'm']
spice_server_deps += compiler.find_library(dep)
spice_server_deps += compiler.find_library(dep, required: false)
endforeach
else
foreach dep : ['ws2_32', 'shlwapi']