summaryrefslogtreecommitdiffstats
path: root/dynamic-layers/clang-layer/recipes-core/ispc/ispc/0001-CMakeLists.txt-allow-to-pick-llvm-config-from-usr-bi.patch
diff options
context:
space:
mode:
authorNaveen Saini <naveen.kumar.saini@intel.com>2023-05-16 15:03:06 +0800
committerAnuj Mittal <anuj.mittal@intel.com>2023-05-17 09:45:24 +0800
commita19fda659afc05b7767d7e3adaefd0c0610a055c (patch)
tree4840082f85b8f6c93ec34593ee20f208c1e59d5d /dynamic-layers/clang-layer/recipes-core/ispc/ispc/0001-CMakeLists.txt-allow-to-pick-llvm-config-from-usr-bi.patch
parentf709b3f2b05e2ac73c6734dc2a213382b5eaf579 (diff)
downloadmeta-intel-a19fda659afc05b7767d7e3adaefd0c0610a055c.tar.gz
ispc: fix recipe
There are few problems in current recipe: (1) ispc needs to invoke native llvm-config from target sysroot to list LLVM lib libraries. clang already provides crossscripts/llvm-config, which does the job. However, using LLVM_TOOLS_BINARY_DIR leads to wrong llvm-config being used. So remove it from search path for llvm-config. (2) Error: ispc/1.17.0-r0/recipe-sysroot-native/usr/bin/x86_64-poky-linux/x86_64-poky-linux-ld: ispc/1.17.0-r0/recipe-sysroot-native/usr/lib/libclang-cpp.so: undefined reference to `std::condition_variable::wait(std::unique_lock<std::mutex>&)@GLIBCXX_3.4.30' error: linker command failed with exit code 1 (use -v to see invocation) Native libraries were being linked to target libraries leading to this failure. Fix and cleanup DEPENDS/RDEPENDS. Signed-off-by: Naveen Saini <naveen.kumar.saini@intel.com> Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
Diffstat (limited to 'dynamic-layers/clang-layer/recipes-core/ispc/ispc/0001-CMakeLists.txt-allow-to-pick-llvm-config-from-usr-bi.patch')
-rw-r--r--dynamic-layers/clang-layer/recipes-core/ispc/ispc/0001-CMakeLists.txt-allow-to-pick-llvm-config-from-usr-bi.patch37
1 files changed, 37 insertions, 0 deletions
diff --git a/dynamic-layers/clang-layer/recipes-core/ispc/ispc/0001-CMakeLists.txt-allow-to-pick-llvm-config-from-usr-bi.patch b/dynamic-layers/clang-layer/recipes-core/ispc/ispc/0001-CMakeLists.txt-allow-to-pick-llvm-config-from-usr-bi.patch
new file mode 100644
index 00000000..79e8e683
--- /dev/null
+++ b/dynamic-layers/clang-layer/recipes-core/ispc/ispc/0001-CMakeLists.txt-allow-to-pick-llvm-config-from-usr-bi.patch
@@ -0,0 +1,37 @@
1From 51d248d3b470f3fa1cf2ed3f5742851091acb65f Mon Sep 17 00:00:00 2001
2From: Naveen Saini <naveen.kumar.saini@intel.com>
3Date: Fri, 12 May 2023 09:10:11 +0800
4Subject: [PATCH] CMakeLists.txt: allow to pick llvm-config from
5 usr/bin/crossscripts/
6
7ispc needs to invoke native llvm-config from target sysroot to list LLVM
8lib libraries. clang already provides crossscripts/llvm-config, which does
9the job.
10
11However, using LLVM_TOOLS_BINARY_DIR leads to wrong llvm-config being
12used. So remove it from search path for llvm-config.
13
14Upstream-Status: Inappropriate
15
16Signed-off-by: Naveen Saini <naveen.kumar.saini@intel.com>
17---
18 cmake/FindLLVM.cmake | 3 +--
19 1 file changed, 1 insertion(+), 2 deletions(-)
20
21diff --git a/cmake/FindLLVM.cmake b/cmake/FindLLVM.cmake
22index d0297d5d..90d9fed2 100644
23--- a/cmake/FindLLVM.cmake
24+++ b/cmake/FindLLVM.cmake
25@@ -41,8 +41,7 @@ find_package(LLVM REQUIRED CONFIG)
26 set(LLVM_VERSION "LLVM_${LLVM_VERSION_MAJOR}_${LLVM_VERSION_MINOR}")
27 message(STATUS "Found LLVM ${LLVM_VERSION}")
28
29-find_program(LLVM_CONFIG_EXECUTABLE NAMES llvm-config
30- PATHS ${LLVM_TOOLS_BINARY_DIR} PATH_SUFFIXES bin NO_DEFAULT_PATH)
31+find_program(LLVM_CONFIG_EXECUTABLE NAMES llvm-config)
32 if (NOT LLVM_CONFIG_EXECUTABLE)
33 message(FATAL_ERROR "Failed to find llvm-config")
34 endif()
35--
362.37.3
37