]> git.ipfire.org Git - thirdparty/gcc.git/blobdiff - configure.ac
top-level configure: setup target_configdirs based on repository
[thirdparty/gcc.git] / configure.ac
index 1df038b04f361867333769ec3a27f7b6ed59008d..c523083c346f21e4c9856f56a4f03d6e8c15b929 100644 (file)
@@ -2272,6 +2272,16 @@ case ,${enable_languages}, in
     ;;
 esac
 
+# If gcc/ is not in the source tree then we'll not be building a
+# target compiler, assume in that case we don't want to build any
+# target libraries or tools.
+#
+# This was added primarily for the benefit for binutils-gdb who reuse
+# this configure script, but don't always have target tools available.
+if test ! -d ${srcdir}/gcc; then
+   skipdirs="${skipdirs} ${target_configdirs}"
+fi
+
 # Remove the entries in $skipdirs and $noconfigdirs from $configdirs,
 # $build_configdirs and $target_configdirs.
 # If we have the source for $noconfigdirs entries, add them to $notsupp.