void-packages/srcpkgs/stfl/template
Đoàn Trần Công Danh 4b97cd2fb4 srcpkgs/s*: 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

28 lines
762 B
Bash

# Template file for 'stfl'
pkgname=stfl
version=0.24
revision=4
build_style=gnu-makefile
hostmakedepends="swig"
makedepends="ncurses-devel"
short_desc="Curses-based widget set for text terminals"
maintainer="Logen K <logen@sudotask.com>"
license="GPL-3.0-or-later"
homepage="http://www.clifford.at/stfl/"
distfiles="http://www.clifford.at/${pkgname}/${pkgname}-${version}.tar.gz"
checksum=d4a7aa181a475aaf8a8914a8ccb2a7ff28919d4c8c0f8a061e17a0c36869c090
post_install() {
ln -sf libstfl.so.${version} ${DESTDIR}/usr/lib/libstfl.so.0
}
stfl-devel_package() {
depends="stfl>=${version}_${revision} $makedepends"
short_desc+=" - development files"
pkg_install() {
vmove usr/include
vmove usr/lib/pkgconfig
vmove "usr/lib/*.so"
vmove "usr/lib/*.a"
}
}