diff options
author | Khem Raj <raj.khem@gmail.com> | 2019-07-31 10:48:20 -0700 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2019-08-08 10:19:56 +0100 |
commit | 4df4352813c76ef75ab7c85e40d2b5ec2e8535ec (patch) | |
tree | e0de09a7bcacc826ca68e70e921f49f013936ef7 /meta/recipes-devtools/llvm/llvm/0007-llvm-allow-env-override-of-exe-path.patch | |
parent | 3ef77a577c8dcbf9ac3718a3bc114767ab55a71a (diff) | |
download | poky-4df4352813c76ef75ab7c85e40d2b5ec2e8535ec.tar.gz |
mesa,llvm,meson: Update llvm to 8.0.1 plus define and use LLVM version globally
- Add missing dependency on libedit
- Define LLVMVERSION on the same lines as GCCVERSION and other tools
- Use LLVMVERSION in mesa and meson.bbclass to get llvm version instead of
hardcoding it
- Use llvm patches unmodified from meta-clang, helps in keeping them in
sync
- Define PREFERRED_VERSION for llvm, llvm-native, nativesdk-llvm
(From OE-Core rev: 3c08b638348abd543fc92baf56c28ca16ae6aac6)
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/llvm/llvm/0007-llvm-allow-env-override-of-exe-path.patch')
-rw-r--r-- | meta/recipes-devtools/llvm/llvm/0007-llvm-allow-env-override-of-exe-path.patch | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/meta/recipes-devtools/llvm/llvm/0007-llvm-allow-env-override-of-exe-path.patch b/meta/recipes-devtools/llvm/llvm/0007-llvm-allow-env-override-of-exe-path.patch new file mode 100644 index 0000000000..f47080c9fd --- /dev/null +++ b/meta/recipes-devtools/llvm/llvm/0007-llvm-allow-env-override-of-exe-path.patch | |||
@@ -0,0 +1,38 @@ | |||
1 | From b66d6f39a374b8df41e7235351e5dee2e81f440c Mon Sep 17 00:00:00 2001 | ||
2 | From: Martin Kelly <mkelly@xevo.com> | ||
3 | Date: Fri, 19 May 2017 00:22:57 -0700 | ||
4 | Subject: [PATCH 07/19] llvm: allow env override of exe path | ||
5 | |||
6 | When using a native llvm-config from inside a sysroot, we need llvm-config to | ||
7 | return the libraries, include directories, etc. from inside the sysroot rather | ||
8 | than from the native sysroot. Thus provide an env override for calling | ||
9 | llvm-config from a target sysroot. | ||
10 | |||
11 | Upstream-Status: Pending | ||
12 | Signed-off-by: Martin Kelly <mkelly@xevo.com> | ||
13 | Signed-off-by: Khem Raj <raj.khem@gmail.com> | ||
14 | --- | ||
15 | llvm/tools/llvm-config/llvm-config.cpp | 7 +++++++ | ||
16 | 1 file changed, 7 insertions(+) | ||
17 | |||
18 | diff --git a/llvm/tools/llvm-config/llvm-config.cpp b/llvm/tools/llvm-config/llvm-config.cpp | ||
19 | index 7ef7c46a262..a4f7ed82c7b 100644 | ||
20 | --- a/llvm/tools/llvm-config/llvm-config.cpp | ||
21 | +++ b/llvm/tools/llvm-config/llvm-config.cpp | ||
22 | @@ -225,6 +225,13 @@ Typical components:\n\ | ||
23 | |||
24 | /// Compute the path to the main executable. | ||
25 | std::string GetExecutablePath(const char *Argv0) { | ||
26 | + // Hack for Yocto: we need to override the root path when we are using | ||
27 | + // llvm-config from within a target sysroot. | ||
28 | + const char *Sysroot = std::getenv("YOCTO_ALTERNATE_EXE_PATH"); | ||
29 | + if (Sysroot != nullptr) { | ||
30 | + return Sysroot; | ||
31 | + } | ||
32 | + | ||
33 | // This just needs to be some symbol in the binary; C++ doesn't | ||
34 | // allow taking the address of ::main however. | ||
35 | void *P = (void *)(intptr_t)GetExecutablePath; | ||
36 | -- | ||
37 | 2.22.0 | ||
38 | |||