summaryrefslogtreecommitdiffstats
path: root/recipes-devtools/clang/common.inc
blob: 5357848be6dc6bdb22aa00f94684d90fcab8bee2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
FILESEXTRAPATHS =. "${FILE_DIRNAME}/clang:"

LIC_FILES_CHKSUM = "file://llvm/LICENSE.TXT;md5=${LLVMMD5SUM} \
                    file://clang/LICENSE.TXT;md5=${CLANGMD5SUM} \
"
LICENSE = "Apache-2.0-with-LLVM-exception"

BASEURI ??= "${LLVM_GIT}/llvm-project;protocol=${LLVM_GIT_PROTOCOL};branch=${BRANCH}"
SRC_URI = "\
    ${BASEURI} \
    file://llvm-config \
    file://libunwind.pc.in \
    file://0001-lldb-Add-lxml2-to-linker-cmdline-of-xml-is-found.patch \
    file://0002-libcxxabi-Find-libunwind-headers-when-LIBCXXABI_LIBU.patch \
    file://0003-compiler-rt-support-a-new-embedded-linux-target.patch \
    file://0004-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch \
    file://0005-llvm-TargetLibraryInfo-Undefine-libc-functions-if-th.patch \
    file://0006-llvm-allow-env-override-of-exe-path.patch \
    file://0007-clang-driver-Check-sysroot-for-ldso-path.patch \
    file://0008-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch \
    file://0009-clang-musl-ppc-does-not-support-128-bit-long-double.patch \
    file://0010-clang-Prepend-trailing-to-sysroot.patch \
    file://0011-clang-Look-inside-the-target-sysroot-for-compiler-ru.patch \
    file://0012-clang-Define-releative-gcc-installation-dir.patch \
    file://0013-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch \
    file://0014-Pass-PYTHON_EXECUTABLE-when-cross-compiling-for-nati.patch \
    file://0015-Check-for-atomic-double-intrinsics.patch \
    file://0016-clang-Enable-SSP-and-PIE-by-default.patch \
    file://0017-libcxx-Add-compiler-runtime-library-to-link-step-for.patch \
    file://0018-clang-llvm-cmake-Fix-configure-for-packages-using-fi.patch \
    file://0019-clang-Fix-resource-dir-location-for-cross-toolchains.patch \
    file://0020-fix-path-to-libffi.patch \
    file://0021-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch \
    file://0022-clang-Use-python3-in-python-scripts.patch \
    file://0023-For-x86_64-set-Yocto-based-GCC-install-search-path.patch \
    file://0024-llvm-Do-not-use-find_library-for-ncurses.patch \
    file://0025-llvm-Insert-anchor-for-adding-OE-distro-vendor-names.patch \
    file://0026-compiler-rt-Use-mcr-based-barrier-on-armv6.patch \
    file://0027-clang-Switch-defaults-to-dwarf-5-debug-info-on-Linux.patch \
    file://0028-compiler-rt-Do-not-use-backtrace-APIs-on-non-glibc-l.patch \
    file://0029-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch \
    file://0030-compiler-rt-Link-scudo-with-SANITIZER_CXX_ABI_LIBRAR.patch \
    file://0031-compiler-rt-Link-scudo-standalone-with-libatomic-on-.patch \
    file://0032-libunwind-Added-unw_backtrace-method.patch \
    file://0033-compiler-rt-Use-uintptr_t-instead-of-_Unwind_Word.patch \
    file://0034-compiler-rt-Do-not-force-thumb-mode-directive.patch \
    file://0035-Drop-the-git-suffix-from-various-version-variables.patch \
    file://0036-clang-Do-not-use-install-relative-libc-headers.patch \
    file://0037-Revert-libomptarget-amdcgn-Add-build-dependency-for-.patch \
    "
# Fallback to no-PIE if not set
GCCPIE ??= ""

S = "${TMPDIR}/work-shared/llvm-project-source-${PV}-${PR}/git"
B = "${WORKDIR}/llvm-project-source-${PV}/build.${HOST_SYS}.${TARGET_SYS}"

# We need to ensure that for the shared work directory, the do_patch signatures match
# The real WORKDIR location isn't a dependency for the shared workdir.
src_patches[vardepsexclude] = "WORKDIR"
should_apply[vardepsexclude] += "PN"