summaryrefslogtreecommitdiff
path: root/configure.in
diff options
context:
space:
mode:
authorAlexandre Oliva <aoliva@redhat.com>2000-12-12 20:33:05 +0000
committerAlexandre Oliva <aoliva@redhat.com>2000-12-12 20:33:05 +0000
commite1127ef37d28b7359afa617c1eb218751d568059 (patch)
tree0eff5322d7065dd9995ac5cd9e3f44b8bdc91767 /configure.in
parent17e2c9fefc8420bfc88d4bf917bc4627a0394389 (diff)
downloadgdb-e1127ef37d28b7359afa617c1eb218751d568059.tar.gz
* configure.in: Disable language-specific target libraries fornewlib-1_9_0
languages that aren't enabled.
Diffstat (limited to 'configure.in')
-rw-r--r--configure.in49
1 files changed, 49 insertions, 0 deletions
diff --git a/configure.in b/configure.in
index b9e1b715c04..f79d9a34696 100644
--- a/configure.in
+++ b/configure.in
@@ -948,6 +948,55 @@ if [ x$with_gnu_as = xno ]; then
noconfigdirs="$noconfigdirs gas"
fi
+# Figure out what language subdirectories are present.
+# Look if the user specified --enable-languages="..."; if not, use
+# the environment variable $LANGUAGES if defined. $LANGUAGES might
+# go away some day.
+if test x"${enable_languages+set}" != xset; then
+ if test x"${LANGUAGES+set}" = xset; then
+ enable_languages="`echo ${LANGUAGES} | tr ' ' ','`"
+ else
+ enable_languages=all
+ fi
+else
+ if test x"${enable_languages}" = x; then
+ echo configure.in: --enable-languages needs at least one argument 1>&2
+ exit 1
+ fi
+fi
+subdirs=
+for lang in ${srcdir}/gcc/*/config-lang.in ..
+do
+ case $lang in
+ ..) ;;
+ # The odd quoting in the next line works around
+ # an apparent bug in bash 1.12 on linux.
+ ${srcdir}/gcc/[*]/config-lang.in) ;;
+ *)
+ lang_alias=`sed -n -e 's,^language=['"'"'"'"]\(.*\)["'"'"'"'].*$,\1,p' -e 's,^language=\([^ ]*\).*$,\1,p' $lang`
+ this_lang_libs=`sed -n -e 's,^target_libs=['"'"'"'"]\(.*\)["'"'"'"'].*$,\1,p' -e 's,^target_libs=\([^ ]*\).*$,\1,p' $lang`
+ build_by_default=`sed -n -e 's,^build_by_default=['"'"'"'"]\(.*\)["'"'"'"'].*$,\1,p' -e 's,^build_by_default=\([^ ]*\).*$,\1,p' $lang`
+ if test "x$lang_alias" = x
+ then
+ echo "$lang doesn't set \$language." 1>&2
+ exit 1
+ fi
+ case ${build_by_default},${enable_languages}, in
+ *,$lang_alias,*) add_this_lang=yes ;;
+ no,*) add_this_lang=no ;;
+ *,all,*) add_this_lang=yes ;;
+ *) add_this_lang=no ;;
+ esac
+ if test x"${add_this_lang}" = xyes; then
+ eval target_libs='"$target_libs "'\"$this_lang_libs\"
+ else
+ eval noconfigdirs='"$noconfigdirs "'\"$this_lang_libs\"
+ fi
+ ;;
+ esac
+done
+
+
# Remove the entries in $skipdirs and $noconfigdirs from $configdirs and
# $target_configdirs.
# If we have the source for $noconfigdirs entries, add them to $notsupp.