summaryrefslogtreecommitdiffstats
path: root/recipes-devtools
diff options
context:
space:
mode:
authorKhem Raj <raj.khem@gmail.com>2021-05-28 17:37:52 -0700
committerKhem Raj <raj.khem@gmail.com>2021-06-08 11:37:54 -0700
commitc48de926ac54802df7e1e4b7f91caa4fa4ef45b1 (patch)
treea008b3b8fe30b212851797a2c5261ceec380562a /recipes-devtools
parent933795217f9142c246c359f92e8320516e5c66a5 (diff)
downloadmeta-clang-c48de926ac54802df7e1e4b7f91caa4fa4ef45b1.tar.gz
libunwind: Install headers and pkgconfig file
This ensures it can replace nongnu libunwind Use it only when selecting RUNTIME = "llvm" Signed-off-by: Khem Raj <raj.khem@gmail.com>
Diffstat (limited to 'recipes-devtools')
-rw-r--r--recipes-devtools/clang/clang/libunwind.pc.in9
-rw-r--r--recipes-devtools/clang/common.inc1
-rw-r--r--recipes-devtools/clang/libcxx_git.bb11
3 files changed, 21 insertions, 0 deletions
diff --git a/recipes-devtools/clang/clang/libunwind.pc.in b/recipes-devtools/clang/clang/libunwind.pc.in
new file mode 100644
index 0000000..a93d676
--- /dev/null
+++ b/recipes-devtools/clang/clang/libunwind.pc.in
@@ -0,0 +1,9 @@
1prefix=/usr
2exec_prefix=/usr
3libdir=@LIBDIR@
4includedir=/usr/include
5
6Name: libunwind
7Description: libunwind base library
8Version: @VERSION@
9Libs: -lunwind
diff --git a/recipes-devtools/clang/common.inc b/recipes-devtools/clang/common.inc
index d529c0d..ac96ef5 100644
--- a/recipes-devtools/clang/common.inc
+++ b/recipes-devtools/clang/common.inc
@@ -9,6 +9,7 @@ BASEURI ??= "${LLVM_GIT}/llvm-project;protocol=${LLVM_GIT_PROTOCOL};branch=${BRA
9SRC_URI = "\ 9SRC_URI = "\
10 ${BASEURI} \ 10 ${BASEURI} \
11 file://llvm-config \ 11 file://llvm-config \
12 file://libunwind.pc.in \
12 file://0001-lldb-Add-lxml2-to-linker-cmdline-of-xml-is-found.patch \ 13 file://0001-lldb-Add-lxml2-to-linker-cmdline-of-xml-is-found.patch \
13 file://0002-libcxxabi-Find-libunwind-headers-when-LIBCXXABI_LIBU.patch \ 14 file://0002-libcxxabi-Find-libunwind-headers-when-LIBCXXABI_LIBU.patch \
14 file://0003-compiler-rt-support-a-new-embedded-linux-target.patch \ 15 file://0003-compiler-rt-support-a-new-embedded-linux-target.patch \
diff --git a/recipes-devtools/clang/libcxx_git.bb b/recipes-devtools/clang/libcxx_git.bb
index dd87f1d..94e9311 100644
--- a/recipes-devtools/clang/libcxx_git.bb
+++ b/recipes-devtools/clang/libcxx_git.bb
@@ -70,5 +70,16 @@ ALLOW_EMPTY_${PN} = "1"
70 70
71PROVIDES += "${@bb.utils.contains("RUNTIME", "llvm", "libunwind", "", d)}" 71PROVIDES += "${@bb.utils.contains("RUNTIME", "llvm", "libunwind", "", d)}"
72 72
73
74do_install_append() {
75 if ${@bb.utils.contains("RUNTIME", "llvm", "true", "false", d)}
76 then
77 install -Dm 0644 ${S}/libunwind/include/libunwind.h ${S}/libunwind/include/__libunwind_config.h ${D}${includedir}
78 install -Dm 0644 ${S}/libunwind/include/unwind.h ${D}${includedir}/unwind.h
79 install -d ${D}${libdir}/pkgconfig
80 sed -e 's,@LIBDIR@,${libdir},g;s,@VERSION@,${PV},g' ${S}/../libunwind.pc.in > ${D}${libdir}/pkgconfig/libunwind.pc
81 fi
82}
83
73BBCLASSEXTEND = "native nativesdk" 84BBCLASSEXTEND = "native nativesdk"
74TOOLCHAIN = "clang" 85TOOLCHAIN = "clang"