From 9efa75c6fa0a24c42d7be1e40ac6cd5f26cab045 Mon Sep 17 00:00:00 2001 From: Thomas Schwinge Date: Fri, 27 Oct 2023 21:53:03 +0200 Subject: [PATCH] Disable target libgrust if we're not building target libstdc++ This complements "libgrust: Add dependency to libstdc++". --- configure | 11 +++++++++++ configure.ac | 11 +++++++++++ 2 files changed, 22 insertions(+) diff --git a/configure b/configure index 2b35e4b300b6..a4cf47df42e5 100755 --- a/configure +++ b/configure @@ -9259,6 +9259,17 @@ case ,${enable_languages}, in ;; esac +case ,${enable_languages}, in + *,rust,*) + case " ${noconfigdirs} " in + *\ target-libstdc++-v3\ *) + # Disable target libgrust if we're not building target libstdc++. + noconfigdirs="$noconfigdirs target-libgrust" + ;; + esac + ;; +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. diff --git a/configure.ac b/configure.ac index d65848b9fe09..2dffdbf49ce2 100644 --- a/configure.ac +++ b/configure.ac @@ -2455,6 +2455,17 @@ case ,${enable_languages}, in ;; esac +case ,${enable_languages}, in + *,rust,*) + case " ${noconfigdirs} " in + *\ target-libstdc++-v3\ *) + # Disable target libgrust if we're not building target libstdc++. + noconfigdirs="$noconfigdirs target-libgrust" + ;; + esac + ;; +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. -- 2.40.1