mirror of
https://git.yoctoproject.org/poky
synced 2026-09-19 18:49:32 +02:00
lldb: add new recipe, split out of clang
LLDB takes a reasonable amount of time to compile, but also isn't an essential component of the LLVM suite. Instead of always building it when we build clang, split it out into a separate recipe. On my build machine where clang takes 21 minutes to build with lldb, it takes 19 minutes without lldb. (From OE-Core rev: 9da4900aa5a37718bd42f277d5a1805ec897b1b4) Signed-off-by: Ross Burton <ross.burton@arm.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
bd3792a7ad
commit
322fc2fc75
53
meta/recipes-devtools/clang/lldb_git.bb
Normal file
53
meta/recipes-devtools/clang/lldb_git.bb
Normal file
@@ -0,0 +1,53 @@
|
||||
SUMMARY = "LLDB"
|
||||
DESCRIPTION = "LLDB is a next generation, high-performance debugger."
|
||||
HOMEPAGE = "https://lldb.llvm.org"
|
||||
SECTION = "devel"
|
||||
|
||||
require common-clang.inc
|
||||
require common-source.inc
|
||||
|
||||
COMPATIBLE_HOST = "(x86_64|i.86|arm|aarch64|powerpc64).*-linux"
|
||||
|
||||
LIC_FILES_CHKSUM = "file://lldb/LICENSE.TXT;md5=2e0d44968471fcde980034dbb826bea9"
|
||||
|
||||
inherit cmake pkgconfig python3native python3targetconfig
|
||||
|
||||
# This actually just depends on LLVM but right now llvm and clang are built together
|
||||
DEPENDS = "llvm-tblgen-native clang"
|
||||
|
||||
OECMAKE_SOURCEPATH = "${S}/lldb"
|
||||
|
||||
EXTRA_OECMAKE = "-DLLDB_INCLUDE_TESTS=OFF \
|
||||
-DLLDB_ENABLE_LUA=OFF \
|
||||
-DLLDB_PYTHON_RELATIVE_PATH=${PYTHON_SITEPACKAGES_DIR} \
|
||||
-DLLDB_PYTHON_EXE_RELATIVE_PATH=${PYTHON_PN} \
|
||||
-DLLDB_PYTHON_EXT_SUFFIX=${SOLIBSDEV} \
|
||||
-DLLVM_DIR=${STAGING_LIBDIR}/cmake/llvm/ \
|
||||
-DLLVM_TABLEGEN=${STAGING_BINDIR_NATIVE}/llvm-tblgen \
|
||||
-DLLDB_TABLEGEN_EXE=${STAGING_BINDIR_NATIVE}/lldb-tblgen \
|
||||
"
|
||||
|
||||
PACKAGECONFIG ??= "libedit libxml2 lzma"
|
||||
PACKAGECONFIG[libedit] = "-DLLDB_ENABLE_LIBEDIT=ON,-DLLDB_ENABLE_LIBEDIT=OFF,libedit"
|
||||
PACKAGECONFIG[libxml2] = "-DLLDB_ENABLE_LIBXML2=ON,-DLLDB_ENABLE_LIBXML2=OFF,libxml2"
|
||||
PACKAGECONFIG[lzma] = "-DLLDB_ENABLE_LLDB_ENABLE_LZMA=ON,-DLLDB_ENABLE_LLDB_ENABLE_LZMA=OFF,xz"
|
||||
PACKAGECONFIG[python] = "-DLLDB_ENABLE_PYTHON=ON,-DLLDB_ENABLE_PYTHON=OFF,swig-native"
|
||||
|
||||
do_install:append() {
|
||||
if ${@bb.utils.contains('PACKAGECONFIG', 'python', 'true', 'false', d)}; then
|
||||
# Fix a bad symlink that points to the -dev .so
|
||||
rm -f ${D}${PYTHON_SITEPACKAGES_DIR}/lldb/_lldb.so
|
||||
ln -s ${libdir}/liblldb.so.${MAJOR_VER}.${MINOR_VER} ${D}${PYTHON_SITEPACKAGES_DIR}/lldb/_lldb.so
|
||||
fi
|
||||
}
|
||||
|
||||
PACKAGES =+ "${PN}-python ${PN}-server"
|
||||
|
||||
FILES:${PN}-python = "${PYTHON_SITEPACKAGES_DIR}"
|
||||
RDEPENDS:${PN}-python = "${PN}"
|
||||
# This has a symlink to the lldb library
|
||||
INSANE_SKIP:${PN}-python = "dev-so"
|
||||
|
||||
FILES:${PN}-server = "${bindir}/lldb-server"
|
||||
|
||||
BBCLASSEXTEND = "native nativesdk"
|
||||
Reference in New Issue
Block a user