aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Poznyakoff <gray@gnu.org.ua>2008-03-11 23:22:54 +0000
committerSergey Poznyakoff <gray@gnu.org.ua>2008-03-11 23:22:54 +0000
commitc56ae1845ebbe64a9f73eb60f365a1f8f29a0100 (patch)
treef15c06cfb7b9f90b83e275120e8367467d02fb2e
parent3a2e207c3413ed61ed12ab9738146c5ce73f73d6 (diff)
downloadpies-c56ae1845ebbe64a9f73eb60f365a1f8f29a0100.tar.gz
pies-c56ae1845ebbe64a9f73eb60f365a1f8f29a0100.tar.bz2
Rewrite the bootstrap suite.
* README-alpha: Rewritten. * bootstrap.conf: Rewritten. * bootstrap: Slightly modified version from gnulib. * gnulib.modules, README-hacking: New files. * doc/mailfromd.texi: Minor fix.
-rwxr-xr-xbootstrap745
-rw-r--r--bootstrap.conf68
2 files changed, 597 insertions, 216 deletions
diff --git a/bootstrap b/bootstrap
index 51d94b2..0fa016d 100755
--- a/bootstrap
+++ b/bootstrap
@@ -1,96 +1,86 @@
1#! /bin/sh 1#! /bin/sh
2############################
3## Configuration
4############################
5
6GNULIB_DATE=2007-05-12
7GNU_SOURCE_BASE=gnu
8
9MODLIST="argp\
10 fprintftime\
11 getline\
12 gettext\
13 malloc\
14 memrchr\
15 mkdtemp\
16 obstack\
17 realloc\
18 regex\
19 save-cwd\
20 snprintf\
21 strtok_r\
22 vasprintf"
23
24MODAVOID="xalloc-die openat-die"
25 2
26# Other locale categories that need message catalogs. 3# Bootstrap this package from checked-out sources.
27EXTRA_LOCALE_CATEGORIES=
28 4
29NLS_MARKERS="\ 5# Copyright (C) 2003-2008 Free Software Foundation, Inc.
30 MF_THROW:2\
31 MF_ASSERT:3\
32 parse_error:1\
33 parse_error_locus:2\
34 mu_error:1\
35 gacopyz_io_log:3\
36 gacopyz_logmsg:2\
37 gacopyz_log:3"
38 6
39# Additional xgettext options to use. Use "\\\newline" to break lines. 7# This program is free software: you can redistribute it and/or modify
40XGETTEXT_OPTIONS='\\\ 8# it under the terms of the GNU General Public License as published by
41 --flag=_:1:pass-c-format\\\ 9# the Free Software Foundation, either version 3 of the License, or
42 --flag=N_:1:pass-c-format\\\ 10# (at your option) any later version.
43 --flag=error:3:c-format --flag=error_at_line:5:c-format\\\ 11
12# This program is distributed in the hope that it will be useful,
13# but WITHOUT ANY WARRANTY; without even the implied warranty of
14# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15# GNU General Public License for more details.
16
17# You should have received a copy of the GNU General Public License
18# along with this program. If not, see <http://www.gnu.org/licenses/>.
19
20# Written by Paul Eggert.
21
22nl='
44' 23'
45 24
46COPYRIGHT_HOLDER="Sergey Poznyakoff" 25# Ensure file names are sorted consistently across platforms.
26LC_ALL=C
27export LC_ALL
47 28
48# Translation Project URL, for the registry of all projects 29local_gl_dir=gl
49# and for the translation-team master directory.
50# (for future use)
51tp_url() {
52 echo "http://translationproject.org/domain/$1.html"
53}
54 30
55############################ 31# Temporary directory names.
56## Implementation 32bt='._bootmp'
57############################ 33bt_regex=`echo "$bt"| sed 's/\./[.]/g'`
34bt2=${bt}2
58 35
59usage() { 36usage() {
60 echo >&2 "\ 37 echo >&2 "\
61Usage: $0 [OPTION]... GNULIB_DIR 38Usage: $0 [OPTION]...
62Bootstrap this package from the checked-out sources. 39Bootstrap this package from the checked-out sources.
63 40
41Options:
42 --gnulib-srcdir=DIRNAME Specify the local directory where gnulib
43 sources reside. Use this if you already
44 have gnulib sources on your machine, and
45 do not want to waste your bandwidth downloading
46 them again.
64 --copy Copy files instead of creating symbolic links. 47 --copy Copy files instead of creating symbolic links.
65 --force Attempt to bootstrap even if the sources seem 48 --force Attempt to bootstrap even if the sources seem
66 not to have been checked out. 49 not to have been checked out.
67 --skip-po Do not download po files. 50 --skip-po Do not download po files.
68 --update-po[=LANG] Update po file(s) and exit.
69
70The only argument specifes the file name of the directory were gnulib
71sources are located. You will have to check out them beforehand, \`bootstrap'
72won't do this for you.
73 51
74Local defaults can be provided by placing the file \`.bootstrap' in the 52If the file bootstrap.conf exists in the current working directory, its
75current working directory. The file is read, comments and empty lines are 53contents are read as shell variables to configure the bootstrap.
76removed, shell variables expanded and the result is prepended to the command
77line options.
78 54
79Running without arguments will suffice in most cases. 55Running without arguments will suffice in most cases.
80" 56"
81} 57}
82 58
83# Read local configuration file 59# Configuration.
84if [ -r .bootstrap ]; then 60
85 echo "$0: Reading configuration file .bootstrap" 61# Name of the Makefile.am
86 eval set -- "`sed 's/#.*$//;/^$/d' .bootstrap | tr '\n' ' '` $*" 62gnulib_mk=gnulib.mk
87fi 63
64# List of gnulib modules needed.
65gnulib_modules=
66
67# Any gnulib files needed that are not in modules.
68gnulib_files=
69
70# The command to download all .po files for a specified domain into
71# a specified directory. Fill in the first %s is the domain name, and
72# the second with the destination directory. Use rsync's -L and -r
73# options because the latest/%s directory and the .po files within are
74# all symlinks.
75po_download_command_format=\
76"rsync -Lrtvz 'translationproject.org::tp/latest/%s/' '%s'"
88 77
89extract_package_name=' 78extract_package_name='
90 /^AC_INIT(/{ 79 /^AC_INIT(/{
91 /.*,.*,.*,/{ 80 /.*,.*,.*, */{
92 s/// 81 s///
93 s/[][]//g 82 s/[][]//g
83 s/)$//
94 p 84 p
95 q 85 q
96 } 86 }
@@ -103,23 +93,70 @@ extract_package_name='
103 } 93 }
104' 94'
105package=`sed -n "$extract_package_name" configure.ac` || exit 95package=`sed -n "$extract_package_name" configure.ac` || exit
96gnulib_name=lib$package
97
98build_aux=build-aux
99source_base=lib
100m4_base=m4
101doc_base=doc
102tests_base=tests
103
104# Extra files from gnulib, which override files from other sources.
105gnulib_extra_files="
106 $build_aux/install-sh
107 $build_aux/missing
108 $build_aux/mdate-sh
109 $build_aux/texinfo.tex
110 $build_aux/depcomp
111 $build_aux/config.guess
112 $build_aux/config.sub
113 doc/INSTALL
114"
106 115
107extract_bug_address=' 116# Additional gnulib-tool options to use. Use "\newline" to break lines.
108 /^AC-INIT-BUG-ADDRESS/{ 117gnulib_tool_option_extras=
109 s/[][]//g 118
110 s/.*=//p 119# Other locale categories that need message catalogs.
111 } 120EXTRA_LOCALE_CATEGORIES=
121
122# Additional xgettext options to use. Use "\\\newline" to break lines.
123XGETTEXT_OPTIONS='\\\
124 --flag=_:1:pass-c-format\\\
125 --flag=N_:1:pass-c-format\\\
126 --flag=error:3:c-format --flag=error_at_line:5:c-format\\\
112' 127'
113bug_address=`m4 -D'AC_INIT=AC-INIT-BUG-ADDRESS=$3' configure.ac | sed -n "$extract_bug_address"` 128
114if test -z "$bug_address"; then 129# Package bug report address for gettext files
115 bug_address="bug-${package}@gnu.org.ua" 130MSGID_BUGS_ADDRESS=bug-$package@gnu.org
116fi 131
132# Files we don't want to import.
133excluded_files=
134
135# File that should exist in the top directory of a checked out hierarchy,
136# but not in a distribution tarball.
137checkout_only_file=README-hacking
117 138
118# Whether to use copies instead of symlinks. 139# Whether to use copies instead of symlinks.
119copy=false 140copy=false
120 141
121GNULIB_OPTION= 142# Set this to '.cvsignore .gitignore' in bootstrap.conf if you want
122DOWNLOAD_PO= 143# those files to be generated in directories like lib/, m4/, and po/.
144# Or set it to 'auto' to make this script select which to use based
145# on which version control system (if any) is used in the source directory.
146vc_ignore=auto
147
148# Override the default configuration, if necessary.
149test -r bootstrap.conf && . ./bootstrap.conf
150
151if test "$vc_ignore" = auto; then
152 vc_ignore=
153 test -d .git && vc_ignore=.gitignore
154 test -d CVS && vc_ignore="$vc_ignore .cvsignore"
155fi
156
157# Translate configuration into internal form.
158
159# Parse options.
123 160
124for option 161for option
125do 162do
@@ -127,186 +164,462 @@ do
127 --help) 164 --help)
128 usage 165 usage
129 exit;; 166 exit;;
130 --skip-po | --no-po) # --no-po is for compatibility with 'tar' tradition. 167 --gnulib-srcdir=*)
131 DOWNLOAD_PO=skip;; 168 GNULIB_SRCDIR=`expr "$option" : '--gnulib-srcdir=\(.*\)'`;;
132 --update-po=*)