void-packages/srcpkgs/desmume/template
Đoàn Trần Công Danh b6bcd8cd34 srcpkgs/d*: convert patches to -Np1
* daemontools and dmraid is kept at -Np0

```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

32 lines
1.1 KiB
Bash

# Template file for 'desmume'
pkgname=desmume
version=0.9.11
revision=4
build_style=gnu-configure
configure_args="--enable-wifi --enable-hud --disable-openal --enable-glx"
hostmakedepends="pkg-config intltool dos2unix"
makedepends="SDL-devel libpcap-devel soundtouch-devel alsa-lib-devel
gtk+-devel agg-devel zziplib-devel glu-devel"
depends="desktop-file-utils"
short_desc="Nintendo DS emulator"
maintainer="Orphaned <orphan@voidlinux.org>"
license="GPL-2.0-or-later"
homepage="http://www.desmume.org"
distfiles="${SOURCEFORGE_SITE}/$pkgname/$pkgname-$version.tar.gz"
checksum=3ab34ba6cc009566245025c1dd94bf449b6a1b416d24387cb42e183c78e38896
post_extract() {
# git eats CRLFs, so the patch has wrong line ending. Instead
# convert the target file to LF-only.
dos2unix $wrksrc/src/MMU_timing.h
}
post_install() {
# locales is only used for glade, but it's never built
# The configure script set GETTEXT_PACKAGE to empty string
# this it's never usable.
# /usr/lib/locale/nb/LC_MESSAGES/.mo
# /usr/share/locale/nb/LC_MESSAGES/.mo
rm -rf $DESTDIR/usr/lib/locale
rm -rf $DESTDIR/usr/share/locale
}