diff options
Diffstat (limited to 'recipes-devtools/clang/compiler-rt_git.bb')
-rw-r--r-- | recipes-devtools/clang/compiler-rt_git.bb | 130 |
1 files changed, 0 insertions, 130 deletions
diff --git a/recipes-devtools/clang/compiler-rt_git.bb b/recipes-devtools/clang/compiler-rt_git.bb deleted file mode 100644 index debc61f..0000000 --- a/recipes-devtools/clang/compiler-rt_git.bb +++ /dev/null | |||
@@ -1,130 +0,0 @@ | |||
1 | # Copyright (C) 2015 Khem Raj <raj.khem@gmail.com> | ||
2 | # Released under the MIT license (see COPYING.MIT for the terms) | ||
3 | |||
4 | SUMMARY = "LLVM based C/C++ compiler Runtime" | ||
5 | DESCRIPTIOM = "Simple builtin library that provides an \ | ||
6 | implementation of the low-level target-specific \ | ||
7 | hooks required by code generation and other runtime \ | ||
8 | components" | ||
9 | HOMEPAGE = "http://compiler-rt.llvm.org/" | ||
10 | SECTION = "base" | ||
11 | |||
12 | require clang.inc | ||
13 | require common-source.inc | ||
14 | |||
15 | BPN = "compiler-rt" | ||
16 | |||
17 | inherit cmake cmake-native pkgconfig python3native | ||
18 | |||
19 | |||
20 | LIC_FILES_CHKSUM = "file://compiler-rt/LICENSE.TXT;md5=d846d1d65baf322d4c485d6ee54e877a" | ||
21 | |||
22 | LIBCPLUSPLUS = "" | ||
23 | COMPILER_RT = "" | ||
24 | |||
25 | TUNE_CCARGS:remove = "-no-integrated-as" | ||
26 | |||
27 | INHIBIT_DEFAULT_DEPS = "1" | ||
28 | |||
29 | DEPENDS += "ninja-native libgcc" | ||
30 | DEPENDS:append:class-target = " clang-cross-${TARGET_ARCH} virtual/${MLPREFIX}libc gcc-runtime" | ||
31 | DEPENDS:append:class-nativesdk = " clang-native clang-crosssdk-${SDK_SYS} nativesdk-gcc-runtime" | ||
32 | DEPENDS:append:class-native = " clang-native" | ||
33 | |||
34 | # Trick clang.bbclass into not creating circular dependencies | ||
35 | UNWINDLIB:class-nativesdk:toolchain-clang = "--unwindlib=libgcc" | ||
36 | COMPILER_RT:class-nativesdk:toolchain-clang = "-rtlib=libgcc --unwindlib=libgcc" | ||
37 | LIBCPLUSPLUS:class-nativesdk:toolchain-clang = "-stdlib=libstdc++" | ||
38 | UNWINDLIB:class-native:toolchain-clang = "--unwindlib=libgcc" | ||
39 | COMPILER_RT:class-native:toolchain-clang = "-rtlib=libgcc --unwindlib=libgcc" | ||
40 | LIBCPLUSPLUS:class-native:toolchain-clang = "-stdlib=libstdc++" | ||
41 | UNWINDLIB:class-target:toolchain-clang = "--unwindlib=libgcc" | ||
42 | COMPILER_RT:class-target:toolchain-clang = "-rtlib=libgcc --unwindlib=libgcc" | ||
43 | LIBCPLUSPLUS:class-target:toolchain-clang = "-stdlib=libstdc++" | ||
44 | |||
45 | PACKAGECONFIG ??= "" | ||
46 | PACKAGECONFIG[crt] = "-DCOMPILER_RT_BUILD_CRT:BOOL=ON,-DCOMPILER_RT_BUILD_CRT:BOOL=OFF" | ||
47 | PACKAGECONFIG[profile] = "-DCOMPILER_RT_BUILD_PROFILE=ON,-DCOMPILER_RT_BUILD_PROFILE=OFF" | ||
48 | # Context Profiling, might need to enable 'profile' too | ||
49 | PACKAGECONFIG[ctx-profile] = "-DCOMPILER_RT_BUILD_CTX_PROFILE=ON,-DCOMPILER_RT_BUILD_CTX_PROFILE=OFF" | ||
50 | |||
51 | HF = "" | ||
52 | HF:class-target = "${@ bb.utils.contains('TUNE_CCARGS_MFLOAT', 'hard', 'hf', '', d)}" | ||
53 | HF[vardepvalue] = "${HF}" | ||
54 | |||
55 | OECMAKE_TARGET_COMPILE = "compiler-rt" | ||
56 | OECMAKE_TARGET_INSTALL = "install-compiler-rt install-compiler-rt-headers" | ||
57 | OECMAKE_SOURCEPATH = "${S}/llvm" | ||
58 | EXTRA_OECMAKE += "-DCMAKE_BUILD_TYPE=RelWithDebInfo \ | ||
59 | -DLLVM_ENABLE_PER_TARGET_RUNTIME_DIR=OFF \ | ||
60 | -DCOMPILER_RT_STANDALONE_BUILD=ON \ | ||
61 | -DCOMPILER_RT_INCLUDE_TESTS=OFF \ | ||
62 | -DCOMPILER_RT_BUILD_XRAY=OFF \ | ||
63 | -DCOMPILER_RT_BUILD_SANITIZERS=OFF \ | ||
64 | -DCOMPILER_RT_BUILD_MEMPROF=OFF \ | ||
65 | -DCOMPILER_RT_BUILD_LIBFUZZER=OFF \ | ||
66 | -DLLVM_ENABLE_RUNTIMES='compiler-rt' \ | ||
67 | -DLLVM_LIBDIR_SUFFIX=${LLVM_LIBDIR_SUFFIX} \ | ||
68 | -DLLVM_APPEND_VC_REV=OFF \ | ||
69 | -S ${S}/runtimes \ | ||
70 | " | ||
71 | EXTRA_OECMAKE:append:class-target = "\ | ||
72 | -DCMAKE_RANLIB=${STAGING_BINDIR_TOOLCHAIN}/${TARGET_PREFIX}llvm-ranlib \ | ||
73 | -DCMAKE_AR=${STAGING_BINDIR_TOOLCHAIN}/${TARGET_PREFIX}llvm-ar \ | ||
74 | -DCMAKE_NM=${STAGING_BINDIR_TOOLCHAIN}/${TARGET_PREFIX}llvm-nm \ | ||
75 | -DCMAKE_C_COMPILER_TARGET=${HOST_ARCH}${HOST_VENDOR}-${HOST_OS}${HF} \ | ||
76 | -DCOMPILER_RT_DEFAULT_TARGET_ONLY=ON \ | ||
77 | -DCMAKE_POSITION_INDEPENDENT_CODE=ON \ | ||
78 | " | ||
79 | |||
80 | EXTRA_OECMAKE:append:class-nativesdk = "\ | ||
81 | -DCMAKE_RANLIB=${STAGING_BINDIR_TOOLCHAIN}/${TARGET_PREFIX}llvm-ranlib \ | ||
82 | -DCMAKE_AR=${STAGING_BINDIR_TOOLCHAIN}/${TARGET_PREFIX}llvm-ar \ | ||
83 | -DCMAKE_NM=${STAGING_BINDIR_TOOLCHAIN}/${TARGET_PREFIX}llvm-nm \ | ||
84 | -DLLVM_TABLEGEN=${STAGING_BINDIR_NATIVE}/llvm-tblgen \ | ||
85 | -DCLANG_TABLEGEN=${STAGING_BINDIR_NATIVE}/clang-tblgen \ | ||
86 | -DCMAKE_C_COMPILER_TARGET=${HOST_ARCH}${HOST_VENDOR}-${HOST_OS}${HF} \ | ||
87 | -DCOMPILER_RT_DEFAULT_TARGET_ONLY=ON \ | ||
88 | " | ||
89 | EXTRA_OECMAKE:append:powerpc = " -DCOMPILER_RT_DEFAULT_TARGET_ARCH=powerpc " | ||
90 | |||
91 | do_install:append () { | ||
92 | mkdir -p ${D}${nonarch_libdir}/clang/${MAJOR_VER}.${MINOR_VER}.${PATCH_VER}/lib | ||
93 | mv ${D}${nonarch_libdir}/linux ${D}${nonarch_libdir}/clang/${MAJOR_VER}.${MINOR_VER}.${PATCH_VER}/lib | ||
94 | } | ||
95 | |||
96 | FILES_SOLIBSDEV = "" | ||
97 | |||
98 | FILES:${PN} += "${nonarch_libdir}/clang/${MAJOR_VER}.${MINOR_VER}.${PATCH_VER}/lib/linux/lib*${SOLIBSDEV} \ | ||
99 | ${nonarch_libdir}/clang/${MAJOR_VER}.${MINOR_VER}.${PATCH_VER}/*.txt \ | ||
100 | ${nonarch_libdir}/clang/${MAJOR_VER}.${MINOR_VER}.${PATCH_VER}/share/*.txt" | ||
101 | FILES:${PN}-staticdev += "${nonarch_libdir}/clang/${MAJOR_VER}.${MINOR_VER}.${PATCH_VER}/lib/linux/*.a" | ||
102 | FILES:${PN}-dev += "${datadir} ${nonarch_libdir}/clang/${MAJOR_VER}.${MINOR_VER}.${PATCH_VER}/lib/linux/*.syms \ | ||
103 | ${nonarch_libdir}/clang/${MAJOR_VER}.${MINOR_VER}.${PATCH_VER}/include \ | ||
104 | ${nonarch_libdir}/clang/${MAJOR_VER}.${MINOR_VER}.${PATCH_VER}/lib/linux/clang_rt.crt*.o \ | ||
105 | ${nonarch_libdir}/clang/${MAJOR_VER}.${MINOR_VER}.${PATCH_VER}/lib/linux/libclang_rt.asan-preinit*.a" | ||
106 | |||
107 | INSANE_SKIP:${PN} = "dev-so libdir" | ||
108 | INSANE_SKIP:${PN}-dbg = "libdir" | ||
109 | |||
110 | #PROVIDES:append:class-target = "\ | ||
111 | # virtual/${MLPREFIX}compilerlibs \ | ||
112 | # libgcc \ | ||
113 | # libgcc-initial \ | ||
114 | # libgcc-dev \ | ||
115 | # libgcc-initial-dev \ | ||
116 | # " | ||
117 | # | ||
118 | |||
119 | RDEPENDS:${PN}-dev += "${PN}-staticdev" | ||
120 | |||
121 | BBCLASSEXTEND = "native nativesdk" | ||
122 | |||
123 | ALLOW_EMPTY:${PN} = "1" | ||
124 | ALLOW_EMPTY:${PN}-dev = "1" | ||
125 | |||
126 | TOOLCHAIN = "clang" | ||
127 | # Overrides defaults from clang.bbclass | ||
128 | TOOLCHAIN:class-nativesdk = "clang" | ||
129 | TOOLCHAIN:class-native = "clang" | ||
130 | SYSROOT_DIRS:append:class-target = " ${nonarch_libdir}" | ||