aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Thomas Petazzoni <thomas.petazzoni@free-electrons.com>2016-05-24 17:29:53 +0200
committerGravatar Peter Korsgaard <peter@korsgaard.com>2016-05-24 21:49:33 +0200
commit45eaede51b6817abc53e71d9e73c4c17ee29039e (patch)
tree2823740487bef1b34805f3111b7c9476a2a10268
parent9b429a90fad9681caa8d057098b76470c5dd498e (diff)
downloadbuildroot-45eaede51b6817abc53e71d9e73c4c17ee29039e.tar.gz
buildroot-45eaede51b6817abc53e71d9e73c4c17ee29039e.tar.bz2
strongswan: needs __atomic operations
strongswan uses the __atomic_*() intrinsics, so we make it depend on BR2_TOOLCHAIN_HAS_ATOMIC and link with libatomic when available. This allows to fix the build on SPARC, therefore fixing: http://autobuild.buildroot.org/results/7e090237801874fb889c76f84863dc4c2ca20450/ Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
-rw-r--r--package/strongswan/Config.in2
-rw-r--r--package/strongswan/strongswan.mk4
2 files changed, 6 insertions, 0 deletions
diff --git a/package/strongswan/Config.in b/package/strongswan/Config.in
index cada78bb70..b49435c8c7 100644
--- a/package/strongswan/Config.in
+++ b/package/strongswan/Config.in
@@ -1,11 +1,13 @@
comment "strongswan needs a toolchain w/ threads, dynamic library"
depends on BR2_USE_MMU
+ depends on BR2_TOOLCHAIN_HAS_ATOMIC
depends on !BR2_TOOLCHAIN_HAS_THREADS || BR2_STATIC_LIBS
menuconfig BR2_PACKAGE_STRONGSWAN
bool "strongswan"
depends on BR2_USE_MMU # fork()
depends on BR2_TOOLCHAIN_HAS_THREADS
+ depends on BR2_TOOLCHAIN_HAS_ATOMIC
depends on !BR2_STATIC_LIBS
help
strongSwan is an OpenSource IPsec implementation for the
diff --git a/package/strongswan/strongswan.mk b/package/strongswan/strongswan.mk
index e7606c008f..36b5148535 100644
--- a/package/strongswan/strongswan.mk
+++ b/package/strongswan/strongswan.mk
@@ -35,6 +35,10 @@ STRONGSWAN_CONF_OPTS += \
--enable-vici=$(if $(BR2_PACKAGE_STRONGSWAN_VICI),yes,no) \
--enable-swanctl=$(if $(BR2_PACKAGE_STRONGSWAN_VICI),yes,no)
+ifeq ($(BR2_TOOLCHAIN_HAS_LIBATOMIC),y)
+STRONGSWAN_CONF_ENV += LIBS='-latomic'
+endif
+
ifeq ($(BR2_PACKAGE_STRONGSWAN_EAP),y)
STRONGSWAN_CONF_OPTS += \
--enable-eap-sim \