pkgname=pacman
pkgver=6.1.0
pkgrel=8
arch=('armv7h' 'aarch64')
license=('unknown')
source=("$pkgname-release-6.1.x.tar.gz"
"0001-Initial-asignify-support.patch"
"0001-makepkg-check-for-usr-lib64.patch"
"makepkg.conf"
"pacman.conf")
depends=(bash glibc libarchive curl gettext gawk coreutils grep openssl asignify)
makedepends=(meson)
provides=('libalpm.so')
backup=(etc/pacman.conf
etc/makepkg.conf)
prepare() {
cd "$pkgname-release-6.1.x"
patch -Np1 -i ../0001-Initial-asignify-support.patch
patch -Np1 -i ../0001-makepkg-check-for-usr-lib64.patch
}
build() {
cd "$pkgname-release-6.1.x"
mkdir -p build
cd build
meson --prefix=/usr \
-Dcrypto=openssl \
-Dgpgme=disabled \
-Dasignify=enabled \
-Ddebug-suffix=dbginfo
# "-debug-" clashes with some package(s) (ruby-debug IIRC)
ninja
}
package() {
cd "$pkgname-release-6.1.x/build"
DESTDIR="$pkgdir" ninja install
# install Arch specific stuff
install -dm755 "$pkgdir/etc"
install -m644 "$srcdir/pacman.conf" "$pkgdir/etc"
case $CARCH in
armv7h)
mycarch="armv7h"
mychost="armv7l-unknown-linux-gnueabihf"
myflags="-march=armv7ve -mfloat-abi=hard -mfpu=neon-vfp4 -mtune=cortex-a17 "
myrflag="-C target-cpu=cortex-a17"
;;
aarch64)
mycarch="aarch64"
mychost="aarch64-unknown-linux-gnu"
myflags="-march=armv8-a "
myrflag=""
;;
esac
install -m644 "$srcdir/makepkg.conf" "$pkgdir/etc"
sed -i "$pkgdir/etc/makepkg.conf" \
-e "s|@CARCH[@]|$mycarch|g" \
-e "s|@CHOST[@]|$mychost|g" \
-e "s|@CARCHFLAGS[@]|$myflags|g" \
-e "s|@RUSTFLAGS[@]|$myrflag|g"
sed -i $pkgdir/etc/pacman.conf -e "s|@CARCH[@]|$mycarch|g"
}
sha256sums=('b15679b7b751992d8d8f2acfa94f0c381d71d8289e5ac9f89cb6ddb88306c788'
'6303db37b0b91953228e8a11d1bf4984b2514cbe9713588da8bd646375ae0e15'
'703e94b641a824d3e44f94d5ffc314ed1a6bfe97f3e11be9cf990a86a7bdcb73'
'a00bdc563a2190d5965d1c44e907944372b63fa17a81212ce7dd7bcfaf6d63ef'
'7226a5b2cdf7d3b2f697620c5a5637566e791e003ee605106c2c9ab8ceb13384')