]> sjero.net Git - wget/blobdiff - util/dist-wget
[svn] Synch doc/version.texi with src/version.c.
[wget] / util / dist-wget
index b4fe96e5368783dd1213de19bed130064c0ab90e..2dc305ccda129ae45cb5a38c99e56fd63bcdf5ee 100755 (executable)
@@ -1,4 +1,4 @@
-#!/bin/sh -e
+#!/bin/sh
 
 # Copyright (C) 2001 Free Software Foundation, Inc.
 
@@ -26,6 +26,7 @@
 # file, but you are not obligated to do so.  If you do not wish to do
 # so, delete this exception statement from your version.
 
+set -e
 
 CVSROOT=:pserver:cvs@sunsite.dk:/pack/anoncvs
 SUBDIR=wget.cvs.$$
@@ -53,7 +54,7 @@ do
       ;;
     -r)
       shift
-      EXPORT_TAG="-r $1"
+      EXPORT_TAG="-r '$1'"
       ;;
     --force-version)
       shift
@@ -85,7 +86,7 @@ echo "Output from commands is in $O."
 echo "-----------" >$O
 
 # Checkout clean sources from the repository.
-echo $e_n "Exporting ($EXPORT_TAG) out the CVS tree to $SUBDIR... $e_c"
+echo $e_n "Exporting ($EXPORT_TAG) out the CVS tree to $TMPDIR/$SUBDIR... $e_c"
 cvs -d $CVSROOT export $EXPORT_TAG -d $SUBDIR wget 1>>$O 2>&1
 echo "done."
 
@@ -97,8 +98,9 @@ rm -rf Branches 1>>$O 2>&1
 # Force the version if required.
 if test x"$VERSION" != x
 then
-  echo "char *version_string = \"$VERSION\";" > src/version.c
   echo "Forcing version to $VERSION."
+  echo "char *version_string = \"$VERSION\";" > src/version.c
+  echo "@set VERSION $VERSION" > doc/version.texi
 fi
 
 # Create configure and friends.
@@ -137,8 +139,9 @@ echo "done."
 # Create the distribution file.
 echo $e_n "Creating distribution tarball... $e_c"
 $MAKE dist 1>>$O 2>&1
-mv wget-*.tar.gz $DEST_DIR
-echo "done."
+archive=`echo wget-*.tar.gz`
+mv "$archive" $DEST_DIR
+echo "$archive"
 
 cd ..