diff --git a/meta-networking/recipes-protocols/frr/frr_10.6.1.bb b/meta-networking/recipes-protocols/frr/frr_10.6.1.bb index 1cd102f0da..8f53cf68d5 100644 --- a/meta-networking/recipes-protocols/frr/frr_10.6.1.bb +++ b/meta-networking/recipes-protocols/frr/frr_10.6.1.bb @@ -67,6 +67,14 @@ LDFLAGS:append:mipsel = " -latomic" LDFLAGS:append:powerpc = " -latomic" LDFLAGS:append:riscv32 = " -latomic" +# configure links -latomic whenever the toolchain merely has it +# (AC_CHECK_LIB([atomic],[main])) rather than when it is needed. buildtools ships +# libatomic, so clippy gets a DT_NEEDED that the loader cannot resolve later: +# BUILD_LDFLAGS has no --as-needed, there is no libatomic-native, and uninative +# only rewrites the interpreter. Hosts without a system libatomic then fail with +# "clippy: error while loading shared libraries: libatomic.so.1". +LDFLAGS:append:class-native = " -Wl,--as-needed" + SYSTEMD_PACKAGES = "${PN}" SYSTEMD_SERVICE:${PN} = "frr.service" SYSTEMD_AUTO_ENABLE = "disable"