llvm: enable building clang-tools-extra and new subpkg.

This commit is contained in:
Christian Neukirchen 2016-08-30 15:49:44 +02:00
parent d4a2f43248
commit 595cc1d1dd
2 changed files with 20 additions and 3 deletions

1
srcpkgs/clang-tools-extra Symbolic link
View File

@ -0,0 +1 @@
llvm

View File

@ -1,7 +1,7 @@
# Template file for 'llvm'
pkgname=llvm
version=3.8.1
revision=2
revision=3
wrksrc="llvm-${version}.src"
lib32disabled=yes
build_style=cmake
@ -38,7 +38,7 @@ hostmakedepends="groff perl python zlib-devel libffi-devel swig"
makedepends="python-devel zlib-devel libffi-devel libedit-devel libxml2-devel binutils-devel"
depends="libllvm3.8"
subpackages="clang clang-analyzer libllvm3.8"
subpackages="clang-tools-extra clang clang-analyzer libllvm3.8"
if [ -z "$CROSS_BUILD" ]; then
# XXX fails to cross compile due to python
subpackages+=" lldb lldb-devel"
@ -84,7 +84,7 @@ post_extract() {
fi
# Move clang-tools-extra files into llvm source.
if [ -d ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ]; then
mv ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ${wrksrc}/tools/clang/extra
mv ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ${wrksrc}/tools/clang/tools/extra
fi
# Move lld files into the llvm source.
if [ -d ${XBPS_BUILDDIR}/lld-${version}.src ]; then
@ -176,6 +176,22 @@ clang-analyzer_package() {
vmove "/usr/libexec/*analyzer"
}
}
clang-tools-extra_package() {
depends="clang-${version}_${revision} python"
homepage="http://clang.llvm.org/extra/"
pkg_install() {
vmove usr/bin/clang-apply-replacements
vmove usr/bin/clang-query
vmove usr/bin/clang-rename
vmove usr/bin/clang-tidy
vmove usr/bin/modularize
vmove "usr/lib/libclangApplyReplacements*"
vmove "usr/lib/libclangQuery*"
vmove "usr/lib/libclangRename*"
vmove "usr/lib/libclangTidy*"
vmove "usr/share/clang/*tidy*"
}
}
clang_package() {
lib32disabled=yes
depends="libstdc++-devel libgcc-devel binutils"