another autoconf patch


Subject: another autoconf patch
From: Alec Wolman (wolman@cs.washington.edu)
Date: Sat Jul 07 2001 - 20:18:24 CDT


The following patch changes configure.in-v2.13 and configure.in-v2.50
to add a new option: --enable-peer-config. This option is on by
default (in order to be consistent with the previous behavior), but
it can be used to disable the automatic running of configure in
the peer directories. This is needed on some systems when the
configure options are different for the peer directories than
they are for the abi directory. Comments?

Alec

--- ../configure.in-v2.13.orig Sat Jul 7 17:26:22 2001
+++ ../configure.in-v2.13 Sat Jul 7 17:39:04 2001
@@ -96,11 +96,13 @@
 AC_SUBST(ABIWORD_APP_LIBDIR)
 
 dnl ./configure command line arguments
-dnl curretnly, we have:
+dnl currently, we have:
 dnl --enable-gnome
 dnl --enable-debug
 dnl --enable-extra-optimization
 dnl --enable-profile
+dnl --enable-bidi
+dnl --enable-peer-config
 dnl --with-pspell
 dnl --with-libxml2
 dnl The defined values are used mostly in includes.mk, but also in
@@ -161,6 +163,17 @@
        *) AC_MSG_ERROR(bad value ${enableval} for --enable-bidi) ;;
      esac],[BIDI_CFLAGS=""])
 
+# by default, configure in the abi directory runs the same configure command
+# in the peer directories (wv, expat, etc...). this provides a way to
+# disable that behavior.
+AC_ARG_ENABLE(peer-config,
+ [ --enable-peer-config Enable automatic configuration of peer directories (on by default) ],
+ [case "${enableval}" in
+ yes) peerconfig=true ;;
+ no) peerconfig=false ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for --enable-peer-config) ;;
+ esac],[peerconfig=true])
+
 AC_ARG_ENABLE(scripting,
     [ --enable-scripting Enable the perl scripting interface ],
      [case "${enableval}" in
@@ -302,18 +315,21 @@
 AC_TYPE_SIGNAL
 AC_CHECK_FUNCS(re_comp regcomp strdup strstr)
 
-dnl other configure scripts
-# AC_CONFIG_SUBDIRS($PEERDIRS) won't work :-(
-for i in . $PEERDIRS; do
- if test $i != . ; then
- echo "Running configure in ${i}"
- config_flags='--disable-shared --enable-static'
- if test `basename "$i"` = wv; then
- config_flags="$config_flags --with-exporter"
- fi
- (cd $i; ./configure $config_flags)
- fi
-done
+if test $peerconfig = "true"; then
+ dnl other configure scripts
+ # AC_CONFIG_SUBDIRS($PEERDIRS) won't work :-(
+ for i in . $PEERDIRS; do
+ if test $i != . ; then
+ echo "Running configure in ${i}"
+ config_flags='--disable-shared --enable-static'
+ if test `basename "$i"` = wv; then
+ config_flags="$config_flags --with-exporter"
+ fi
+ (cd $i; ./configure $config_flags)
+ fi
+ done
+fi
+
 AC_SUBST(PEERDIRS)
 AC_SUBST(PEERS)

--- ../configure.in-v2.50.orig Mon Jul 2 15:22:01 2001
+++ ../configure.in-v2.50 Sat Jul 7 17:35:59 2001
@@ -98,11 +98,13 @@
 AC_SUBST(ABIWORD_APP_LIBDIR)
 
 dnl ./configure command line arguments
-dnl curretnly, we have:
+dnl currently, we have:
 dnl --enable-gnome
 dnl --enable-debug
 dnl --enable-extra-optimization
 dnl --enable-profile
+dnl --enable-bidi
+dnl --enable-peer-config
 dnl --with-pspell
 dnl --with-libxml2
 dnl The defined values are used mostly in includes.mk, but also in
@@ -163,6 +165,17 @@
        *) AC_MSG_ERROR(bad value ${enableval} for --enable-bidi) ;;
      esac],[BIDI_CFLAGS=""])
 
+# by default, configure in the abi directory runs the same configure command
+# in the peer directories (wv, expat, etc...). this provides a way to
+# disable that behavior.
+AC_ARG_ENABLE(peer-config,
+ [ --enable-peer-config Enable automatic configuration of peer directories (on by default) ],
+ [case "${enableval}" in
+ yes) peerconfig=true ;;
+ no) peerconfig=false ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for --enable-peer-config) ;;
+ esac],[peerconfig=true])
+
 AC_ARG_ENABLE(scripting,
     [ --enable-scripting Enable the perl scripting interface ],
      [case "${enableval}" in
@@ -303,18 +316,21 @@
 AC_TYPE_SIGNAL
 AC_CHECK_FUNCS(re_comp regcomp strdup strstr)
 
-dnl other configure scripts
-# AC_CONFIG_SUBDIRS($PEERDIRS) won't work :-(
-for i in . $PEERDIRS; do
- if test $i != . ; then
- echo "Running configure in ${i}"
- config_flags='--disable-shared --enable-static'
- if test `basename "$i"` = wv; then
- config_flags="$config_flags --with-exporter"
- fi
- (cd $i; ./configure $config_flags)
- fi
-done
+if test $peerconfig = "true"; then
+ dnl other configure scripts
+ # AC_CONFIG_SUBDIRS($PEERDIRS) won't work :-(
+ for i in . $PEERDIRS; do
+ if test $i != . ; then
+ echo "Running configure in ${i}"
+ config_flags='--disable-shared --enable-static'
+ if test `basename "$i"` = wv; then
+ config_flags="$config_flags --with-exporter"
+ fi
+ (cd $i; ./configure $config_flags)
+ fi
+ done
+fi
+
 AC_SUBST(PEERDIRS)
 AC_SUBST(PEERS)
 



This archive was generated by hypermail 2b25 : Sat Jul 07 2001 - 20:18:33 CDT