void-packages/srcpkgs/vte3/template
Đoàn Trần Công Danh 76acfa2dd2 srcpkgs/v*: 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

43 lines
1.3 KiB
Bash

# Template file for 'vte3'
pkgname=vte3
version=0.64.1
revision=1
wrksrc="vte-${version}"
build_style=meson
build_helper="gir"
configure_args="-Db_ndebug=false -Db_lto=false -D_systemd=false
$(vopt_bool gir gir) $(vopt_bool gir vapi)"
hostmakedepends="glib-devel gperf intltool pkg-config
$(vopt_if gir vala)"
makedepends="gnutls-devel gtk+3-devel pcre2-devel $(vopt_if gir vala-devel)"
short_desc="Terminal widget with improved accessibility and I18N support"
maintainer="Enno Boland <gottox@voidlinux.org>"
license="GPL-3.0-or-later, LGPL-2.1-or-later, LGPL-3.0-or-later"
homepage="https://wiki.gnome.org/Apps/Terminal/VTE"
distfiles="${GNOME_SITE}/vte/${version%.*}/vte-${version}.tar.xz"
checksum=12fb41a9ff8e03c5f1711b46560910a4b9b3102aec3e9e7609ceef4dfa98aa2a
# Suppress warnings as errors for NULL format strings (musl libc)
CXXFLAGS="-Wno-error=format="
# Package build options
build_options="gir"
build_options_default="gir"
pre_build() {
export GIR_EXTRA_LIBS_PATH="${wrksrc}/src/.libs"
}
vte3-devel_package() {
depends="gnutls-devel gtk+3-devel pcre2-devel vte3>=${version}_${revision}"
short_desc+=" - development files"
pkg_install() {
vmove usr/include
vmove usr/lib/pkgconfig
vmove "usr/lib/*.so"
if [ "$build_option_gir" ]; then
vmove usr/share/gir-1.0
vmove usr/share/vala
fi
}
}