Fix Groonga crash on MIPS: Correctly link to libatomic

MIPS (and possibly other) platforms require linking against libatomic to
support 64-bit atomic integers. Groonga was failing to do so and all related
tests were failing with an atomics relocation error on MIPS.

Contributors:
James Cowgill <jcowgill@debian.org>
This commit is contained in:
Vicențiu Ciorbaru 2021-10-19 19:20:23 +03:00
parent a33c1082da
commit 1388845e04

View File

@ -89,7 +89,12 @@ else()
endif()
set_target_properties(libgroonga PROPERTIES OUTPUT_NAME "groonga")
if (HAVE_GCC_C11_ATOMICS_WITH_LIBATOMIC)
set(ATOMIC_LIBS atomic)
endif()
set(GRN_ALL_LIBRARIES
${ATOMIC_LIBS}
${EXECINFO_LIBS}
${RT_LIBS}
${PTHREAD_LIBS}