- cat <<EOF
- usage: $0 [--gnulib-srcdir=DIR][--paxutils-srcdir=DIR][--cvs-auth=AUTH-METHOD][--cvs-user=USERNAME][--no-po]
- Options are:
- --paxutils-srcdir=DIRNAME Specify the local directory where paxutils
- sources reside. Use this if you already
- have paxutils sources on your machine, and
- do not want to waste your bandwidth dowloading
- them again.
- --gnulib-srcdir=DIRNAME Specify the local directory where gnulib
- sources reside. Use this if you already
- have gnulib sources on your machine, and
- do not want to waste your bandwidth dowloading
- them again.
- --cvs-auth=METHOD Set the CVS access method used for downloading
- gnulib files. METHOD is one of the keywords
- accepted by cvs -d option (see info cvs
- repository).
- --cvs-user=USERNAME Set the CVS username to be used when accessing
- the gnulib repository.
- --no-po Do not download po files.
- --update-po[=LANG] Update po file(s) and exit.
-
-If the file \`.bootstrap' exists in the current working directory, its
-contents is read, comments and empty lines removed, shell variables expanded
-and the result is prepended to the command line options.
-
-Running without arguments will suffice in most cases. It is equivalent
-to
-
- ./bootstrap --cvs-auth=pserver
-
-EOF
+ echo >&2 "\
+Usage: $0 [OPTION]...
+Bootstrap this package from the checked-out sources.
+
+Options:
+ --paxutils-srcdir=DIRNAME Specify the local directory where paxutils
+ sources reside. Use this if you already
+ have paxutils sources on your machine, and
+ do not want to waste your bandwidth dowloading
+ them again.
+ --gnulib-srcdir=DIRNAME Specify the local directory where gnulib
+ sources reside. Use this if you already
+ have gnulib sources on your machine, and
+ do not want to waste your bandwidth dowloading
+ them again.
+ --copy Copy files instead of creating symbolic links.
+ --force Attempt to bootstrap even if the sources seem
+ not to have been checked out.
+ --skip-po Do not download po files.
+ --update-po[=LANG] Update po file(s) and exit.
+ --cvs-user=USERNAME Set the CVS username to be used when accessing
+ the paxutils repository.
+
+If the file bootstrap.conf exists in the current working directory, its
+contents are read as shell variables to configure the bootstrap.
+
+Local defaults can be provided by placing the file \`.bootstrap' in the
+current working directory. The file is read after bootstrap.conf, comments
+and empty lines are removed, shell variables expanded and the result is
+prepended to the command line options.
+
+Running without arguments will suffice in most cases.
+"
+}
+
+checkout() {
+ if [ ! -d $1 ]; then
+ echo "$0: getting $1 files..."
+
+ case $1 in
+ paxutils)
+ case ${CVS_AUTH-pserver} in
+ pserver)
+ CVS_PREFIX=':pserver:anonymous@';;
+ ssh)
+ CVS_PREFIX="$CVS_USER${CVS_USER+@}";;
+ *)
+ echo "$0: $CVS_AUTH: Unknown CVS access method" >&2
+ exit 1;;
+ esac
+
+ case $CVS_RSH in
+ '') CVS_RSH=ssh; export CVS_RSH;;
+ esac
+
+ CVSURL=${CVS_PREFIX}cvs.savannah.gnu.org:/cvsroot/"$1"
+ ;;
+
+ gnulib)
+ CVSURL=:pserver:anonymous@pserver.git.sv.gnu.org:/gnulib.git
+ ;;
+
+ esac
+
+ trap "cleanup $1" 1 2 13 15
+
+ cvs -z3 -q -d $CVSURL co $1 || cleanup $1
+
+ trap - 1 2 13 15
+ fi
+}
+
+cleanup() {
+ status=$?
+ rm -fr $1
+ exit $status
+}
+
+# Configuration.
+
+# List of gnulib modules needed.
+gnulib_modules=
+
+# Any gnulib files needed that are not in modules.
+gnulib_files=
+
+# Translation Project URL, for the registry of all projects
+# and for the translation-team master directory.
+tp_url() {
+ echo "http://translationproject.org/domain/$1.html"