summaryrefslogtreecommitdiff
path: root/etc/defaults/rust/nix.TARGETS
diff options
context:
space:
mode:
authorKlaus Aehlig <klaus.aehlig@huawei.com>2024-06-27 12:25:35 +0200
committerGitHub <noreply@github.com>2024-06-27 12:25:35 +0200
commit05b2d6fc51146fe07340a58bc87fbbd99e788143 (patch)
tree2c607815866fdb7887dc5486255d2a7729f23578 /etc/defaults/rust/nix.TARGETS
parent7dc9a7b9107b2607e9870d7fc92fb2d40505f7ef (diff)
parentc6b35f8f2e83621b4e53ab999e5b5bf146a73aa0 (diff)
downloadhello-nix-05b2d6fc51146fe07340a58bc87fbbd99e788143.tar.gz
Merge pull request #3 from aehlig/cargo-example
Add example on how to use cargo
Diffstat (limited to 'etc/defaults/rust/nix.TARGETS')
-rw-r--r--etc/defaults/rust/nix.TARGETS43
1 files changed, 43 insertions, 0 deletions
diff --git a/etc/defaults/rust/nix.TARGETS b/etc/defaults/rust/nix.TARGETS
new file mode 100644
index 0000000..fbd1a69
--- /dev/null
+++ b/etc/defaults/rust/nix.TARGETS
@@ -0,0 +1,43 @@
+{ "defaults":
+ { "type": "configure"
+ , "target": "defaults (unconfigured)"
+ , "arguments_config": ["TOOLCHAIN_CONFIG"]
+ , "config":
+ { "type": "let*"
+ , "bindings":
+ [ [ "toolchain"
+ , { "type": "lookup"
+ , "map":
+ { "type": "var"
+ , "name": "TOOLCHAIN_CONFIG"
+ , "default": {"type": "empty_map"}
+ }
+ , "key": "RUST"
+ , "default": {"type": "empty_map"}
+ }
+ ]
+ , [ "RUSTC"
+ , { "type": "lookup"
+ , "map": {"type": "var", "name": "toolchain"}
+ , "key": "RUSTC"
+ , "default": "rustc"
+ }
+ ]
+ , [ "PATH"
+ , { "type": "lookup"
+ , "map": {"type": "var", "name": "toolchain"}
+ , "key": "PATH"
+ , "default": []
+ }
+ ]
+ ]
+ , "body": {"type": "env", "vars": ["RUSTC", "PATH"]}
+ }
+ }
+, "defaults (unconfigured)":
+ { "type": "defaults"
+ , "arguments_config": ["RUSTC", "PATH"]
+ , "RUSTC": [{"type": "var", "name": "RUSTC"}]
+ , "PATH": {"type": "var", "name": "PATH"}
+ }
+}