```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 ```
20 lines
714 B
Bash
20 lines
714 B
Bash
# Template file for 'xplanet'
|
|
pkgname=xplanet
|
|
version=1.3.1
|
|
revision=2
|
|
build_style=gnu-configure
|
|
configure_args="--with-freetype"
|
|
hostmakedepends="pkg-config"
|
|
makedepends="pango-devel freetype-devel giflib-devel tiff-devel libXScrnSaver-devel"
|
|
short_desc="Planetary body renderer"
|
|
maintainer="Orphaned <orphan@voidlinux.org>"
|
|
license="GPL-2"
|
|
homepage="http://xplanet.sourceforge.net"
|
|
distfiles="${SOURCEFORGE_SITE}/$pkgname/$pkgname-$version.tar.gz"
|
|
checksum=4380d570a8bf27b81fb629c97a636c1673407f4ac4989ce931720078a90aece7
|
|
|
|
pre_configure() {
|
|
# make it build with giflib-5.1.0
|
|
# see http://wiki.linuxfromscratch.org/blfs/ticket/5076#comment:2
|
|
sed -i "/[DE]GifCloseFile/s:GifFile:&, NULL:g" src/libimage/gif.c
|
|
}
|