don't use file type flake inputs

Because they aren't supported by flake-compat and can't be without IFD.
This commit is contained in:
Charles Hall 2025-03-02 11:12:38 -08:00
parent 114e7ba577
commit adb174d985
No known key found for this signature in database
GPG key ID: 7B8E0645816E07CF
2 changed files with 9 additions and 22 deletions

15
flake.lock generated
View file

@ -267,8 +267,7 @@
"flake-utils": "flake-utils",
"nix-filter": "nix-filter",
"nixpkgs": "nixpkgs_2",
"rocksdb": "rocksdb",
"rust-manifest": "rust-manifest"
"rocksdb": "rocksdb"
}
},
"rust-analyzer-src": {
@ -288,18 +287,6 @@
"type": "github"
}
},
"rust-manifest": {
"flake": false,
"locked": {
"narHash": "sha256-dm4qOlaZ/uZ+O2TmOrWEjjMAzZNWAGE8S0ne79Fo8OA=",
"type": "file",
"url": "https://static.rust-lang.org/dist/channel-rust-1.84.0.toml"
},
"original": {
"type": "file",
"url": "https://static.rust-lang.org/dist/channel-rust-1.84.0.toml"
}
},
"systems": {
"locked": {
"lastModified": 1681028828,

View file

@ -9,16 +9,16 @@
nix-filter.url = "github:numtide/nix-filter?ref=main";
nixpkgs.url = "github:NixOS/nixpkgs?ref=nixos-unstable";
rocksdb = { url = "github:facebook/rocksdb?ref=v9.7.4"; flake = false; };
rust-manifest = {
# Keep version in sync with rust-toolchain.toml
url = "https://static.rust-lang.org/dist/channel-rust-1.84.0.toml";
flake = false;
};
};
outputs = inputs:
let
rust-manifest = builtins.fetchurl {
# Keep version in sync with rust-toolchain.toml
url = "https://static.rust-lang.org/dist/channel-rust-1.84.0.toml";
sha256 = "sha256-lMLAupxng4Fd9F1oDw8gx+qA0RuF7ou7xhNU8wgs0PU=";
};
# Keep sorted
mkScope = pkgs: pkgs.lib.makeScope pkgs.newScope (self: {
craneLib =
@ -60,11 +60,11 @@
targets = toolchainFile.toolchain.targets;
fenix = inputs.fenix.packages.${pkgs.stdenv.buildPlatform.system};
nativeToolchain = (fenix.fromManifestFile inputs.rust-manifest)
nativeToolchain = (fenix.fromManifestFile rust-manifest)
.withComponents components;
crossComponents = builtins.map
(target:
(fenix.targets.${target}.fromManifestFile inputs.rust-manifest)
(fenix.targets.${target}.fromManifestFile rust-manifest)
.rust-std)
targets;
in