ls: fix possible incorrect exit status when recursing directories
[coreutils.git] / bootstrap.conf
blob0863590394f735f1579b301575d55e150521a753
1 # Bootstrap configuration.
3 # Copyright (C) 2006-2013 Free Software Foundation, Inc.
5 # This program is free software: you can redistribute it and/or modify
6 # it under the terms of the GNU General Public License as published by
7 # the Free Software Foundation, either version 3 of the License, or
8 # (at your option) any later version.
10 # This program is distributed in the hope that it will be useful,
11 # but WITHOUT ANY WARRANTY; without even the implied warranty of
12 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13 # GNU General Public License for more details.
15 # You should have received a copy of the GNU General Public License
16 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
19 # We don't need these modules.
20 avoided_gnulib_modules='
21   --avoid=canonicalize-lgpl
22   --avoid=dummy
25 # gnulib modules used by this package.
26 gnulib_modules="
27   $avoided_gnulib_modules
28   acl
29   alignof
30   alloca
31   announce-gen
32   areadlink-with-size
33   argmatch
34   argv-iter
35   assert
36   autobuild
37   backupfile
38   base64
39   buffer-lcm
40   c-strcase
41   c-strtod
42   c-strtold
43   calloc-gnu
44   canon-host
45   canonicalize
46   chown
47   cloexec
48   closein
49   closeout
50   config-h
51   configmake
52   crypto/md5
53   crypto/sha1
54   crypto/sha256
55   crypto/sha512
56   cycle-check
57   d-ino
58   d-type
59   di-set
60   diacrit
61   dirfd
62   dirname
63   do-release-commit-and-tag
64   dtoastr
65   dup2
66   environ
67   error
68   euidaccess
69   exclude
70   exitfail
71   faccessat
72   fadvise
73   fchdir
74   fchmodat
75   fchownat
76   fclose
77   fcntl
78   fcntl-safer
79   fd-reopen
80   fdatasync
81   fdl
82   fdopen
83   fdutimensat
84   file-type
85   fileblocks
86   filemode
87   filenamecat
88   filevercmp
89   fnmatch-gnu
90   fopen-safer
91   fprintftime
92   freopen
93   freopen-safer
94   fseeko
95   fstatat
96   fsusage
97   fsync
98   ftello
99   ftoastr
100   ftruncate
101   fts
102   full-read
103   full-write
104   getgroups
105   gethrxtime
106   getline
107   getloadavg
108   getlogin
109   getndelim2
110   getopt-gnu
111   getpagesize
112   getpass-gnu
113   gettext-h
114   gettime
115   gettimeofday
116   getugroups
117   getusershell
118   git-version-gen
119   gitlog-to-changelog
120   gnu-make
121   gnu-web-doc-update
122   gnumakefile
123   gnupload
124   group-member
125   hard-locale
126   hash
127   hash-pjw
128   heap
129   host-os
130   human
131   idcache
132   ignore-value
133   inttostr
134   inttypes
135   isapipe
136   isatty
137   isblank
138   largefile
139   lchmod
140   lchown
141   ldtoastr
142   lib-ignore
143   linebuffer
144   link
145   link-follow
146   linkat
147   long-options
148   lstat
149   maintainer-makefile
150   malloc-gnu
151   manywarnings
152   mbrlen
153   mbrtowc
154   mbsalign
155   mbswidth
156   memcasecmp
157   memchr
158   memcmp2
159   mempcpy
160   memrchr
161   mgetgroups
162   mkancesdirs
163   mkdir
164   mkdir-p
165   mkfifo
166   mknod
167   mkstemp
168   mktime
169   modechange
170   mountlist
171   mpsort
172   netinet_in
173   non-recursive-gnulib-prefix-hack
174   nproc
175   obstack
176   parse-datetime
177   pathmax
178   perl
179   physmem
180   pipe
181   posix-shell
182   posixtm
183   posixver
184   priv-set
185   progname
186   propername
187   pthread
188   putenv
189   quote
190   quotearg
191   randint
192   randperm
193   read-file
194   readlink
195   readtokens
196   readtokens0
197   readutmp
198   realloc-gnu
199   regex
200   remove
201   rename
202   rmdir
203   root-dev-ino
204   rpmatch
205   safe-read
206   same
207   save-cwd
208   savedir
209   savewd
210   selinux-at
211   settime
212   sig2str
213   sigaction
214   smack
215   ssize_t
216   statat
217   stat-macros
218   stat-size
219   stat-time
220   stdbool
221   stdlib-safer
222   stpcpy
223   stpncpy
224   strdup-posix
225   strftime
226   strncat
227   strnumcmp
228   strpbrk
229   strsignal
230   strtod
231   strtoimax
232   strtoumax
233   symlink
234   sys_ioctl
235   sys_resource
236   sys_stat
237   sys_wait
238   termios
239   timer-time
240   timespec
241   tzset
242   uname
243   unicodeio
244   unistd-safer
245   unlink-busy
246   unlinkat
247   unlocked-io
248   unsetenv
249   update-copyright
250   uptime
251   useless-if-before-free
252   userspec
253   utimecmp
254   utimens
255   vasprintf-posix
256   vc-list-files
257   verify
258   verror
259   version-etc-fsf
260   wcswidth
261   wcwidth
262   winsz-ioctl
263   winsz-termios
264   write-any-file
265   xalloc
266   xfreopen
267   xfts
268   xgetcwd
269   xgetgroups
270   xgethostname
271   xmemcoll
272   xnanosleep
273   xprintf
274   xprintf-posix
275   xreadlink
276   xstrtod
277   xstrtoimax
278   xstrtol
279   xstrtold
280   xstrtoumax
281   yesno
284 # Other locale categories that need message catalogs.
285 EXTRA_LOCALE_CATEGORIES=LC_TIME
287 # Additional xgettext options to use.  Use "\\\newline" to break lines.
288 XGETTEXT_OPTIONS=$XGETTEXT_OPTIONS'\\\
289  --flag=asnprintf:3:c-format\\\
290  --flag=asprintf:2:c-format\\\
291  --flag=error:3:c-format\\\
292  --flag=error_at_line:5:c-format\\\
293  --flag=vasnprintf:3:c-format\\\
294  --flag=vasprintf:2:c-format\\\
295  --flag=verror:3:c-format\\\
296  --flag=verror_at_line:5:c-format\\\
297  --flag=wrapf:1:c-format\\\
298  --flag=xasprintf:1:c-format\\\
299  --flag=xfprintf:2:c-format\\\
300  --flag=xprintf:1:c-format\\\
301  --from-code=UTF-8\\\
304 # Append these, since we use the propername module.
305 see_manual='"This is a proper name. See the gettext manual, section Names."'
306 see_manual=\'"$see_manual"\'
307 XGETTEXT_OPTIONS=$XGETTEXT_OPTIONS'\\\
308  --keyword=proper_name:1,'"$see_manual"'\\\
309  --keyword=proper_name_utf8:1,'"$see_manual"'\\\
312 gnulib_tool_option_extras="--tests-base=gnulib-tests --with-tests --symlink\
313  --makefile-name=gnulib.mk
316 # Build prerequisites
317 buildreq="\
318 autoconf   2.64
319 automake   1.11.2
320 autopoint  -
321 bison      -
322 gettext    0.18.1
323 git        1.4.4
324 gperf      -
325 gzip       -
326 makeinfo   4.13
327 patch      -
328 perl       5.5
329 rsync      -
330 tar        -
331 xz         -
334 bootstrap_post_import_hook ()
336   # Automake requires that ChangeLog exist.
337   touch ChangeLog || return 1
338   # List of coreutils programs.  See heading comments in the invoked
339   # script for more info.  Keep this in sync with the rules in
340   (m4f=m4/cu-progs.m4 mkf=src/cu-progs.mk tmp=cu-progs.tmp \
341     && rm -f $m4f $mkf $tmp-1 $tmp-2 \
342     && build-aux/gen-lists-of-programs.sh --autoconf >$tmp-1 \
343     && build-aux/gen-lists-of-programs.sh --automake >$tmp-2 \
344     && chmod a-w $tmp-1 $tmp-2 \
345     && mv -f $tmp-1 $m4f && mv -f $tmp-2 $mkf)
347   # Massage lib/gnulib.mk before using it later in the bootstrapping process.
348   build-aux/prefix-gnulib-mk --lib-name=$gnulib_name lib/$gnulib_mk
352 bootstrap_epilogue()
354   # Since this is a "GNU" package, replace this line
355   #   if LC_ALL=C grep 'GNU @PACKAGE@' $(top_srcdir)/* 2>/dev/null \
356   #      | grep -v 'libtool:' >/dev/null; then
357   # with this:
358   #   if true; then
359   # Why?  That pipeline searches all files in $(top_srcdir), and if you
360   # happen to have large files (or apparently large sparse files), the
361   # first grep may well run out of memory.
362   perl -pi -e 's/if LC_ALL=C grep .GNU .PACKAGE.*; then/if true; then/' \
363     po/Makefile.in.in
365   # Install our git hooks, as long as "cp" accepts the --backup option,
366   # so that we can back up any existing files.
367   case $(cp --help) in *--backup*) backup=1;; *) backup=0;; esac
368   if test $backup = 1; then
369     hooks=$(cd scripts/git-hooks && git ls-files)
370     for f in $hooks; do
371       # If it is identical, skip it.
372       cmp scripts/git-hooks/$f .git/hooks/$f > /dev/null \
373         && continue
374       cp --backup=numbered scripts/git-hooks/$f .git/hooks
375       chmod a-w .git/hooks/$f
376     done
377   fi