https://gcc.gnu.org/g:2dff71f6fcbd84570e282b6c884ae246715c621e
commit 2dff71f6fcbd84570e282b6c884ae246715c621e Author: Arthur Cohen <arthur.co...@embecosm.com> Date: Tue Apr 9 13:43:01 2024 +0200 rust: Add --offline flag to cargo when building Rust components. gcc/rust/ChangeLog: * Make-lang.in: Add --offline flag to cargo invocation. Diff: --- gcc/rust/Make-lang.in | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gcc/rust/Make-lang.in b/gcc/rust/Make-lang.in index 1efab4987db5..bec02f79731a 100644 --- a/gcc/rust/Make-lang.in +++ b/gcc/rust/Make-lang.in @@ -421,8 +421,9 @@ rust/%.o: rust/lex/%.cc %.toml: echo $@ +# TODO: Improve `cargo` invocation with host specific flags, possibly creating a $(CARGO) variable? rust/libformat_parser.a: $(srcdir)/../libgrust/libformat_parser/Cargo.toml $(wildcard $(srcdir)/../libgrust/libformat_parser/src/*.rs) - cargo build --manifest-path $(srcdir)/../libgrust/libformat_parser/Cargo.toml # FIXME: Not always release, right? + cd $(srcdir)/../libgrust/libformat_parser && cargo build --offline # FIXME: Not always release, right? cp $(srcdir)/../libgrust/libformat_parser/target/debug/liblibformat_parser.a $@ # build all rust/parse files in rust folder, add cross-folder includes