void-packages/srcpkgs/moc/template
Đoàn Trần Công Danh 765e304c4b srcpkgs/m*: 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

21 lines
815 B
Bash

# Template file for 'moc'
pkgname=moc
version=2.5.2
revision=6
build_style=gnu-configure
hostmakedepends="pkg-config"
makedepends="db-devel ncurses-devel libcurl-devel popt-devel ffmpeg-devel
jack-devel alsa-lib-devel libltdl-devel libflac-devel libvorbis-devel
libmad-devel libmpcdec-devel libmodplug-devel libid3tag-devel faad2-devel
taglib-devel libsndfile-devel wavpack-devel speex-devel libsamplerate-devel
sndio-devel"
short_desc="Console-based audio player"
maintainer="necrophcodr <necrophcodr@necrophcodr.me>"
license="GPL-2.0-or-later"
homepage="http://moc.daper.net"
distfiles="http://ftp.daper.net/pub/soft/${pkgname}/stable/${pkgname}-${version}.tar.bz2"
checksum=f3a68115602a4788b7cfa9bbe9397a9d5e24c68cb61a57695d1c2c3ecf49db08
pre_configure() {
sed -i -e "s|^ac_cpp='\$CPP |&-P |g" configure
}