a929538d20a626286197af48899ff6ce0c5ed645
[vuplus_openembedded] / packages / webkit / webkit-gtk / autogen.sh
1 #! /bin/sh
2
3 # Allow invocation from a separate build directory; in that case, we change
4 # to the source directory to run the auto*, then change back before running configure
5 srcdir=`dirname $0`
6 test -z "$srcdir" && srcdir=.
7
8 ORIGDIR=`pwd`
9 cd $srcdir
10
11 DIE=0
12
13 (autoconf --version) < /dev/null > /dev/null 2>&1 || {
14     echo
15     echo "You must have autoconf installed to compile $PROJECT."
16     echo "Install the appropriate package for your distribution,"
17     echo "or get the source tarball at http://ftp.gnu.org/gnu/autoconf/"
18     DIE=1
19 }
20
21 (automake --version) < /dev/null > /dev/null 2>&1 || {
22     echo
23     echo "You must have automake installed to compile $PROJECT."
24     echo "Install the appropriate package for your distribution,"
25     echo "or get the source tarball at http://ftp.gnu.org/gnu/automake/"
26     DIE=1
27 }
28
29 LIBTOOLIZE=libtoolize
30 ($LIBTOOLIZE --version) < /dev/null > /dev/null 2>&1 || {
31     LIBTOOLIZE=glibtoolize
32     ($LIBTOOLIZE --version) < /dev/null > /dev/null 2>&1 || {
33         echo
34         echo "You must have libtool installed to compile $PROJECT."
35         echo "Install the appropriate package for your distribution,"
36         echo "or get the source tarball at http://ftp.gnu.org/gnu/libtool/"
37         DIE=1
38     }
39 }
40
41 if test "$DIE" -eq 1; then
42     exit 1
43 fi
44
45 rm -rf $top_srcdir/autom4te.cache
46
47 touch README INSTALL
48
49 aclocal || exit $?
50 $LIBTOOLIZE --force || exit $?
51 autoheader || exit $?
52 automake --foreign --add-missing || exit $?
53 autoconf || exit $?
54
55 cd $ORIGDIR || exit 1
56
57 $srcdir/configure $AUTOGEN_CONFIGURE_ARGS "$@" || exit $?