Split base/llvm package into base/llvm,clang,lld Updated base buildlist Discarded old heavybuilds/firefox patch
74 lines
2.7 KiB
Bash
74 lines
2.7 KiB
Bash
# Maintainer: PktSurf <smlinux@pktsurf.in>
|
|
app=clang
|
|
version=17.0.6
|
|
build=1sml
|
|
homepage="http://llvm.org/"
|
|
download="https://github.com/llvm/llvm-project/releases/download/llvmorg-$version/llvm-$version.src.tar.xz"
|
|
desc="Clang from LLVM compiler toolkit"
|
|
requires="libffi libxml2 perl cmake"
|
|
|
|
prepbuilddir() {
|
|
mkandenterbuilddir
|
|
rm -rf $app-$version.src
|
|
|
|
tar xf $srcdir/$app-$version.src.tar.?z*
|
|
cd $app-$version.src
|
|
|
|
(
|
|
cd ../
|
|
tar xf $srcdir/cmake-$version.src.tar.?z*
|
|
mv cmake-$version.src cmake
|
|
)
|
|
|
|
tar xf $srcdir/clang-tools-extra-$version.src.tar.?z*
|
|
mv clang-tools-extra-$version.src tools/extra
|
|
|
|
tar xf $srcdir/third-party-$version.src.tar.?z*
|
|
mv third-party-$version.src third-party
|
|
|
|
tar xf $srcdir/clang-tools-extra-$version.src.tar.?z*
|
|
mv clang-tools-extra-$version.src tools/extra
|
|
fixbuilddirpermissions
|
|
|
|
applypatch $srcdir/10-add-musl-triples.patch
|
|
applypatch $srcdir/clang-003-as-needed.patch
|
|
}
|
|
|
|
build() {
|
|
unset CFLAGS CXXFLAGS
|
|
|
|
mkdir -p build
|
|
cmake -B build -G Ninja -Wno-dev \
|
|
-DCMAKE_BUILD_TYPE=Release \
|
|
-DCLANG_BUILT_STANDALONE=ON \
|
|
-DCLANG_CONFIG_FILE_SYSTEM_DIR=/etc/clang \
|
|
-DCLANG_DEFAULT_PIE_ON_LINUX=ON \
|
|
-DCLANG_INCLUDE_TESTS=OFF \
|
|
-DCLANG_LINK_CLANG_DYLIB=ON \
|
|
-DCLANG_PLUGIN_SUPPORT=ON \
|
|
-DCMAKE_INSTALL_PREFIX=/usr \
|
|
-DENABLE_LINKER_BUILD_ID=ON \
|
|
-DLLVM_INCLUDE_TESTS=OFF \
|
|
-DLLVM_ENABLE_RTTI=ON \
|
|
-DLLVM_LINK_LLVM_DYLIB=ON \
|
|
-DLLVM_MAIN_SRC_DIR=../../llvm-$version.src \
|
|
-DCMAKE_MODULE_PATH=../cmake/Modules
|
|
|
|
ninja -C build clang-tblgen
|
|
ninja -C build
|
|
DESTDIR=$pkg cmake --install build
|
|
|
|
cp LICENSE.TXT $pkgdocs/
|
|
|
|
mkfinalpkg
|
|
}
|
|
|
|
sha512sums="
|
|
9dee9b2897f8bc9eeb86cd726df706d6451f223bfc612c2c722aca3b70495546688bb28f6d6753e177731cb041d6a78d407a00215317d6cb17e56671c09ead59 clang-17.0.6.src.tar.lz
|
|
7c9b0def78f84fa6f2a5ef2a0f780d81638b27f1f40aaf98e199710404dfbc95d500a59a5dcc7714b8a472b9f259ceb42cc92412a6fcefdcd2f675b38ffb3485 clang-tools-extra-17.0.6.src.tar.lz
|
|
4ea1adcd10729f73e84d00e5800cb2f40daf7c3c91d6717fc7572d2db95902c927daed0b403c660beae673973431aecf854eeafa966bd2145ee917a8b090f78a cmake-17.0.6.src.tar.lz
|
|
0eb60df337875c110dfac112f6bb4e7686919f09c8e007b77a9f6e0f723c31721f09902e7b8bed07acea00aa5c02e07e3aee756fdf0caf74f01c4f9488107bbf llvm-17.0.6.src.tar.lz
|
|
242dada4800c5e558f5f243e6aa0905d90ca3f82cc81baf14c60de543a7e737d4c2f3471122f2c641dc4f0724e4ebf5cf137761a231b34aab2a12f1cfc902c53 third-party-17.0.6.src.tar.xz
|
|
606e7938a1f3402e38cbf38667154352e9e695f8120fa837836107d9878a152b3758ce4658f3192d6a509df3ead803a69c4f8ca599819331c7518f3479f8333d 10-add-musl-triples.patch
|
|
5f98f147d7d66315e9a56ae6fee602a053d40e57a8b1ee4f2ef1764203bb6fdb9082c8e825c535a9388213a38b49d2702b1e936fcf56560c4a2a56b7e6dd232c clang-003-as-needed.patch
|
|
"
|