File: make-patch.sh

package info (click to toggle)
glib2.0 2.42.1-1
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-backports, jessie-kfreebsd, jessie-kfreebsd-proposed-updates
  • size: 82,084 kB
  • sloc: ansic: 411,692; xml: 15,280; sh: 12,977; python: 5,145; makefile: 3,567; perl: 1,422; cpp: 9
file content (28 lines) | stat: -rwxr-xr-x 762 bytes parent folder | download | duplicates (12)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#!/bin/sh

if test $# = 1 ; then 
  ORIGINAL=$1
else
  echo "Usage: make-patch.sh /path/to/libcharset" 1>&2
  exit 1
fi

if test -f $ORIGINAL/lib/localcharset.c ; then : ; else
  echo "Usage: make-patch.sh /path/to/libcharset" 1>&2
  exit 1
fi

VERSION=`grep VERSION= $ORIGINAL/configure.ac | sed s/VERSION=//`

echo "# Patch against libcharset version $VERSION" > libcharset-glib.patch

for i in localcharset.c ref-add.sin ref-del.sin ; do
  diff -u $ORIGINAL/lib/$i $i >> libcharset-glib.patch
done

for i in glibc21.m4 codeset.m4 ; do
  diff -u $ORIGINAL/m4/$i $i >> libcharset-glib.patch
done

diff -u $ORIGINAL/include/libcharset.h.in libcharset.h >> libcharset-glib.patch
diff -u $ORIGINAL/include/localcharset.h.in localcharset.h >> libcharset-glib.patch