* Makefile.am:
[monodevelop.git] / main / autogen.sh
blob008df44421de44f1d0fb8a439df837a53541dccb
1 #!/bin/sh
2 # Run this to generate all the initial makefiles, etc.
3 # Ripped off from GNOME macros version
5 DIE=0
7 PKG_NAME=MonoDevelop
8 WANT_AUTOCONF="2.5"
9 srcdir=`dirname $0`
10 test -z "$srcdir" && srcdir=.
12 (autoconf --version) < /dev/null > /dev/null 2>&1 || {
13 echo
14 echo "**Error**: You must have \`autoconf' installed to compile MonoDevelop."
15 echo "Download the appropriate package for your distribution, or get the "
16 echo "source at ftp://ftp.gnu.org/pub/gnu/autoconf/autoconf-2.61.tar.bz2 "
17 echo "(or a newer version if it is available)"
18 DIE=1
21 (automake --version) < /dev/null > /dev/null 2>&1 || {
22 echo
23 echo "**Error**: You must have \`automake' installed to compile MonoDevelop."
24 echo "Download the appropriate package for your distribution, or get the "
25 echo "source at ftp://ftp.gnu.org/pub/gnu/automake/automake-1.10.1.tar.bz2 "
26 echo "(or a newer version if it is available)"
27 DIE=1
28 NO_AUTOMAKE=yes
31 # if no automake, don't bother testing for aclocal
32 test -n "$NO_AUTOMAKE" || (aclocal --version) < /dev/null > /dev/null 2>&1 || {
33 echo
34 echo "**Error**: Missing \`aclocal'."
35 DIE=1
38 if test "$DIE" -eq 1; then
39 exit 1
42 if test -z "$*"; then
43 echo "**Warning**: I am going to run \`configure' with no arguments."
44 echo "If you wish to pass any to it, please specify them on the"
45 echo \`$0\'" command line."
46 echo
49 case $CC in
50 xlc )
51 am_opt=--include-deps;;
52 esac
54 echo "Running aclocal $ACLOCAL_FLAGS ..."
55 aclocal $ACLOCAL_FLAGS || {
56 echo
57 echo "**Error**: aclocal failed. This may mean that you have not"
58 echo "installed all of the packages you need, or you may need to"
59 echo "set ACLOCAL_FLAGS to include \"-I \$prefix/share/aclocal\""
60 echo "for the prefix where you installed the packages whose"
61 echo "macros were not found"
62 exit 1
65 echo "Running automake --foreign $am_opt ..."
66 automake --add-missing --foreign -Wno-portability -Wno-syntax $am_opt ||
67 { echo "**Error**: automake failed."; exit 1; }
69 echo "Running autoconf ..."
70 WANT_AUTOCONF="2.5" autoconf || { echo "**Error**: autoconf failed."; exit 1; }
73 conf_flags="--enable-maintainer-mode --enable-compile-warnings"
75 if test x$NOCONFIGURE = x; then
76 echo Running $srcdir/configure $conf_flags "$@" ...
77 $srcdir/configure $conf_flags "$@" \
78 && echo Now type \`make\' to compile $PKG_NAME || exit 1
79 else
80 echo Skipping configure process.