]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
If --enable-add-ons is given without an argument, set the addons list
authorUlrich Drepper <drepper@redhat.com>
Fri, 12 Dec 1997 02:29:18 +0000 (02:29 +0000)
committerUlrich Drepper <drepper@redhat.com>
Fri, 12 Dec 1997 02:29:18 +0000 (02:29 +0000)
to all subdirs with a configure script.

configure.in

index 5d35ac51c505936aead2532c961d9a80594ff626..c3b971451f3d94a373f25ce0bf78b61db5ce52cf 100644 (file)
@@ -85,14 +85,24 @@ fi
 
 dnl Generic infrastructure for drop-in additions to libc.
 AC_ARG_ENABLE(add-ons, dnl
-[  --enable-add-ons=DIR... configure and build named extra directories],
-             [add_ons=`echo "$enableval" | sed 's/,/ /g'`],
-             [add_ons=])
+[  --enable-add-ons[=DIR1,DIR2]... configure and build add-ons in DIR1,DIR2,...
+                                  search for add-ons if no parameter given],
+ [case "$enableval" in
+    yes) add_ons=`echo $srcdir/*/configure | \
+                 sed -e "s!$srcdir/!!g" -e 's!/configure!!g'`;;
+    *) add_ons=`echo "$enableval" | sed 's/,/ /g'`;;
+   esac],
+  [add_ons=])
 AC_CONFIG_SUBDIRS($add_ons)
 add_ons_pfx=
 if test x"$add_ons" != x; then
   for f in $add_ons; do
-    add_ons_pfx="$add_ons_pfx $f/"
+    # Test whether such a subdir really exists.
+    if test -d $srcdir/$f; then
+      add_ons_pfx="$add_ons_pfx $f/"
+    else
+      AC_MSG_ERROR(add-on directory \"$f\" does not exist)
+    fi
   done
 fi