flake.nix: set /home/h7x4/.local/share/cargo for all relevant derivations
Build and test / build-static-library (push) Failing after 1m57s
Build and test / test (push) Failing after 1m57s
Build and test / build-shared-library (push) Failing after 2m1s

This commit is contained in:
2026-05-07 00:51:39 +09:00
parent 26f30de32e
commit 0c3b1f5123
+10 -2
View File
@@ -28,9 +28,11 @@
};
rust-bin = rust-overlay.lib.mkRustBin { } pkgs.buildPackages;
toolchain = rust-bin.stable.latest.default.override {
toolchain = (rust-bin.stable.latest.default.override {
extensions = [ "rust-src" "rust-analyzer" "rust-std" ];
};
}).overrideAttrs (old: {
env.CARGO_HOME = "/tmp/cargo-home";
});
in f system pkgs toolchain);
in {
devShells = forAllSystems (system: pkgs: toolchain: {
@@ -74,6 +76,8 @@
version = cargoToml.package.version;
inherit src;
env.CARGO_HOME = "/tmp/cargo-home";
strictDeps = true;
doCheck = false;
@@ -91,6 +95,8 @@
strictDeps = true;
doCheck = false;
env.CARGO_HOME = "/tmp/cargo-home";
postPatch = ''
'${lib.getExe pkgs.yq-go}' '.lib.crate-type = [ "staticlib" ]' --inplace Cargo.toml
'';
@@ -117,6 +123,8 @@
inherit src;
strictDeps = true;
env.CARGO_HOME = "/tmp/cargo-home";
buildInputs = with pkgs; [
sqlite
];