]> git.saurik.com Git - wxWidgets.git/blame - src/expat/make-release.sh
Revert "Make wxMSW stack walking methods work with Unicode identifiers."
[wxWidgets.git] / src / expat / make-release.sh
CommitLineData
11a3e7b6
VZ
1#! /bin/bash
2#
3# make-release.sh: make an Expat release
4#
5# USAGE: make-release.sh tagname
6#
7# Note: tagname may be HEAD to just grab the head revision (e.g. for testing)
8#
9
10#CVSROOT=':ext:cvs.libexpat.org:/cvsroot/expat'
11CVSROOT=':pserver:anonymous@expat.cvs.sourceforge.net:/cvsroot/expat'
12
13if test $# != 1; then
14 echo "USAGE: $0 tagname"
15 exit 1
16fi
17
18tmpdir=expat-release.$$
19if test -e $tmpdir; then
20 echo "ERROR: oops. chose the $tmpdir subdir, but it exists."
21 exit 1
22fi
23
24echo "Checking out into temporary area: $tmpdir"
25cvs -fq -d "$CVSROOT" export -r "$1" -d $tmpdir expat || exit 1
26
27echo ""
28echo "----------------------------------------------------------------------"
29echo "Preparing $tmpdir for release (running buildconf.sh)"
30(cd $tmpdir && ./buildconf.sh) || exit 1
31
32# figure out the release version
33vsn="`$tmpdir/conftools/get-version.sh $tmpdir/lib/expat.h`"
34
35echo ""
36echo "Release version: $vsn"
37
38if test "$1" = HEAD ; then
39 distdir=expat-`date '+%Y-%m-%d'`
40else
41 distdir=expat-$vsn
42fi
43if test -e $distdir; then
44 echo "ERROR: for safety, you must manually remove $distdir."
45 rm -rf $tmpdir
46 exit 1
47fi
48mkdir $distdir || exit 1
49
50CPOPTS=-Pp
51if (cp --version 2>/dev/null | grep -q 'Free Software Foundation') ; then
52 # If we're using GNU cp, we can avoid the warnings about forward
53 # compatibility of the options.
54 CPOPTS='--parents --preserve'
55fi
56
57echo ""
58echo "----------------------------------------------------------------------"
59echo "Building $distdir based on the MANIFEST:"
60files="`sed -e 's/[ ]:.*$//' $tmpdir/MANIFEST`"
61for file in $files; do
62 echo "Copying $file..."
63 (cd $tmpdir && cp $CPOPTS $file ../$distdir) || exit 1
64done
65
66echo ""
67echo "----------------------------------------------------------------------"
68echo "Removing (temporary) checkout directory..."
69rm -rf $tmpdir
70
71tarball=$distdir.tar.gz
72echo "Constructing $tarball..."
73tar cf - $distdir | gzip -9 > $tarball || exit $?
74rm -r $distdir
75
76echo "Done."