* [Buildroot] [PATCH 1/1] package/cairo: Do not use -latomic with non-threaded toolchains
@ 2016-03-06 8:52 Bernd Kuhls
2016-03-06 20:48 ` Thomas Petazzoni
0 siblings, 1 reply; 3+ messages in thread
From: Bernd Kuhls @ 2016-03-06 8:52 UTC (permalink / raw)
To: buildroot
Fixes
http://autobuild.buildroot.net/results/ec4/ec4e48c0e4b8fa72d8bb7ef4ad67a166699c0b62/
Gcc used by the defconfig was compiled with --disable-libatomic:
$ /home/bernd/buildroot/buildroot/output/host/usr/bin/arm-linux-gcc -v
[...]
Thread model: single
gcc version 4.9.3 (Buildroot 2015.11-rc1-00072-g4880195)
Configure fails due to
configure:3517: checking whether the C compiler works
configure:3539: /home/peko/autobuild/instance-2/output/host/usr/bin/arm-linux-gcc -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -Os -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -DCAIRO_NO_MUTEX=1 conftest.c -latomic >&5
/home/peko/autobuild/instance-2/output/host/opt/ext-toolchain/bin/../lib/gcc/arm-buildroot-linux-uclibcgnueabihf/4.9.3/../../../../arm-buildroot-linux-uclibcgnueabihf/bin/ld: cannot find -latomic
Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
---
package/cairo/cairo.mk | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/package/cairo/cairo.mk b/package/cairo/cairo.mk
index 6b54b28..d27a172 100644
--- a/package/cairo/cairo.mk
+++ b/package/cairo/cairo.mk
@@ -18,7 +18,7 @@ endif
# cairo can use C++11 atomics when available, so we need to link with
# libatomic for the architectures who need libatomic.
-ifeq ($(BR2_TOOLCHAIN_GCC_AT_LEAST_4_8),y)
+ifeq ($(BR2_TOOLCHAIN_GCC_AT_LEAST_4_8)$(BR2_TOOLCHAIN_HAS_THREADS),yy)
CAIRO_CONF_ENV += LIBS="-latomic"
endif
--
2.7.0
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [Buildroot] [PATCH 1/1] package/cairo: Do not use -latomic with non-threaded toolchains
2016-03-06 8:52 [Buildroot] [PATCH 1/1] package/cairo: Do not use -latomic with non-threaded toolchains Bernd Kuhls
@ 2016-03-06 20:48 ` Thomas Petazzoni
2016-03-06 20:53 ` Bernd Kuhls
0 siblings, 1 reply; 3+ messages in thread
From: Thomas Petazzoni @ 2016-03-06 20:48 UTC (permalink / raw)
To: buildroot
Dear Bernd Kuhls,
On Sun, 6 Mar 2016 09:52:31 +0100, Bernd Kuhls wrote:
> # cairo can use C++11 atomics when available, so we need to link with
> # libatomic for the architectures who need libatomic.
> -ifeq ($(BR2_TOOLCHAIN_GCC_AT_LEAST_4_8),y)
> +ifeq ($(BR2_TOOLCHAIN_GCC_AT_LEAST_4_8)$(BR2_TOOLCHAIN_HAS_THREADS),yy)
> CAIRO_CONF_ENV += LIBS="-latomic"
> endif
Thanks for this patch! However, I believe a more general solution is
needed for this problem. I have just submitted two patches that aim at
fixing this issue. See:
http://patchwork.ozlabs.org/patch/592591/
http://patchwork.ozlabs.org/patch/592592/
Let me know what you think.
Best regards,
Thomas
--
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2016-03-06 20:53 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-03-06 8:52 [Buildroot] [PATCH 1/1] package/cairo: Do not use -latomic with non-threaded toolchains Bernd Kuhls
2016-03-06 20:48 ` Thomas Petazzoni
2016-03-06 20:53 ` Bernd Kuhls
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox