Skip to contentSkip to conversation

package/pistache: link with libatomic when needed

PATCH New Fabrice Fontaine 2 participants 2 messages Aug 15, 2020 – Aug 16, 2020

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 package/pistache: link with libatomic when needed

pistache does not mandatory link with libatomic since
https://github.com/oktal/pistache/commit/4ed3f8e148dae203730139ae3c1c4c87bfc86c02
however the logic is broken due to an unknown issue in CheckAtomic.cmake.

Instead of trying to fix it, just link with -latomic if needed

Fixes:
- http://autobuild.buildroot.org/results/17f05238a3479f5b0c9ef8f9bb42210f6fc14fff

---
 package/pistache/pistache.mk | 4 ++++
 1 file changed, 4 insertions(+)
package/pistache/pistache.mk +4 -0
index 4d6bd283ea..0ca64a05ae 100644
@@ -18,4 +18,8 @@ else
 PISTACHE_CONF_OPTS += -DPISTACHE_USE_SSL=OFF
 endif
 
+ifeq ($(BR2_TOOLCHAIN_HAS_LIBATOMIC),y)
+PISTACHE_CONF_OPTS += -DCMAKE_CXX_FLAGS="$(TARGET_CXXFLAGS) -latomic"
+endif
+
 $(eval $(cmake-package))
Signature · 1 line
2.27.0
#1 lore raw

PATCH 1/1 package/pistache: link with libatomic when needed

Quoted 3 lines · On Sat, 15 Aug 2020 22:14:15 +0200 Fabrice Fontaine…

pistache does not mandatory link with libatomic since
https://github.com/oktal/pistache/commit/4ed3f8e148dae203730139ae3c1c4c87bfc86c02
however the logic is broken due to an unknown issue in CheckAtomic.cmake.

It's a bit sad that they have all this logic to detect if linking with libatomic is needed, and it doesn't work for us. Have you investigated a bit more why it is not working ?

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com