861ac185a6
```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 ```
32 lines
982 B
Bash
32 lines
982 B
Bash
# Template file for 'libselinux'
|
|
pkgname=libselinux
|
|
version=3.0
|
|
revision=1
|
|
build_style=gnu-makefile
|
|
make_install_args="SHLIBDIR=/usr/lib SBINDIR=/usr/bin"
|
|
hostmakedepends="pkgconf python ruby xz swig"
|
|
makedepends="libsepol-devel pcre-devel"
|
|
depends="libsepol pcre"
|
|
short_desc="SELinux library and simple utilities"
|
|
maintainer="Anjandev Momi <anjan@momi.ca>"
|
|
license="GPL-2.0-only"
|
|
homepage="https://www.nsa.gov/what-we-do/research/selinux/"
|
|
distfiles="https://github.com/SELinuxProject/selinux/releases/download/20191204/${pkgname}-${version}.tar.gz"
|
|
checksum=2ea2b30f671dae9d6b1391cbe8fb2ce5d36a3ee4fb1cd3c32f0d933c31b82433
|
|
|
|
if [ "$XBPS_TARGET_LIBC" = musl ]; then
|
|
makedepends+=" musl-fts-devel"
|
|
export FTS_LDLIBS="-lfts"
|
|
fi
|
|
|
|
libselinux-devel_package() {
|
|
short_desc+=" - development files"
|
|
depends="${sourcepkg}>=${version}_${revision}"
|
|
pkg_install() {
|
|
vmove usr/include
|
|
vmove "usr/lib/*.a"
|
|
vmove usr/share/man/man3
|
|
vmove "usr/lib/*.so"
|
|
vmove usr/lib/pkgconfig
|
|
}
|
|
}
|