```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
```
12 lines
363 B
Diff
12 lines
363 B
Diff
--- a/m4/libxml2.m4 2020-05-10 19:36:06.000000000 +0200
|
|
+++ b/m4/libxml2.m4 2020-07-24 07:58:12.642619506 +0200
|
|
@@ -52,7 +52,7 @@
|
|
AC_REQUIRE([PKG_PROG_PKG_CONFIG])
|
|
PKG_PROG_PKG_CONFIG()
|
|
|
|
- if test -x "$PKG_CONFIG"; then
|
|
+ if test -x $(which "$PKG_CONFIG"); then
|
|
|
|
LIBXML2_CFLAGS="`$PKG_CONFIG --cflags libxml-2.0`"
|
|
|