void-packages/srcpkgs/liba52/template
Đoàn Trần Công Danh 861ac185a6 srcpkgs/l*: 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

35 lines
839 B
Bash

# Template file for 'liba52'
pkgname=liba52
version=0.7.4
revision=9
wrksrc="a52dec-${version}"
build_style=gnu-configure
configure_args="--enable-shared"
hostmakedepends="automake libtool"
short_desc="Free ATSC A/52 stream decoder"
maintainer="Orphaned <orphan@voidlinux.org>"
license="GPL-2.0-or-later"
homepage="http://liba52.sourceforge.net/"
distfiles="http://liba52.sourceforge.net/files/a52dec-${version}.tar.gz"
checksum=a21d724ab3b3933330194353687df82c475b5dfb997513eef4c25de6c865ec33
pre_configure() {
./bootstrap
}
a52dec_package() {
short_desc="ATSC A/52 stream decoder tools"
pkg_install() {
vmove usr/bin
vmove usr/share
}
}
liba52-devel_package() {
depends="liba52>=${version}_${revision}"
short_desc+=" - development files"
pkg_install() {
vmove usr/include
vmove "usr/lib/*.a"
vmove "usr/lib/*.so"
}
}