3 # "$Id: makesrcdist 5502 2006-05-08 21:09:15Z mike $"
5 # makesrcdist - make a source distribution of CUPS.
8 # Make sure we are running in the right directory...
9 if test ! -f tools
/makesrcdist
; then
10 echo "Run this script from the top-level CUPS source directory, e.g.:"
12 echo " tools/makesrcdist $*"
18 echo Updating
for snapshot...
20 rev=`svnversion . | sed -e '1,$s/[a-zA-Z]//g'`
23 fileversion
="1.3svn-r$rev"
24 fileurl
="ftp://ftp.easysw.com/pub/cups/test/cups-$fileversion-source.tar."
27 echo Creating tag
for release...
32 fileurl
="ftp://ftp.easysw.com/pub/cups/$version/cups-$fileversion-source.tar."
33 url
="https://svn.easysw.com/public/cups/tags/release-$version"
35 svn copy https
://svn.easysw.com
/public
/cups
/trunk
"$url" \
36 -m "Tag $version" ||
exit 1
39 fileurl
=`echo $fileurl | sed -e '1,$s/\\//\\\\\\//g'`
41 echo Exporting
$fileversion...
42 rm -rf /tmp
/cups-
$version
43 svn
export $url /tmp
/cups-
$version
45 echo Updating version information...
46 cd /tmp
/cups-
$version/config-scripts
48 sed -e '1,$s/^CUPS_VERSION=.*/CUPS_VERSION='$version'/' \
49 -e '1,$s/^CUPS_REVISION=.*/CUPS_REVISION='$revision'/' \
50 <cups-common.
m4 >cups-common.
m4.new
51 mv cups-common.
m4.new cups-common.
m4
56 rm -rf autom4te
*.cache
61 echo -n Archiving...gz
62 sed -e '1,$s/@CUPS_VERSION@/'$version'/' \
63 -e '1,$s/^Release:.*/Release: '$rev'/' \
64 -e '1,$s/^Source:.*/Source: '$fileurl'gz/' \
65 <cups-
$version/packaging
/cups.spec.
in \
66 >cups-
$version/packaging
/cups.spec
67 tar czf cups-
$fileversion-source.
tar.gz cups-
$version
70 sed -e '1,$s/@CUPS_VERSION@/'$version'/' \
71 -e '1,$s/^Release:.*/Release: '$rev'/' \
72 -e '1,$s/^Source:.*/Source: '$fileurl'bz2/' \
73 <cups-
$version/packaging
/cups.spec.
in \
74 >cups-
$version/packaging
/cups.spec
75 tar cjf cups-
$fileversion-source.
tar.bz2 cups-
$version
78 echo Removing temporary files...
84 # End of "$Id: makesrcdist 5502 2006-05-08 21:09:15Z mike $".