Message ID | 20250801042242.3076232-3-raj.khem@gmail.com |
---|---|
State | New |
Headers | show |
Series | [1/7] toolchain/clang-native: Set BUILD_LDFLAGS instead of LDFLAGS | expand |
diff --git a/meta/recipes-core/libxcrypt/libxcrypt.inc b/meta/recipes-core/libxcrypt/libxcrypt.inc index 77fec832348..10f6cd921d8 100644 --- a/meta/recipes-core/libxcrypt/libxcrypt.inc +++ b/meta/recipes-core/libxcrypt/libxcrypt.inc @@ -24,3 +24,5 @@ API = "--disable-obsolete-api" EXTRA_OECONF += "${API}" BBCLASSEXTEND = "native nativesdk" + +LDFLAGS:append:toolchain-clang = "${@bb.utils.contains('DISTRO_FEATURES', 'ld-is-lld', ' -Wl,--undefined-version', '', d)}"
Unlike GNU ld, LLD defaults to erroring about undefined version symbols add commandline parameter to sush lld here Fixes | x86_64-yoesdk-linux-ld.lld: error: version script assignment of 'XCRYPT_2.0' to symbol 'crypt_gensalt_r' failed: symbol not defined | x86_64-yoesdk-linux-ld.lld: error: version script assignment of 'XCRYPT_2.0' to symbol 'xcrypt' failed: symbol not defined | x86_64-yoesdk-linux-ld.lld: error: version script assignment of 'XCRYPT_2.0' to symbol 'xcrypt_gensalt' failed: symbol not defined | x86_64-yoesdk-linux-ld.lld: error: version script assignment of 'XCRYPT_2.0' to symbol 'xcrypt_gensalt_r' failed: symbol not defined | x86_64-yoesdk-linux-ld.lld: error: version script assignment of 'XCRYPT_2.0' to symbol 'xcrypt_r' failed: symbol not defined | x86_64-yoesdk-linux-clang: error: linker command failed with exit code 1 (use -v to see invocation) Signed-off-by: Khem Raj <raj.khem@gmail.com> --- meta/recipes-core/libxcrypt/libxcrypt.inc | 2 ++ 1 file changed, 2 insertions(+)