2 # Run this to generate all the initial makefiles, etc.
7 # Make it possible to specify path in the environment
9 : ${AUTOHEADER=autoheader}
10 : ${AUTOMAKE=automake}
12 : ${AUTOPOINT=autopoint}
13 : ${XGETTEXT=xgettext}
16 test -z "$srcdir" && srcdir
=.
19 # Some shells don't propagate "set -e" to subshells.
24 # The autoconf cache (version after 2.52) is not reliable yet.
25 rm -rf autom4te.cache vfs
/samba
/autom4te.cache
27 if test ! -d config
; then
31 # Recreate intl directory.
33 $AUTOPOINT --force ||
exit 1
35 # Generate po/POTFILES.in
36 $XGETTEXT --keyword=_
--keyword=N_
--keyword=Q_
--output=- \
37 `find . -name '*.[ch]'` |
sed -ne '/^#:/{s/#://;s/:[0-9]*/\
39 grep -v '^$' |
sort |
uniq |
grep -v 'regex.c' >po
/POTFILES.
in
41 ACLOCAL_INCLUDES
="-I m4"
43 # Some old version of GNU build tools fail to set error codes.
44 # Check that they generate some of the files they should.
46 $ACLOCAL $ACLOCAL_INCLUDES $ACLOCAL_FLAGS
47 test -f aclocal.
m4 || \
48 { echo "aclocal failed to generate aclocal.m4" >&2; exit 1; }
51 test -f config.h.
in || \
52 { echo "autoheader failed to generate config.h.in" >&2; exit 1; }
55 test -f configure || \
56 { echo "autoconf failed to generate configure" >&2; exit 1; }
58 # Workaround for Automake 1.5 to ensure that depcomp is distributed.
59 if test "`$AUTOMAKE --version|awk '{print $NF;exit}'`" = '1.5' ; then
60 $AUTOMAKE -a src
/Makefile
63 test -f Makefile.
in || \
64 { echo "automake failed to generate Makefile.in" >&2; exit 1; }
67 date -u >include
/stamp-h.
in
70 test -f include
/config.h.
in || \
71 { echo "autoheader failed to generate vfs/samba/include/config.h.in" >&2; exit 1; }
74 test -f configure || \
75 { echo "autoconf failed to generate vfs/samba/configure" >&2; exit 1; }
78 if test -x $srcdir/configure.mc
; then
79 $srcdir/configure.mc
"$@"
81 $srcdir/configure
--cache-file=config.cache
--enable-maintainer-mode "$@"