2fd8d4df94
```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 ```
29 lines
760 B
Bash
29 lines
760 B
Bash
# Template file for 'openbsd-file'
|
|
pkgname=openbsd-file
|
|
version=6.2
|
|
revision=3
|
|
wrksrc="file-${version}"
|
|
build_style=gnu-configure
|
|
configure_args="--program-prefix=openbsd-"
|
|
hostmakedepends="automake libtool"
|
|
short_desc="Portable version of OpenBSD's privsep/sandboxed file(1) utility"
|
|
maintainer="Juan RP <xtraeme@gmail.com>"
|
|
license="ISC"
|
|
homepage="https://github.com/brynet/file/"
|
|
distfiles="https://github.com/brynet/file/archive/v${version}.tar.gz"
|
|
checksum=f6bf601f513bd83038e343bbd93b7982f373669a2ffa76dc52d48fa7251515b2
|
|
|
|
system_accounts="_file"
|
|
|
|
if [ "$XBPS_TARGET_LIBC" = "musl" ]; then
|
|
CFLAGS="-DREG_STARTEND=0"
|
|
makedepends+=" musl-legacy-compat"
|
|
fi
|
|
|
|
pre_configure() {
|
|
autoreconf -fi
|
|
}
|
|
post_install() {
|
|
vinstall magic 444 /etc
|
|
vlicense LICENSE
|
|
}
|