Skip to content
Joachim Schiele edited this page Jul 23, 2024 · 45 revisions

Motivation

We start with rust/cargo on linux to make it work with nix as backend, see https://github.com/NixOS/nix/pull/8699 for this

https://lastlog.de/blog/libnix_roadmap.html#cargo-with-nix-support

https://github.com/NixOS/nix/pull/8699

Working branch

https://github.com/nixcloud/cargo/tree/libnix-0.79.0

https://github.com/Anillc/nixrs/pull/1

~/.cargo

[nixos@nixos:~/cargo]$ du -sh ~/.cargo
239M    /home/nixos/.cargo

[nixos@nixos:~/cargo]$ ls ~/.cargo/
registry

[nixos@nixos:~/cargo]$ ls ~/.cargo/registry/
cache  CACHEDIR.TAG  index  src

~/cargo

the example is the cargo itself, the tool coming with the rust toolchain, since we hack on it.

[nixos@nixos:~/cargo]$ du -sh target/
2.3G    target/

[nixos@nixos:~/cargo]$ ls target/
CACHEDIR.TAG  debug

[nixos@nixos:~/cargo]$ ls target/debug/
build  cargo  cargo.d  deps  examples  incremental  libcargo.d  libcargo.rlib

Clone this wiki locally