void-packages/srcpkgs/numactl/template
Đoàn Trần Công Danh 65749575ab srcpkgs/n*: convert patches to -Np1
```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

43 lines
952 B
Bash

# Template file for 'numactl'
pkgname=numactl
version=2.0.14
revision=1
build_style=gnu-configure
hostmakedepends="automake libtool"
short_desc="Simple NUMA policy support"
maintainer="Anthony Iliopoulos <ailiop@altatus.com>"
license="LGPL-2.1-only"
homepage="https://github.com/numactl/numactl"
distfiles="https://github.com/numactl/numactl/archive/v${version}.tar.gz"
checksum=1ee27abd07ff6ba140aaf9bc6379b37825e54496e01d6f7343330cf1a4487035
if [ "$XBPS_TARGET_MACHINE" = "i686" ]; then
# XXX
nopie=yes
fi
pre_configure() {
autoreconf -fi
}
post_install() {
rm -r ${DESTDIR}/usr/share/man/man2
}
libnuma_package() {
short_desc+=" - runtime library"
pkg_install() {
vmove "usr/lib/*.so.*"
}
}
libnuma-devel_package() {
depends="libnuma>=${version}_${revision}"
short_desc+=" - development files"
pkg_install() {
vmove usr/include
vmove "usr/lib/*.a"
vmove "usr/lib/*.so"
vmove usr/share/man/man3
vmove usr/lib/pkgconfig
}
}