From 765d4ce064c84d1c1e1ec650813e47a3135fbd41 Mon Sep 17 00:00:00 2001 From: Khem Raj Date: Tue, 18 May 2021 22:52:53 -0700 Subject: replace --rtlib with -rtlib This is advertised option from clang Signed-off-by: Khem Raj --- classes/clang.bbclass | 6 +++--- conf/nonclangable.conf | 52 +++++++++++++++++++++++++------------------------- 2 files changed, 29 insertions(+), 29 deletions(-) diff --git a/classes/clang.bbclass b/classes/clang.bbclass index d6a7fe8..a56084d 100644 --- a/classes/clang.bbclass +++ b/classes/clang.bbclass @@ -13,8 +13,8 @@ LTO_toolchain-clang = "${@bb.utils.contains('DISTRO_FEATURES', 'thin-lto', '-flt PACKAGE_DEBUG_SPLIT_STYLE_toolchain-clang = "debug-without-src" COMPILER_RT ??= "${@bb.utils.contains("RUNTIME", "llvm", "-rtlib=compiler-rt ${UNWINDLIB}", "", d)}" -COMPILER_RT_powerpc = "--rtlib=libgcc ${UNWINDLIB}" -COMPILER_RT_armeb = "--rtlib=libgcc ${UNWINDLIB}" +COMPILER_RT_powerpc = "-rtlib=libgcc ${UNWINDLIB}" +COMPILER_RT_armeb = "-rtlib=libgcc ${UNWINDLIB}" UNWINDLIB ??= "${@bb.utils.contains("RUNTIME", "llvm", "--unwindlib=libgcc", "", d)}" UNWINDLIB_riscv64 = "--unwindlib=libgcc" @@ -89,7 +89,7 @@ def clang_base_deps(d): if not d.getVar('INHIBIT_DEFAULT_DEPS', False): if not oe.utils.inherits(d, 'allarch') : ret = " clang-cross-${TARGET_ARCH} virtual/libc " - if (d.getVar('COMPILER_RT').find('--rtlib=compiler-rt') != -1): + if (d.getVar('COMPILER_RT').find('-rtlib=compiler-rt') != -1): ret += " compiler-rt " else: ret += " libgcc " diff --git a/conf/nonclangable.conf b/conf/nonclangable.conf index f889df2..b174603 100644 --- a/conf/nonclangable.conf +++ b/conf/nonclangable.conf @@ -271,24 +271,24 @@ TUNE_CCARGS_remove_pn-pulseaudio_toolchain-clang = "-Qunused-arguments" #| /usr/src/debug/ruby/2.5.1-r0/build/../ruby-2.5.1/process.c:7073: undefined reference to `__mulodi4' #| clang-7: error: linker command failed with exit code 1 (use -v to see invocation) -COMPILER_RT_pn-ruby_toolchain-clang = "--rtlib=compiler-rt ${UNWINDLIB}" -COMPILER_RT_pn-python3_toolchain-clang = "--rtlib=compiler-rt ${UNWINDLIB}" -COMPILER_RT_pn-m4_toolchain-clang = "--rtlib=compiler-rt ${UNWINDLIB}" -COMPILER_RT_pn-cpio_toolchain-clang = "--rtlib=compiler-rt ${UNWINDLIB}" -COMPILER_RT_pn-openssh_toolchain-clang = "--rtlib=compiler-rt ${UNWINDLIB}" -COMPILER_RT_pn-webkitgtk_toolchain-clang = "--rtlib=compiler-rt ${UNWINDLIB}" -COMPILER_RT_pn-wpewebkit_toolchain-clang = "--rtlib=compiler-rt ${UNWINDLIB}" -COMPILER_RT_pn-python3-numpy_toolchain-clang = "--rtlib=compiler-rt ${UNWINDLIB}" -COMPILER_RT_remove_pn-m4_powerpc = "--rtlib=compiler-rt" -COMPILER_RT_remove_pn-ruby_powerpc = "--rtlib=compiler-rt" -COMPILER_RT_remove_pn-webkitgtk_powerpc = "--rtlib=compiler-rt" -COMPILER_RT_remove_pn-m4_armeb = "--rtlib=compiler-rt" -COMPILER_RT_remove_pn-ruby_armeb = "--rtlib=compiler-rt" -COMPILER_RT_remove_pn-webkitgtk_armeb = "--rtlib=compiler-rt" +COMPILER_RT_pn-ruby_toolchain-clang = "-rtlib=compiler-rt ${UNWINDLIB}" +COMPILER_RT_pn-python3_toolchain-clang = "-rtlib=compiler-rt ${UNWINDLIB}" +COMPILER_RT_pn-m4_toolchain-clang = "-rtlib=compiler-rt ${UNWINDLIB}" +COMPILER_RT_pn-cpio_toolchain-clang = "-rtlib=compiler-rt ${UNWINDLIB}" +COMPILER_RT_pn-openssh_toolchain-clang = "-rtlib=compiler-rt ${UNWINDLIB}" +COMPILER_RT_pn-webkitgtk_toolchain-clang = "-rtlib=compiler-rt ${UNWINDLIB}" +COMPILER_RT_pn-wpewebkit_toolchain-clang = "-rtlib=compiler-rt ${UNWINDLIB}" +COMPILER_RT_pn-python3-numpy_toolchain-clang = "-rtlib=compiler-rt ${UNWINDLIB}" +COMPILER_RT_remove_pn-m4_powerpc = "-rtlib=compiler-rt" +COMPILER_RT_remove_pn-ruby_powerpc = "-rtlib=compiler-rt" +COMPILER_RT_remove_pn-webkitgtk_powerpc = "-rtlib=compiler-rt" +COMPILER_RT_remove_pn-m4_armeb = "-rtlib=compiler-rt" +COMPILER_RT_remove_pn-ruby_armeb = "-rtlib=compiler-rt" +COMPILER_RT_remove_pn-webkitgtk_armeb = "-rtlib=compiler-rt" # build/lib/libQt5Widgets.so: undefined reference to `__lshrti3' # __lshrti3 is missing in libgcc -COMPILER_RT_pn-qtbase_toolchain-clang_riscv32 = "--rtlib=compiler-rt ${UNWINDLIB}" +COMPILER_RT_pn-qtbase_toolchain-clang_riscv32 = "-rtlib=compiler-rt ${UNWINDLIB}" LDFLAGS_append_pn-gnutls_toolchain-clang_riscv64 = " -latomic" LDFLAGS_append_pn-harfbuzz_toolchain-clang_riscv64 = " -latomic" @@ -298,21 +298,21 @@ LDFLAGS_append_pn-qemu_toolchain-clang_runtime-gnu_x86 = " -latomic" # glibc is built with gcc and hence encodes some libgcc specific builtins which are not found # when doing static linking with clang using compiler-rt, so use libgcc # undefined reference to `__unordtf2' -COMPILER_RT_pn-libc-bench_libc-glibc_toolchain-clang_x86 = "--rtlib=libgcc" -COMPILER_RT_pn-aufs-util_libc-glibc_toolchain-clang_x86 = "--rtlib=libgcc" -COMPILER_RT_pn-libhugetlbfs_libc-glibc_toolchain-clang_x86 = "--rtlib=libgcc" -COMPILER_RT_pn-tsocks_libc-glibc_toolchain-clang_x86 = "--rtlib=libgcc" -COMPILER_RT_pn-libc-bench_libc-glibc_toolchain-clang_x86-64 = "--rtlib=libgcc" -COMPILER_RT_pn-aufs-util_libc-glibc_toolchain-clang_x86-64 = "--rtlib=libgcc" -COMPILER_RT_pn-libhugetlbfs_libc-glibc_toolchain-clang_x86-64 = "--rtlib=libgcc" -COMPILER_RT_pn-tsocks_libc-glibc_toolchain-clang_x86-64 = "--rtlib=libgcc" +COMPILER_RT_pn-libc-bench_libc-glibc_toolchain-clang_x86 = "-rtlib=libgcc" +COMPILER_RT_pn-aufs-util_libc-glibc_toolchain-clang_x86 = "-rtlib=libgcc" +COMPILER_RT_pn-libhugetlbfs_libc-glibc_toolchain-clang_x86 = "-rtlib=libgcc" +COMPILER_RT_pn-tsocks_libc-glibc_toolchain-clang_x86 = "-rtlib=libgcc" +COMPILER_RT_pn-libc-bench_libc-glibc_toolchain-clang_x86-64 = "-rtlib=libgcc" +COMPILER_RT_pn-aufs-util_libc-glibc_toolchain-clang_x86-64 = "-rtlib=libgcc" +COMPILER_RT_pn-libhugetlbfs_libc-glibc_toolchain-clang_x86-64 = "-rtlib=libgcc" +COMPILER_RT_pn-tsocks_libc-glibc_toolchain-clang_x86-64 = "-rtlib=libgcc" #(unwind.o): in function `__pthread_unwind': #/usr/src/debug/glibc/2.29-r0/git/nptl/unwind.c:121: undefined reference to `_Unwind_ForcedUnwind' #clang-8: error: linker command failed with exit code 1 (use -v to see invocation) -COMPILER_RT_pn-libc-bench_libc-glibc_toolchain-clang_arm = "--rtlib=libgcc" -COMPILER_RT_pn-aufs-util_libc-glibc_toolchain-clang_arm = "--rtlib=libgcc" -COMPILER_RT_pn-libhugetlbfs_libc-glibc_toolchain-clang_arm = "--rtlib=libgcc" +COMPILER_RT_pn-libc-bench_libc-glibc_toolchain-clang_arm = "-rtlib=libgcc" +COMPILER_RT_pn-aufs-util_libc-glibc_toolchain-clang_arm = "-rtlib=libgcc" +COMPILER_RT_pn-libhugetlbfs_libc-glibc_toolchain-clang_arm = "-rtlib=libgcc" # Uses gcc for native tools, e.g. nsinstall and passes clang options which fails so # let same compiler ( gcc or clang) be native/cross compiler -- cgit v1.2.3-54-g00ecf