Use a boot script instead of having autoreconf recurse
authorIan Lynagh <igloo@earth.li>
Tue, 10 Apr 2007 21:52:52 +0000 (21:52 +0000)
committerIan Lynagh <igloo@earth.li>
Tue, 10 Apr 2007 21:52:52 +0000 (21:52 +0000)
It used to be the case that
    autoreconf
in the root would also autoreconf in any libraries that need it, and
    ./configure
in the root would also configure all the libraries.

However, cabal now configures the libraries, so they were getting
configured twice.

Thus now a small shellscript, boot, autoreconfs the root and all libraries
that need it, and ./configure in the root doesn't configure the libraries.

boot [new file with mode: 0644]
configure.ac
libraries/aclocal.m4 [deleted file]
libraries/configure.ac [deleted file]

diff --git a/boot b/boot
new file mode 100644 (file)
index 0000000..aa90626
--- /dev/null
+++ b/boot
@@ -0,0 +1,15 @@
+#!/bin/sh
+
+set -e
+
+autoreconf
+
+for lib in libraries/*; do
+    if test -e $lib/configure.ac
+    then
+        cd $lib
+        autoreconf
+        cd ../..
+    fi
+done
+
index dce5a07..70936e2 100644 (file)
@@ -44,13 +44,6 @@ dnl We need 2.50 due to the use of AC_SYS_LARGEFILE and AC_MSG_NOTICE.
 dnl We need 2.52 due to the use of AS_TR_CPP and AS_TR_SH.
 AC_PREREQ([2.52])
 
-dnl * Declare subdirectories that have a private configure script
-dnl
-dnl After the toplevel configuration is complete, the script will recurse into
-dnl these subdirectories if they exist. The use of a cache file makes repeated
-dnl checks cheap.
-AC_CONFIG_SUBDIRS([libraries])
-
 # -------------------------------------------------------------------------
 # Prepare to generate the following header files
 #
diff --git a/libraries/aclocal.m4 b/libraries/aclocal.m4
deleted file mode 100644 (file)
index fbea551..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-# Empty file to avoid a dependency on automake: autoreconf calls aclocal to
-# generate a temporary aclocal.m4t when no aclocal.m4 is present.
diff --git a/libraries/configure.ac b/libraries/configure.ac
deleted file mode 100644 (file)
index d4b0229..0000000
+++ /dev/null
@@ -1,45 +0,0 @@
-# Initialise and check sanity.
-AC_INIT([Haskell hierarchical libraries], [1.0], [libraries@haskell.org], [libraries])
-AC_CONFIG_SRCDIR([libraries-footer.txt])
-
-if test -d base; then
-  AC_CONFIG_SUBDIRS(base)
-fi
-if test -d readline; then
-  AC_CONFIG_SUBDIRS(readline)
-fi
-if test -d network; then
-  AC_CONFIG_SUBDIRS(network)
-fi
-if test -d X11; then
-  AC_CONFIG_SUBDIRS(X11)
-fi
-if test -d Win32; then
-  AC_CONFIG_SUBDIRS(Win32)
-fi
-if test -d HGL; then
-  AC_CONFIG_SUBDIRS(HGL)
-fi
-if test -d OpenGL; then
-  AC_CONFIG_SUBDIRS(OpenGL)
-fi
-if test -d GLUT; then
-  AC_CONFIG_SUBDIRS(GLUT)
-fi
-if test -d OpenAL; then
-  AC_CONFIG_SUBDIRS(OpenAL)
-fi
-if test -d ALUT; then
-  AC_CONFIG_SUBDIRS(ALUT)
-fi
-if test -d time; then
-  AC_CONFIG_SUBDIRS(time)
-fi
-if test -d unix; then
-  AC_CONFIG_SUBDIRS(unix)
-fi
-if test -d regex-posix; then
-  AC_CONFIG_SUBDIRS(regex-posix)
-fi
-
-AC_OUTPUT