2022-11-05 02:24:21 +00:00
|
|
|
# Maintainer: Levente Polyak <anthraxx[at]archlinux[dot]org>
|
|
|
|
# Maintainer: Morten Linderud <foxboron@archlinux.org>
|
2010-07-10 01:32:36 +00:00
|
|
|
|
2012-01-17 22:38:54 +00:00
|
|
|
# ALARM: Kevin Mihelich <kevin@archlinuxarm.org>
|
2024-03-16 00:14:20 +00:00
|
|
|
# - arch/host/flags for armv7h, and aarch64
|
|
|
|
# - pacman.conf: architecture=armv7h/aarch64, added our aur and alarm repos
|
|
|
|
# - makepkg.conf: adjusted C/CXX/LDFLAGS
|
2014-04-23 00:34:32 +00:00
|
|
|
# - patch to sync filesystem after install/remove
|
2016-03-12 03:16:56 +00:00
|
|
|
# - reverts to allow scriplet input on stdin
|
2019-05-21 01:01:49 +00:00
|
|
|
# - patch to fix application/gzip change in file 5.37
|
2011-02-06 20:16:05 +00:00
|
|
|
|
2009-10-08 03:40:19 +00:00
|
|
|
pkgname=pacman
|
2024-09-14 14:26:41 +00:00
|
|
|
pkgver=7.0.0.r3.g7736133
|
|
|
|
pkgrel=1
|
|
|
|
# use annotated tag and patch level commit from release branch (can be empty for no patches)
|
|
|
|
_git_tag=7.0.0
|
|
|
|
_git_patch_level_commit=77361331ae3864c6ea880e715c5864d59336f275
|
2009-10-08 03:40:19 +00:00
|
|
|
pkgdesc="A library-based package manager with dependency support"
|
2018-05-03 12:33:23 +00:00
|
|
|
arch=('x86_64')
|
2019-03-01 03:38:38 +00:00
|
|
|
url="https://www.archlinux.org/pacman/"
|
2024-02-08 00:31:02 +00:00
|
|
|
license=('GPL-2.0-or-later')
|
2024-09-14 14:26:41 +00:00
|
|
|
depends=(
|
|
|
|
bash
|
|
|
|
coreutils
|
|
|
|
curl
|
|
|
|
gawk
|
|
|
|
gettext
|
|
|
|
glibc
|
|
|
|
gnupg
|
|
|
|
gpgme
|
|
|
|
grep
|
|
|
|
libarchive
|
|
|
|
pacman-mirrorlist
|
|
|
|
systemd
|
|
|
|
)
|
|
|
|
makedepends=(
|
|
|
|
asciidoc
|
|
|
|
doxygen
|
|
|
|
git
|
|
|
|
meson
|
|
|
|
)
|
|
|
|
checkdepends=(
|
|
|
|
fakechroot
|
|
|
|
python
|
|
|
|
)
|
|
|
|
optdepends=(
|
|
|
|
'base-devel: required to use makepkg'
|
|
|
|
'perl-locale-gettext: translation support in makepkg-template'
|
|
|
|
)
|
2019-10-23 12:52:21 +00:00
|
|
|
provides=('libalpm.so')
|
2019-01-10 13:32:21 +00:00
|
|
|
backup=(etc/pacman.conf
|
2024-09-14 14:26:41 +00:00
|
|
|
etc/makepkg.conf
|
|
|
|
etc/makepkg.conf.d/rust.conf)
|
2017-06-16 01:07:31 +00:00
|
|
|
validpgpkeys=('6645B0A8C7005E78DB1D7864F99FFE0FEAE999BD' # Allan McRae <allan@archlinux.org>
|
|
|
|
'B8151B117037781095514CA7BBDFFC92306B1121') # Andrew Gregory (pacman) <andrew@archlinux.org>
|
2024-09-14 14:26:41 +00:00
|
|
|
source=("git+https://gitlab.archlinux.org/pacman/pacman.git#tag=v${_git_tag}?signed"
|
2024-03-16 00:14:20 +00:00
|
|
|
revertme-makepkg-remove-libdepends-and-libprovides.patch::https://gitlab.archlinux.org/pacman/pacman/-/commit/354a300cd26bb1c7e6551473596be5ecced921de.patch
|
2014-04-23 00:34:32 +00:00
|
|
|
0001-Sychronize-filesystem.patch
|
2016-02-01 13:19:58 +00:00
|
|
|
0002-Revert-close-stdin-before-running-install-scripts.patch
|
2016-03-12 03:16:56 +00:00
|
|
|
0003-Revert-alpm_run_chroot-always-connect-parent2child-p.patch
|
2009-11-16 19:07:36 +00:00
|
|
|
pacman.conf
|
2024-09-14 14:26:41 +00:00
|
|
|
makepkg.conf
|
|
|
|
alpm.sysusers
|
|
|
|
rust.conf)
|
|
|
|
sha256sums=('06d082c3ce6f0811ca728515aa82d69d372800bd3ada99f5c445ef9429b6e3a6'
|
2024-03-16 00:14:20 +00:00
|
|
|
'b3bce9d662e189e8e49013b818f255d08494a57e13fc264625f852f087d3def2'
|
2024-09-14 14:26:41 +00:00
|
|
|
'e055c072608bac62f6d74ab980b3851ac740ae476847de2f5dd5021fd97613ab'
|
|
|
|
'b36c4975286f8dea0fc3c64abf52706c31cb6d6e2c05a4983834b5417e23e802'
|
|
|
|
'7ea05a9457f3b6b1edd9dc82f8a1231b0b9048e8c0a7e75fb99abb330a304234'
|
|
|
|
'f3d8a177092afdd883e9eb20977807d6a3e9a6f4a3874490dab7c1a1a2adf3f0'
|
|
|
|
'1fae8471726bbda9521ce4d54f9fc646751d450cc4c9e6ebcae5eaeaf4909efe'
|
|
|
|
'c8760d7ebb6c9817d508c691c67084be251cd9c8811ee1ccf92c1278bad74c1c'
|
|
|
|
'3d7579f4fa52ef512dc82187c010f273aa45e6e8349f8fda9839f808c7dae042')
|
|
|
|
|
|
|
|
pkgver() {
|
|
|
|
cd "$pkgname"
|
|
|
|
git describe --abbrev=7 --match 'v*' | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g'
|
|
|
|
}
|
2014-04-23 00:34:32 +00:00
|
|
|
|
|
|
|
prepare() {
|
2024-09-14 14:26:41 +00:00
|
|
|
cd "$pkgname"
|
|
|
|
|
|
|
|
# apply patch level commits on top of annotated tag
|
|
|
|
if [[ -n ${_git_patch_level_commit} ]]; then
|
|
|
|
if [[ v${_git_tag} != $(git describe --tags --abbrev=0 "${_git_patch_level_commit}") ]]; then
|
|
|
|
error "patch level commit ${_git_patch_level_commit} is not a descendant of v${_git_tag}"
|
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
git rebase "${_git_patch_level_commit}"
|
|
|
|
fi
|
2024-03-16 00:14:20 +00:00
|
|
|
|
|
|
|
# handle patches
|
|
|
|
local -a patches
|
|
|
|
patches=($(printf '%s\n' "${source[@]}" | grep '.patch'))
|
|
|
|
patches=("${patches[@]%%::*}")
|
|
|
|
patches=("${patches[@]##*/}")
|
|
|
|
|
|
|
|
if (( ${#patches[@]} != 0 )); then
|
|
|
|
for patch in "${patches[@]}"; do
|
|
|
|
if [[ $patch =~ revertme-* ]]; then
|
|
|
|
msg2 "Reverting patch $patch..."
|
|
|
|
patch -RNp1 < "../$patch"
|
|
|
|
else
|
|
|
|
msg2 "Applying patch $patch..."
|
|
|
|
patch -Np1 < "../$patch"
|
|
|
|
fi
|
|
|
|
done
|
|
|
|
fi
|
2014-04-23 00:34:32 +00:00
|
|
|
}
|
2010-04-27 01:52:11 +00:00
|
|
|
|
2009-10-08 03:40:19 +00:00
|
|
|
build() {
|
2024-09-14 14:26:41 +00:00
|
|
|
cd "$pkgname"
|
2011-08-14 16:34:13 +00:00
|
|
|
|
2021-06-01 18:57:01 +00:00
|
|
|
meson --prefix=/usr \
|
|
|
|
--buildtype=plain \
|
|
|
|
-Ddoc=enabled \
|
|
|
|
-Ddoxygen=enabled \
|
|
|
|
-Dscriptlet-shell=/usr/bin/bash \
|
|
|
|
-Dldconfig=/usr/bin/ldconfig \
|
|
|
|
build
|
|
|
|
|
|
|
|
meson compile -C build
|
2009-12-07 20:25:36 +00:00
|
|
|
}
|
|
|
|
|
2012-02-14 14:35:38 +00:00
|
|
|
check() {
|
2024-09-14 14:26:41 +00:00
|
|
|
cd "$pkgname"
|
2021-06-01 18:57:01 +00:00
|
|
|
|
|
|
|
meson test -C build
|
2012-02-14 14:35:38 +00:00
|
|
|
}
|
|
|
|
|
2009-12-07 20:25:36 +00:00
|
|
|
package() {
|
2024-09-14 14:26:41 +00:00
|
|
|
cd "$pkgname"
|
2014-05-09 01:55:26 +00:00
|
|
|
|
2021-06-01 18:57:01 +00:00
|
|
|
DESTDIR="$pkgdir" meson install -C build
|
2009-10-08 03:40:19 +00:00
|
|
|
|
2009-12-07 20:25:36 +00:00
|
|
|
# install Arch specific stuff
|
2014-05-09 01:55:26 +00:00
|
|
|
install -dm755 "$pkgdir/etc"
|
2018-05-29 00:53:59 +00:00
|
|
|
install -m644 "$srcdir/pacman.conf" "$pkgdir/etc"
|
2024-09-14 14:26:41 +00:00
|
|
|
install -D -m644 "$srcdir/alpm.sysusers" "${pkgdir}"/usr/lib/sysusers.d/alpm.conf
|
|
|
|
install -m644 "$srcdir/rust.conf" "$pkgdir/etc/makepkg.conf.d"
|
2014-05-09 01:55:26 +00:00
|
|
|
|
|
|
|
case $CARCH in
|
2011-06-22 00:48:50 +00:00
|
|
|
armv7h)
|
|
|
|
mycarch="armv7h"
|
2012-07-08 17:41:39 +00:00
|
|
|
mychost="armv7l-unknown-linux-gnueabihf"
|
2022-02-07 03:10:09 +00:00
|
|
|
myflags="-march=armv7-a -mfloat-abi=hard -mfpu=neon "
|
2011-05-02 02:46:30 +00:00
|
|
|
;;
|
2015-07-05 01:43:31 +00:00
|
|
|
aarch64)
|
|
|
|
mycarch="aarch64"
|
|
|
|
mychost="aarch64-unknown-linux-gnu"
|
|
|
|
myflags="-march=armv8-a "
|
|
|
|
;;
|
2011-05-02 02:46:30 +00:00
|
|
|
esac
|
2014-05-09 01:55:26 +00:00
|
|
|
|
|
|
|
install -m644 "$srcdir/makepkg.conf" "$pkgdir/etc"
|
|
|
|
sed -i "$pkgdir/etc/makepkg.conf" \
|
2011-02-06 20:13:24 +00:00
|
|
|
-e "s|@CARCH[@]|$mycarch|g" \
|
|
|
|
-e "s|@CHOST[@]|$mychost|g" \
|
|
|
|
-e "s|@CARCHFLAGS[@]|$myflags|g"
|
2012-01-17 22:38:54 +00:00
|
|
|
sed -i $pkgdir/etc/pacman.conf -e "s|@CARCH[@]|$mycarch|g"
|
2024-02-08 00:31:02 +00:00
|
|
|
|
|
|
|
local wantsdir="$pkgdir/usr/lib/systemd/system/sockets.target.wants"
|
|
|
|
install -dm755 "$wantsdir"
|
|
|
|
|
|
|
|
local unit
|
|
|
|
for unit in dirmngr gpg-agent gpg-agent-{browser,extra,ssh} keyboxd; do
|
|
|
|
ln -s "../${unit}@.socket" "$wantsdir/${unit}@etc-pacman.d-gnupg.socket"
|
|
|
|
done
|
2009-10-08 03:40:19 +00:00
|
|
|
}
|
2023-09-26 23:20:59 +00:00
|
|
|
|
|
|
|
# vim: set ts=2 sw=2 et:
|