```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 ```
38 lines
1.1 KiB
Bash
38 lines
1.1 KiB
Bash
# Template file for 'ufraw'
|
|
pkgname=ufraw
|
|
version=0.22
|
|
revision=4
|
|
build_style=gnu-configure
|
|
configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
|
|
$(vopt_enable extras)"
|
|
hostmakedepends="pkg-config dcraw gettext"
|
|
makedepends="exiv2-devel gimp-devel glib-devel gtkimageview-devel lcms2-devel lensfun-devel
|
|
jasper-devel"
|
|
depends="desktop-file-utils"
|
|
short_desc="Utility to read and manipulate raw images from digital cameras"
|
|
maintainer="John <me@johnnynator.dev>"
|
|
license="GPL-2.0-or-later"
|
|
homepage="http://ufraw.sourceforge.net/"
|
|
distfiles="${SOURCEFORGE_SITE}/ufraw/ufraw/ufraw-${version}/ufraw-${version}.tar.gz"
|
|
checksum=f7abd28ce587db2a74b4c54149bd8a2523a7ddc09bedf4f923246ff0ae09a25e
|
|
|
|
build_options="extras"
|
|
|
|
post_patch() {
|
|
vsed -e 's/default(none)//g' \
|
|
-i dcraw_indi.c \
|
|
-i dcraw_api.cc \
|
|
-i ufraw_ufraw.c \
|
|
-i ufraw_developer.c
|
|
vsed -i -e '/DATADIRNAME=/s/=.*/=share/' configure
|
|
vsed -i -e "s,^localedir =.*,localedir = /usr/share/locale," \
|
|
po/Makefile.in.in
|
|
}
|
|
|
|
ufraw-gimp_package() {
|
|
depends="${sourcepkg}>=${version}_${revision}"
|
|
short_desc+=" - gimp plugin"
|
|
pkg_install() {
|
|
vmove usr/lib/gimp
|
|
}
|
|
}
|