Skip to content

Commit

Permalink
nix-util / meson: Add -latomic on arm
Browse files Browse the repository at this point in the history
I couldn't get the test program to work correctly after many attempts,
so let's just unblock this without making it perfect.
  • Loading branch information
roberth committed Sep 18, 2024
1 parent 59acf3b commit 56b8911
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/libutil/meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,14 @@ endforeach

subdir('build-utils-meson/threads')

# Check if -latomic is needed
# This is needed for std::atomic on some platforms
# We did not manage to test this reliably on all platforms, so we hardcode
# it for now.
if host_machine.cpu_family() == 'arm'
deps_other += cxx.find_library('atomic')
endif

if host_machine.system() == 'windows'
socket = cxx.find_library('ws2_32')
deps_other += socket
Expand Down

0 comments on commit 56b8911

Please sign in to comment.