void-packages/srcpkgs/pacman/template
Đoàn Trần Công Danh 49cb564d14 srcpkgs/p*: convert patches to -Np1
* par is kept at -Np0

```sh
git grep -l '^patch_args=-Np0' "srcpkgs/$1*/template" |
while read template; do
	for p in ${template%/template}/patches/*; do
		sed -i '
			\,^[+-][+-][+-] /dev/null,b
			/^[*-]\+ [0-9]\+\(,[0-9]\+\)\? [*-]\+$/b
			s,^[*][*][*] ,&a/,
			/^--- /{
				s,\(^--- \)\(./\)*,\1a/,
				s,[.-][Oo][Rr][Ii][Gg]\([	/]\),\1,
				s/[.-][Oo][Rr][Ii][Gg]$//
				s/[.]patched[.]\([^.]\)/.\1/
				h
			}
			/^+++ -/{
				g
				s/^--- a/+++ b/
				b
			}
			s,\(^+++ \)\(./\)*,\1b/,
		' "$p"
	done
	sed -i '/^patch_args=/d' $template
done
```
2021-06-20 13:17:29 +07:00

27 lines
869 B
Bash

# Template file for 'pacman'
pkgname=pacman
version=5.2.2
revision=2
make_dirs="/var/lib/pacman 0755 root root
/usr/var/cache/pacman/pkg 0755 root root
/usr/share/libalpm/hooks 0755 root root"
conf_files="/etc/pacman.conf"
build_style=meson
hostmakedepends="autoconf automake curl libtool gettext-devel pkg-config asciidoc"
makedepends="libarchive-devel gpgme-devel libcurl-devel"
depends="gnupg2"
checkdepends="fakeroot"
short_desc="Simple library-based package manager"
maintainer="oreo639 <oreo6391@gmail.com>"
license="GPL-2.0-or-later"
homepage="https://www.archlinux.org/pacman/"
distfiles="https://sources.archlinux.org/other/pacman/pacman-${version}.tar.gz"
checksum=bb201a9f2fb53c28d011f661d50028efce6eef2c1d2a36728bdd0130189349a0
if [ "$XBPS_TARGET_LIBC" = musl ]; then
do_check() {
: fakechroot is not available
}
else
checkdepends+=" fakechroot"
fi