void-packages/srcpkgs/sombok/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

30 lines
866 B
Bash

# Template file for 'sombok'
pkgname=sombok
version=2.4.0
revision=2
wrksrc="${pkgname}-${pkgname}-${version}"
build_style=gnu-configure
hostmakedepends="pkg-config automake autogen libtool"
makedepends="libthai-devel"
short_desc="Line Breaking Algorithm described in Unicode Standard Annex UAX #14"
maintainer="newbluemoon <blaumolch@mailbox.org>"
license="Artistic, GPL-1"
homepage="https://github.com/hatukanezumi/sombok"
distfiles="https://github.com/hatukanezumi/${pkgname}/archive/${pkgname}-${version}.tar.gz"
checksum=14d9dcd3621bf9d591a7158aeac99b4d4a60296558173be51d57b54b8f9d70a2
pre_configure() {
autoreconf -i
}
sombok-devel_package() {
short_desc+=" - development files"
depends="${makedepends} ${sourcepkg}>=${version}_${revision}"
pkg_install() {
vmove usr/include
vmove usr/lib/pkgconfig
vmove "usr/lib/*.a"
vmove "usr/lib/*.so"
}
}