eed59f52ac5156652b8e83575c0358d84dd0f5e0
[platform/upstream/glib.git] / autogen.sh
1 #!/bin/sh
2 # Run this to generate all the initial makefiles, etc.
3
4 test -n "$srcdir" || srcdir=`dirname "$0"`
5 test -n "$srcdir" || srcdir=.
6
7 olddir=`pwd`
8 cd "$srcdir"
9
10 # GNU gettext automake support doesn't get along with git.
11 # https://bugzilla.gnome.org/show_bug.cgi?id=661128
12 touch -t 200001010000 po/glib.pot
13
14 GTKDOCIZE=$(which gtkdocize 2>/dev/null)
15 if test -z $GTKDOCIZE; then
16         echo "You don't have gtk-doc installed, and thus won't be able to generate the documentation."
17         rm -f gtk-doc.make
18         echo 'EXTRA_DIST =' > gtk-doc.make
19 else
20         gtkdocize || exit $?
21 fi
22
23 AUTORECONF=`which autoreconf`
24 if test -z $AUTORECONF; then
25         echo "*** No autoreconf found, please install it ***"
26         exit 1
27 fi
28
29 # README and INSTALL are required by automake, but may be deleted by clean
30 # up rules. to get automake to work, simply touch these here, they will be
31 # regenerated from their corresponding *.in files by ./configure anyway.
32 touch README INSTALL
33
34 autoreconf --force --install --verbose || exit $?
35
36 cd "$olddir"
37 test -n "$NOCONFIGURE" || "$srcdir/configure" "$@"