[Buildroot] [git commit branch/2022.05.x] package/libcurl: link with -latomic if needed
Peter Korsgaard
peter at korsgaard.com
Wed Aug 10 15:31:37 UTC 2022
commit: https://git.buildroot.net/buildroot/commit/?id=74c890a556780b16b17d4d6b137156931d9a12de
branch: https://git.buildroot.net/buildroot/commit/?id=refs/heads/2022.05.x
Fixes build error:
/nvmedata/autobuild/instance-1/output-1/host/lib/gcc/microblazeel-buildroot-linux-uclibc/10.3.0/../../../../microblazeel-buildroot-linux-uclibc/bin/ld:
../lib/.libs/libcurl.a(libcurl_la-easy.o): in function `curl_simple_lock_lock':
(.text+0x46c): undefined reference to `__atomic_exchange_1'
Fixes:
http://autobuild.buildroot.net/results/1ed/1eddc48f24ab766cfc880c493ed9b230fc57bc09/
Signed-off-by: Bernd Kuhls <bernd.kuhls at t-online.de>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni at bootlin.com>
(cherry picked from commit 4351da28a4c0de53bf6e4fece48afcb9566590cb)
Signed-off-by: Peter Korsgaard <peter at korsgaard.com>
---
package/libcurl/libcurl.mk | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/package/libcurl/libcurl.mk b/package/libcurl/libcurl.mk
index e241bd1c88..5dc4eebefa 100644
--- a/package/libcurl/libcurl.mk
+++ b/package/libcurl/libcurl.mk
@@ -32,6 +32,10 @@ else
LIBCURL_CONF_OPTS += --disable-threaded-resolver
endif
+ifeq ($(BR2_TOOLCHAIN_HAS_LIBATOMIC),y)
+LIBCURL_CONF_OPTS += LIBS=-latomic
+endif
+
ifeq ($(BR2_PACKAGE_LIBCURL_VERBOSE),y)
LIBCURL_CONF_OPTS += --enable-verbose
else
More information about the buildroot
mailing list