]> arthur.barton.de Git - netatalk.git/blob - bootstrap
Merge remote-tracking branch 'origin/branch-netatalk-3-1'
[netatalk.git] / bootstrap
1 #!/bin/sh
2
3 DIE=0
4
5 (autoconf --version) < /dev/null > /dev/null 2>&1 || {
6   echo
7   echo "**Error**: You must have \`autoconf' installed to."
8   echo "Download the appropriate package for your distribution,"
9   echo "or get the source tarball at ftp://ftp.gnu.org/pub/gnu/"
10   DIE=1
11 }
12
13 (libtool --version) < /dev/null > /dev/null 2>&1 || {
14   echo
15   echo "**Error**: You must have \`libtool' installed."
16   echo "Get ftp://ftp.gnu.org/pub/gnu/libtool-1.2d.tar.gz"
17   echo "(or a newer version if it is available)"
18   DIE=1
19 }
20
21 (automake --version) < /dev/null > /dev/null 2>&1 || {
22   echo
23   echo "**Error**: You must have \`automake' installed."
24   echo "Get ftp://ftp.gnu.org/pub/gnu/automake-1.3.tar.gz"
25   echo "(or a newer version if it is available)"
26   DIE=1
27 }
28
29 (aclocal --version) < /dev/null > /dev/null 2>&1 || {
30   echo
31   echo "**Error**: Missing \`aclocal'.  The version of \`automake'"
32   echo "installed doesn't appear recent enough."
33   echo "Get ftp://ftp.gnu.org/pub/gnu/automake-1.3.tar.gz"
34   echo "(or a newer version if it is available)"
35   DIE=1
36 }
37
38 (pkg-config --version) < /dev/null > /dev/null 2>&1 || {
39   echo
40   echo "**Error**: You must have \`pkg-config' installed."
41   DIE=1
42 }
43
44 if test "$DIE" -eq 1; then
45   exit 1
46 fi
47
48 set -x
49
50 rm -rf autom4te*.cache
51
52 LIBTOOLIZE=libtoolize
53 SYSNAME=`uname`
54 if [ "x$SYSNAME" = "xDarwin" ] ; then
55   LIBTOOLIZE=glibtoolize
56 fi
57
58 # build it all.
59 aclocal -I macros $ACLOCAL_FLAGS || exit 1
60 autoheader || exit 1
61 $LIBTOOLIZE --force --copy
62 automake --include-deps --add-missing --foreign --copy || exit 1
63 autoconf || exit 1
64
65 # libevent
66 cd libevent
67 aclocal -I m4 && \
68         autoheader && \
69         $LIBTOOLIZE --force --copy && \
70         autoconf && \
71         automake --include-deps --add-missing --force-missing --copy || exit 1
72
73 # Let's not fall off the end...
74 exit 0