diff options
author | Esben Haabendal <esben.haabendal@huawei.com> | 2022-04-07 14:34:31 +0200 |
---|---|---|
committer | Khem Raj <raj.khem@gmail.com> | 2023-09-08 09:08:54 -0700 |
commit | e836f76afc97912336617b5b41377c796ffcf743 (patch) | |
tree | 8309cf5208b2c74eb7d3354e38bb6e5a9e66f730 | |
parent | 4c579d445088a40ef1b3ce7c1f961ed5c845c292 (diff) | |
download | meta-clang-e836f76afc97912336617b5b41377c796ffcf743.tar.gz |
libcxx: Fix nativesdk building
Signed-off-by: Esben Haabendal <esben.haabendal@huawei.com>
(cherry picked from commit 12a5f8be1201fa1fcb62aa004542279d5c9acae0)
-rw-r--r-- | recipes-devtools/clang/libcxx_git.bb | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/recipes-devtools/clang/libcxx_git.bb b/recipes-devtools/clang/libcxx_git.bb index f7fcd1a..b8df601 100644 --- a/recipes-devtools/clang/libcxx_git.bb +++ b/recipes-devtools/clang/libcxx_git.bb | |||
@@ -21,12 +21,19 @@ PACKAGECONFIG[unwind-shared] = "-DLIBUNWIND_ENABLE_SHARED=ON,-DLIBUNWIND_ENABLE_ | |||
21 | 21 | ||
22 | DEPENDS += "ninja-native" | 22 | DEPENDS += "ninja-native" |
23 | DEPENDS:append:class-target = " clang-cross-${TARGET_ARCH} virtual/${MLPREFIX}libc virtual/${TARGET_PREFIX}compilerlibs" | 23 | DEPENDS:append:class-target = " clang-cross-${TARGET_ARCH} virtual/${MLPREFIX}libc virtual/${TARGET_PREFIX}compilerlibs" |
24 | DEPENDS:append:class-nativesdk = " clang-crosssdk-${SDK_ARCH} nativesdk-compiler-rt" | ||
24 | DEPENDS:append:class-native = " clang-native" | 25 | DEPENDS:append:class-native = " clang-native" |
25 | 26 | ||
26 | LIBCPLUSPLUS = "" | 27 | LIBCPLUSPLUS = "" |
27 | COMPILER_RT ?= "-rtlib=compiler-rt" | 28 | COMPILER_RT ?= "-rtlib=compiler-rt" |
28 | 29 | ||
30 | # Trick clang.bbclass into not creating circular dependencies | ||
31 | UNWINDLIB:class-nativesdk = "--unwindlib=libgcc" | ||
32 | COMPILER_RT:class-nativesdk = "-rtlib=libgcc --unwindlib=libgcc" | ||
33 | LIBCPLUSPLUS:class-nativesdk = "-stdlib=libstdc++" | ||
34 | |||
29 | CC:append:toolchain-clang:class-native = " -unwindlib=libgcc -rtlib=libgcc" | 35 | CC:append:toolchain-clang:class-native = " -unwindlib=libgcc -rtlib=libgcc" |
36 | CC:append:toolchain-clang:class-nativesdk = " -unwindlib=libgcc -rtlib=libgcc" | ||
30 | 37 | ||
31 | CXXFLAGS += "-stdlib=libstdc++" | 38 | CXXFLAGS += "-stdlib=libstdc++" |
32 | LDFLAGS += "-unwindlib=libgcc -stdlib=libstdc++" | 39 | LDFLAGS += "-unwindlib=libgcc -stdlib=libstdc++" |