Skip to content

Commit

Permalink
cargo config.toml instead of cargo config
Browse files Browse the repository at this point in the history
  • Loading branch information
schmidma committed Jan 9, 2025
1 parent 5645a71 commit 327aa6b
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 0 deletions.
3 changes: 3 additions & 0 deletions kas/base.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,9 @@ repos:
0003-specify-custom-dynamic-linker:
repo: "meta-nao"
path: "patches/0003-bindgen-clang-sysroot.patch"
0006-cargo-config-is-deprecated:
repo: "meta-nao"
path: "patches/0006-cargo-config-is-deprecated.patch"
meta-congatec-x86:
url: "https://git.congatec.com/x86/meta-congatec-x86.git"
commit: 1867244888ed0a5ad85f5b4ab789e1d0201deb02
Expand Down
25 changes: 25 additions & 0 deletions patches/0006-cargo-config-is-deprecated.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
diff --git a/meta/recipes-devtools/rust/rust-cross-canadian.inc b/meta/recipes-devtools/rust/rust-cross-canadian.inc
index 5b88381f11..9d2726ca1f 100644
--- a/meta/recipes-devtools/rust/rust-cross-canadian.inc
+++ b/meta/recipes-devtools/rust/rust-cross-canadian.inc
@@ -73,13 +73,13 @@ do_install () {
export CARGO_HOME="\$OECORE_TARGET_SYSROOT/home/cargo"
mkdir -p "\$CARGO_HOME"
# Init the default target once, it might be otherwise user modified.
- if [ ! -f "\$CARGO_HOME/config" ]; then
- touch "\$CARGO_HOME/config"
- echo "[build]" >> "\$CARGO_HOME/config"
- echo 'target = "'${RUST_TARGET_SYS}'"' >> "\$CARGO_HOME/config"
- echo '# TARGET_SYS' >> "\$CARGO_HOME/config"
- echo '[target.'${RUST_TARGET_SYS}']' >> "\$CARGO_HOME/config"
- echo 'linker = "target-rust-ccld"' >> "\$CARGO_HOME/config"
+ if [ ! -f "\$CARGO_HOME/config.toml" ]; then
+ touch "\$CARGO_HOME/config.toml"
+ echo "[build]" >> "\$CARGO_HOME/config.toml"
+ echo 'target = "'${RUST_TARGET_SYS}'"' >> "\$CARGO_HOME/config.toml"
+ echo '# TARGET_SYS' >> "\$CARGO_HOME/config.toml"
+ echo '[target.'${RUST_TARGET_SYS}']' >> "\$CARGO_HOME/config.toml"
+ echo 'linker = "target-rust-ccld"' >> "\$CARGO_HOME/config.toml"
fi

# Keep the below off as long as HTTP/2 is disabled.

0 comments on commit 327aa6b

Please sign in to comment.