Skip to content

Commit

Permalink
package/libmemcached: link with -latomic when needed
Browse files Browse the repository at this point in the history
Fix the following build failure raised since bump to version 1.1.4 in
commit 7205df8:

/home/buildroot/autobuild/instance-2/output-1/host/opt/ext-toolchain/bin/../lib/gcc/sparc-buildroot-linux-uclibc/11.3.0/../../../../sparc-buildroot-linux-uclibc/bin/ld: CMakeFiles/aslap.dir/ms_conn.c.o: undefined reference to symbol '__atomic_fetch_add_4@@LIBATOMIC_1.0'

Fixes:
 - http://autobuild.buildroot.org/results/c8e4e1f9609d1339fe070afe440c63660892600e

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
  • Loading branch information
ffontaine authored and jacmet committed Dec 3, 2023
1 parent b957a02 commit a73cbe6
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions package/libmemcached/libmemcached.mk
Original file line number Diff line number Diff line change
Expand Up @@ -32,4 +32,8 @@ else
LIBMEMCACHED_CONF_OPTS += -DENABLE_OPENSSL_CRYPTO=OFF
endif

ifeq ($(BR2_TOOLCHAIN_HAS_LIBATOMIC),y)
LIBMEMCACHED_CONF_OPTS += -DCMAKE_EXE_LINKER_FLAGS=-latomic
endif

$(eval $(cmake-package))

0 comments on commit a73cbe6

Please sign in to comment.