]> Pileus Git - ~andy/gtk/blobdiff - autogen.sh
stylecontext: Do invalidation on first resize container
[~andy/gtk] / autogen.sh
index c298ddee64fda3d0cc2e6afeb6b811259021aa9d..17ee16a58c35a07ae6630056694b54fb4246014e 100755 (executable)
@@ -1,52 +1,34 @@
 #!/bin/sh
 # Run this to generate all the initial makefiles, etc.
 
-DIE=0
+test -n "$srcdir" || srcdir=`dirname "$0"`
+test -n "$srcdir" || srcdir=.
 
-(autoconf --version) < /dev/null > /dev/null 2>&1 || {
-       echo
-       echo "You must have autoconf installed to compile GTK+."
-       echo "Download the appropriate package for your distribution,"
-       echo "or get the source tarball at ftp://ftp.gnu.org/pub/gnu/"
-       DIE=1
-}
+olddir=`pwd`
+cd "$srcdir"
 
-(libtool --version) < /dev/null > /dev/null 2>&1 || {
-       echo
-       echo "You must have libtool installed to compile GTK+."
-       echo "Get ftp://alpha.gnu.org/gnu/libtool-1.0h.tar.gz"
-       echo "(or a newer version if it is available)"
-       DIE=1
-}
+mkdir -p m4
 
-(automake --version) < /dev/null > /dev/null 2>&1 || {
-       echo
-       echo "You must have automake installed to compile GTK+."
-       echo "Get ftp://ftp.cygnus.com/pub/home/tromey/automake-1.2d.tar.gz"
-       echo "(or a newer version if it is available)"
-       DIE=1
-}
-
-if test "$DIE" -eq 1; then
-       exit 1
+GTKDOCIZE=`which gtkdocize`
+if test -z $GTKDOCIZE; then
+        echo "*** No GTK-Doc found, please install it ***"
+        exit 1
+else
+        gtkdocize || exit $?
 fi
 
-(test -d gtk && test -d glib) || {
-       echo "You must run this script in the top-level GTK+ directory"
-       exit 1
-}
-
-if test -z "$*"; then
-       echo "I am going to run ./configure with no arguments - if you wish "
-        echo "to pass any to it, please specify them on the $0 command line."
+# README and INSTALL are required by automake, but may be deleted by clean
+# up rules. to get automake to work, simply touch these here, they will be
+# regenerated from their corresponding *.in files by ./configure anyway.
+touch README INSTALL
+
+AUTORECONF=`which autoreconf`
+if test -z $AUTORECONF; then
+        echo "*** No autoreconf found, please install it ***"
+        exit 1
+else
+        autoreconf --force --install --verbose || exit $?
 fi
 
-for i in glib .
-do 
-  echo processing $i
-  (cd $i; aclocal; automake; autoconf)
-done
-./configure "$@"
-
-echo 
-echo "Now type 'make' to compile GTK+."
+cd "$olddir"
+test -n "$NOCONFIGURE" || "$srcdir/configure" "$@"