]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core-contrib.git/commitdiff
rust-source: Fix remove_gcc_directory
authorRichard Purdie <richard.purdie@linuxfoundation.org>
Sat, 29 Mar 2025 14:28:51 +0000 (14:28 +0000)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Sat, 29 Mar 2025 15:24:32 +0000 (15:24 +0000)
The patch works for rust-native but not other recipes which change ${S}.
Set it to use the correct path so it works for llvm-rust, cargo and others,
maximising the space saving.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/recipes-devtools/rust/rust-source.inc

index 92bb5e4779fa82a13e559b910ca0962a77b21b1b..820cdc16e2a462f6157eb6c067b73aab23df1d2e 100644 (file)
@@ -17,7 +17,7 @@ RUSTSRC = "${WORKDIR}/rustc-${RUST_VERSION}-src"
 #After updating to Rust 1.85 we can revert this removal of "src/gcc"
 remove_gcc_directory() {
     # Ensure the gcc directory exists
-    gcc_dir="${S}/src/gcc"
+    gcc_dir="${RUSTSRC}/src/gcc"
     if [ -d "$gcc_dir" ]; then
         rm -rf "$gcc_dir"
     fi