Fix typo.
[gpgme.git] / autogen.sh
index a386bb0..d7da76d 100755 (executable)
@@ -4,10 +4,10 @@
 
 PGM=GPGME
 lib_config_files=""
-autoconf_vers=2.13
-automake_vers=1.4
-aclocal_vers=1.4
-libtool_vers=1.3
+autoconf_vers=2.52
+automake_vers=1.5
+aclocal_vers=1.5
+libtool_vers=1.4
 
 DIE=no
 if test "$1" = "--build-w32"; then
@@ -31,7 +31,15 @@ if test "$1" = "--build-w32"; then
         fi
     fi
 
-    crossbindir=`mingw32 --install-dir`/bin
+    crossinstalldir=`mingw32 --install-dir`
+    crossbindir=`mingw32 --get-bindir 2>/dev/null` \
+               || crossbindir="$crossinstalldir/bin"
+    crossdatadir=`mingw32 --get-datadir 2>/dev/null` \
+               || crossdatadir="$crossinstalldir/share"
+    crosslibdir=`mingw32 --get-libdir 2>/dev/null` \
+               || crosslibdir="$crossinstalldir/i386--mingw32/lib"
+    crossincdir=`mingw32 --get-includedir 2>/dev/null` \
+               || crossincdir="$crossinstalldir/i386--mingw32/include"
     CC=`mingw32 --get-path gcc`
     CPP=`mingw32 --get-path cpp`
     AR=`mingw32 --get-path ar`
@@ -54,8 +62,10 @@ if test "$1" = "--build-w32"; then
     fi
     [ $DIE = yes ] && exit 1
 
-    ./configure --host=${host} --target=${target} \
-                ${disable_foo_tests} $*
+    ./configure --host=${host} --target=${target}  ${disable_foo_tests} \
+                --bindir=${crossbindir} --libdir=${crosslibdir} \
+                --datadir=${crossdatadir} --includedir=${crossincdir} \
+                --enable-maintainer-mode $*
     exit $?
 fi
 
@@ -133,19 +143,7 @@ echo "Running aclocal..."
 aclocal
 echo "Running autoheader..."
 autoheader
-echo "Running automake --gnu ..."
-automake --gnu;
+echo "Running automake --gnu -a ..."
+automake --gnu -a
 echo "Running autoconf..."
 autoconf
-
-if test "$*" = ""; then
-    conf_options="--enable-maintainer-mode"
-else
-   conf_options=$*
-fi
-echo "Running ./configure $conf_options"
-./configure $conf_options
-
-
-
-