void-packages/srcpkgs/pioneer/template
Đoàn Trần Công Danh 49cb564d14 srcpkgs/p*: convert patches to -Np1
* par 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

40 lines
1.1 KiB
Bash

# Template file for 'pioneer'
pkgname=pioneer
version=20210203
revision=1
build_style=cmake
make_build_target="all build-data"
configure_args="-DPIONEER_DATA_DIR=/usr/share/pioneer
-DUSE_SYSTEM_LIBLUA=ON -DUSE_SYSTEM_LIBGLEW=ON"
hostmakedepends="automake pkg-config"
makedepends="freetype-devel libassimp-devel libsigc++-devel
libvorbis-devel SDL2_image-devel glew-devel lua52-devel"
depends="pioneer-data>=${version}_${revision}"
short_desc="Space adventure game set in our galaxy at the turn of the 31st century"
maintainer="John <me@johnnynator.dev>"
license="GPL-3.0-or-later"
homepage="https://pioneerspacesim.net"
distfiles="https://github.com/pioneerspacesim/pioneer/archive/${version}.tar.gz"
checksum=fcbc57374123b44161e9d15d97bd950255f654a222840894f50bfc2be716ea68
if [ "$CROSS_BUILD" ]; then
hostmakedepends+=" pioneer-modelcompiler"
fi
if [ "$XBPS_TARGET_ENDIAN" = "be" ]; then
broken="Not yet implemented"
fi
pioneer-modelcompiler_package() {
short_desc+=" -modelcompiler"
pkg_install() {
vmove usr/bin/modelcompiler
}
}
pioneer-data_package() {
short_desc+=" - data"
pkg_install() {
vmove usr/share/pioneer
}
}