* add build2
This commit is contained in:
parent
b6bba894dc
commit
1b422a0828
19
build2/.SRCINFO
Normal file
19
build2/.SRCINFO
Normal file
@ -0,0 +1,19 @@
|
||||
pkgbase = build2
|
||||
pkgdesc = build2 build system
|
||||
pkgver = 0.16.0
|
||||
pkgrel = 2
|
||||
url = https://build2.org/
|
||||
arch = x86_64
|
||||
license = MIT
|
||||
makedepends = chrpath
|
||||
depends = gcc-libs
|
||||
depends = glibc
|
||||
depends = sqlite3
|
||||
source = https://download.build2.org/0.16.0/build2-toolchain-0.16.0.tar.xz
|
||||
source = https://github.com/build2/libpkg-config/commit/c8978943.patch
|
||||
source = https://github.com/build2/libpkg-config/commit/604eb708.patch
|
||||
sha256sums = 23793f682a17b1d95c80bbd849244735ed59a3e27361529aa4865d2776ff8adc
|
||||
sha256sums = 5b3fdcb4ec53c487aa005224ddbc6db02f078f01c1de530839cc8146026b6a7e
|
||||
sha256sums = 29c2eeff019c6d8b0ffd1bfcf74a02aacf96a2d3dd6df24e2b0b2d0b76d93f00
|
||||
|
||||
pkgname = build2
|
64
build2/PKGBUILD
Normal file
64
build2/PKGBUILD
Normal file
@ -0,0 +1,64 @@
|
||||
# POWER Maintainer: Alexander Baldeck <alex.bldck@gmail.com>
|
||||
# Maintainer:
|
||||
# Contributor: Miguel Revilla <yo at miguelrevilla dot com>
|
||||
# Contributor: Adrià Arrufat <swiftscythe@gmail.com>
|
||||
# Contributor: Filipe Verri <filipeverri@gmail.com>
|
||||
|
||||
pkgname=build2
|
||||
pkgver=0.16.0
|
||||
pkgrel=2
|
||||
pkgdesc='build2 build system'
|
||||
arch=(x86_64 powerpc64le powerpc64 powerpc riscv64)
|
||||
url='https://build2.org/'
|
||||
license=(MIT)
|
||||
makedepends=(chrpath)
|
||||
depends=(gcc-libs
|
||||
glibc
|
||||
sqlite3)
|
||||
options=(!ccache !distcc)
|
||||
source=(https://download.build2.org/$pkgver/build2-toolchain-$pkgver.tar.xz
|
||||
https://github.com/build2/libpkg-config/commit/c8978943.patch
|
||||
https://github.com/build2/libpkg-config/commit/604eb708.patch
|
||||
atomic-non-lock-free.patch)
|
||||
sha256sums=('23793f682a17b1d95c80bbd849244735ed59a3e27361529aa4865d2776ff8adc'
|
||||
'5b3fdcb4ec53c487aa005224ddbc6db02f078f01c1de530839cc8146026b6a7e'
|
||||
'29c2eeff019c6d8b0ffd1bfcf74a02aacf96a2d3dd6df24e2b0b2d0b76d93f00'
|
||||
'd02418f9212ca2909d250a9e14b88ce19911acfd4a0e312cbdb1141cb5222c29')
|
||||
|
||||
prepare() {
|
||||
# Fix build with glibc 2.38
|
||||
patch -d build2-toolchain-$pkgver -p1 < c8978943.patch
|
||||
patch -d build2-toolchain-$pkgver -p1 < 604eb708.patch
|
||||
|
||||
case "${CARCH}" in
|
||||
powerpc)
|
||||
# Avoid:
|
||||
#./libbuild2/target.hxx:1991:4: error: #error timestamp is not lock-free on this architecture
|
||||
# 1991 | # error timestamp is not lock-free on this architecture
|
||||
# ML post: https://lists.build2.org/archives/users/2020-July/000822.html
|
||||
patch -d build2-toolchain-$pkgver -p1 < atomic-non-lock-free.patch
|
||||
;;
|
||||
esac
|
||||
}
|
||||
|
||||
build() {
|
||||
mkdir -p build/usr
|
||||
cd build2-toolchain-$pkgver
|
||||
|
||||
case "${CARCH}" in
|
||||
powerpc)
|
||||
CXXFLAGS+=' -latomic'
|
||||
;;
|
||||
esac
|
||||
|
||||
./build.sh --trust yes --local --system libsqlite3,libpkgconfig --install-dir "$srcdir"/build/usr ${CXX:-g++} $CXXFLAGS $LDFLAGS
|
||||
|
||||
for f in "$srcdir"/build/usr/lib/pkgconfig/*.pc; do sed -i "s|$srcdir/build||" ${f}; done
|
||||
}
|
||||
|
||||
package() {
|
||||
cp -av build/usr "$pkgdir"
|
||||
chrpath -d "$pkgdir"/usr/bin/{b,bpkg,bdep} "$pkgdir"/usr/lib/*.so
|
||||
|
||||
install -Dm644 "$pkgdir"/usr/share/doc/build2/LICENSE -t "$pkgdir"/usr/share/licenses/$pkgname
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user