Skip to contentSkip to conversation

package/fio: link with -latomic if needed

PATCH In review Bernd Kuhls 2 participants 2 messages Nov 22, 2025

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 package/fio: link with -latomic if needed

Upstream commit http://git.kernel.dk/cgit/fio/commit/?h=fio-3.41&id=a9ba7cef70a7fc99d406addbdc6479f633d01ec7
which was first included in version 3.41 and bumped in buildroot with
commit 215133c0fc2819f059fbb35071ab2e0987f5107d added use of atomic
functions causing build errors which are fixed by linking to libatomic.

Fixes:
https://autobuild.buildroot.net/results/c74/c74529b5a3800af269b6819af3cc742ba348d5fe/

---
 package/fio/fio.mk | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
package/fio/fio.mk +6 -1
index cb456587b0..38e7aa7967 100644
@@ -11,6 +11,11 @@ FIO_LICENSE_FILES = COPYING MORAL-LICENSE
 
 FIO_OPTS = --disable-native --cc="$(TARGET_CC)" --extra-cflags="$(TARGET_CFLAGS)"
 
+# Uses __atomic_load_8
+ifeq ($(BR2_TOOLCHAIN_HAS_LIBATOMIC),y)
+FIO_CONF_ENV += LIBS=-latomic
+endif
+
 ifeq ($(BR2_PACKAGE_LIBAIO),y)
 FIO_DEPENDENCIES += libaio
 endif
@@ -36,7 +41,7 @@ FIO_DEPENDENCIES += zlib
 endif
 
 define FIO_CONFIGURE_CMDS
-	(cd $(@D); $(TARGET_MAKE_ENV) ./configure $(FIO_OPTS))
+	(cd $(@D); $(TARGET_MAKE_ENV) $(FIO_CONF_ENV) ./configure $(FIO_OPTS))
 endef
 
 define FIO_BUILD_CMDS
Signature · 6 lines
2.47.3

_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
#1 lore raw
Quoted 8 lines · Bernd Kuhls

Upstream commit http://git.kernel.dk/cgit/fio/commit/?h=fio-3.41&id=a9ba7cef70a7fc99d406addbdc6479f633d01ec7
which was first included in version 3.41 and bumped in buildroot with
commit 215133c0fc2819f059fbb35071ab2e0987f5107d added use of atomic
functions causing build errors which are fixed by linking to libatomic.

Fixes:
https://autobuild.buildroot.net/results/c74/c74529b5a3800af269b6819af3cc742ba348d5fe/

Applied to master, thanks.
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot