* gcov-io.c (gcov_read_words): Don't call memmove if excess is 0.
[official-gcc.git] / libjava / classpath / autogen.sh
blobadb8f0c940880a96a7c2bb934f0caa1e668240d5
1 #!/bin/sh
2 # Run this to generate all the initial makefiles, etc.
4 srcdir=`dirname $0`
5 test -z "$srcdir" && srcdir=.
7 ORIGDIR=`pwd`
8 cd $srcdir
9 PROJECT=classpath
10 TEST_TYPE=-f
11 FILE=java/lang/Object.java
13 DIE=0
15 LIBTOOLIZE=libtoolize
17 have_libtool=false
18 if ${LIBTOOLIZE} --version < /dev/null > /dev/null 2>&1 ; then
19 libtool_version=`${LIBTOOLIZE} --version | sed 's/^.*[^0-9.]\([0-9]\{1,\}\.[0-9.]\{1,\}\).*/\1/'`
20 case $libtool_version in
21 1.5*|2.*)
22 have_libtool=true
24 esac
26 if $have_libtool ; then : ; else
27 echo
28 echo "You must have libtool 1.5 installed to compile $PROJECT."
29 echo "Install the appropriate package for your distribution,"
30 echo "or get the source tarball at http://ftp.gnu.org/gnu/libtool/"
31 echo "For Darwin you need the latest stable (1.5.22) to support"
32 echo "Frameworks linking. Also, you have to point"
33 echo "LOCAL_AUTORECONF_FLAGS to this libtool/share/aclocal."
34 DIE=1
37 if test "$DIE" -eq 1; then
38 exit 1
41 test $TEST_TYPE $FILE || {
42 echo "You must run this script in the top-level $PROJECT directory"
43 exit 1
46 if test "x$AUTOGEN_SUBDIR_MODE" = "xyes"; then
47 if test -z "$*"; then
48 echo "I am going to run ./configure with no arguments - if you wish "
49 echo "to pass any to it, please specify them on the $0 command line."
53 autoreconf --force --install --warnings=no-portability || exit $?
55 cd $ORIGDIR || exit $?
57 if test "x$AUTOGEN_SUBDIR_MODE" = "xyes"; then
58 $srcdir/configure --enable-maintainer-mode $AUTOGEN_CONFIGURE_ARGS "$@" || exit $?
60 echo
61 echo "Now type 'make' to compile $PROJECT."