2 # Run this to generate all the initial makefiles, etc.
3 # Ripped off from GNOME macros version
8 test -z "$srcdir" && srcdir=.
10 (autoconf --version) < /dev/null > /dev/null 2>&1 || {
12 echo "**Error**: You must have \`autoconf' installed to compile Gst#."
13 echo "Download the appropriate package for your distribution,"
14 echo "or get the source tarball at ftp://ftp.gnu.org/pub/gnu/"
18 if [ -z "$LIBTOOL" ]; then
19 LIBTOOL=`which glibtool 2>/dev/null`
20 if [ ! -x "$LIBTOOL" ]; then
21 LIBTOOL=`which libtool`
25 (grep "^AM_PROG_LIBTOOL" $srcdir/configure.ac >/dev/null) && {
26 ($LIBTOOL --version) < /dev/null > /dev/null 2>&1 || {
28 echo "**Error**: You must have \`libtool' installed to compile Gst#."
29 echo "Get ftp://ftp.gnu.org/pub/gnu/libtool-1.2d.tar.gz"
30 echo "(or a newer version if it is available)"
35 (automake --version) < /dev/null > /dev/null 2>&1 || {
37 echo "**Error**: You must have \`automake' installed to compile Gst#."
38 echo "Get ftp://ftp.gnu.org/pub/gnu/automake-1.3.tar.gz"
39 echo "(or a newer version if it is available)"
45 # if no automake, don't bother testing for aclocal
46 test -n "$NO_AUTOMAKE" || (aclocal --version) < /dev/null > /dev/null 2>&1 || {
48 echo "**Error**: Missing \`aclocal'. The version of \`automake'"
49 echo "installed doesn't appear recent enough."
50 echo "Get ftp://ftp.gnu.org/pub/gnu/automake-1.3.tar.gz"
51 echo "(or a newer version if it is available)"
55 if test "$DIE" -eq 1; then
60 echo "**Warning**: I am going to run \`configure' with no arguments."
61 echo "If you wish to pass any to it, please specify them on the"
62 echo \`$0\'" command line."
68 am_opt=--include-deps;;
72 if grep "^AM_PROG_LIBTOOL" configure.ac >/dev/null; then
73 if test -z "$NO_LIBTOOLIZE" ; then
74 echo "Running libtoolize..."
75 libtoolize --force --copy
79 echo "Running aclocal $ACLOCAL_FLAGS ..."
80 aclocal $ACLOCAL_FLAGS || {
82 echo "**Error**: aclocal failed. This may mean that you have not"
83 echo "installed all of the packages you need, or you may need to"
84 echo "set ACLOCAL_FLAGS to include \"-I \$prefix/share/aclocal\""
85 echo "for the prefix where you installed the packages whose"
86 echo "macros were not found"
90 if grep "^AM_CONFIG_HEADER" configure.ac >/dev/null; then
91 echo "Running autoheader..."
92 autoheader || { echo "**Error**: autoheader failed."; exit 1; }
95 echo "Running automake --gnu $am_opt ..."
96 automake --add-missing --gnu $am_opt ||
97 { echo "**Error**: automake failed."; exit 1; }
98 echo "Running autoconf ..."
99 autoconf || { echo "**Error**: autoconf failed."; exit 1; }
102 conf_flags="--enable-maintainer-mode --enable-compile-warnings" #--enable-iso-c
104 if test x$NOCONFIGURE = x; then
105 echo Running $srcdir/configure $conf_flags "$@" ...
106 $srcdir/configure $conf_flags "$@" \
107 && echo Now type \`make\' to compile $PKG_NAME || exit 1
109 echo Skipping configure process.