rjw | 1f88458 | 2022-01-06 17:20:42 +0800 | [diff] [blame^] | 1 | # Copyright (C) 2017 Kai Ruhnau <kai.ruhnau@target-sg.com> |
| 2 | # Released under the MIT license (see COPYING.MIT for the terms) |
| 3 | |
| 4 | DESCRIPTION = "Next generation, high-performance debugger" |
| 5 | HOMEPAGE = "http://lldb.llvm.org/" |
| 6 | LICENSE = "MIT | NCSA" |
| 7 | SECTION = "devel" |
| 8 | |
| 9 | DEPENDS += "clang-native zlib libxml2 ninja-native" |
| 10 | |
| 11 | require clang.inc |
| 12 | require common-source.inc |
| 13 | |
| 14 | inherit cmake pkgconfig |
| 15 | |
| 16 | LIC_FILES_CHKSUM = "file://llvm/LICENSE.TXT;md5=${LLVMMD5SUM}; \ |
| 17 | file://clang/LICENSE.TXT;md5=${CLANGMD5SUM}; \ |
| 18 | file://lldb/LICENSE.TXT;md5=${LLDBMD5SUM}; \ |
| 19 | " |
| 20 | |
| 21 | OECMAKE_FIND_ROOT_PATH_MODE_PROGRAM = "BOTH" |
| 22 | |
| 23 | EXTRA_OECMAKE="\ |
| 24 | -DCMAKE_CROSSCOMPILING=1 \ |
| 25 | -DLLVM_ENABLE_CXX11=ON \ |
| 26 | -DLLVM_BUILD_LLVM_DYLIB=ON \ |
| 27 | -DBUILD_SHARED_LIBS=OFF \ |
| 28 | -DLLVM_BUILD_LLVM_DYLIB=ON \ |
| 29 | -DLLVM_ENABLE_PIC=ON \ |
| 30 | -DLLDB_DISABLE_LIBEDIT=1 \ |
| 31 | -DLLDB_DISABLE_CURSES=1 \ |
| 32 | -DLLDB_DISABLE_PYTHON=1 \ |
| 33 | -DLLVM_ENABLE_TERMINFO=0 \ |
| 34 | -DLLVM_TABLEGEN=${STAGING_BINDIR_NATIVE}/llvm-tblgen \ |
| 35 | -DCLANG_TABLEGEN=${STAGING_BINDIR_NATIVE}/clang-tblgen \ |
| 36 | -DLLVM_HOST_TRIPLE=${TARGET_SYS} \ |
| 37 | -DLLDB_TEST_USE_CUSTOM_C_COMPILER=ON \ |
| 38 | -DLLDB_TEST_USE_CUSTOM_CXX_COMPILER=ON \ |
| 39 | -DLLDB_TEST_C_COMPILER='${CC}' \ |
| 40 | -DLLDB_TEST_CXX_COMPILER='${CXX}' \ |
| 41 | -DCMAKE_BUILD_TYPE=Release \ |
| 42 | -DLLVM_ENABLE_PROJECTS='clang;lldb' \ |
| 43 | -G Ninja ${S}/llvm \ |
| 44 | " |
| 45 | |
| 46 | EXTRA_OEMAKE = "VERBOSE=1" |
| 47 | |
| 48 | do_compile() { |
| 49 | ninja ${PARALLEL_MAKE} lldb |
| 50 | } |
| 51 | |
| 52 | do_install() { |
| 53 | DESTDIR=${D} ninja ${PARALLEL_MAKE} tools/lldb/install |
| 54 | } |
| 55 | |
| 56 | INSANE_SKIP_${PN}-dbg = "libdir" |
| 57 | INSANE_SKIP_${PN} = "libdir" |