Skip to content

Instantly share code, notes, and snippets.

@kolloch
Created January 4, 2024 10:17
Show Gist options
  • Save kolloch/87c8432777fec68267aa663e6e4ca076 to your computer and use it in GitHub Desktop.
Save kolloch/87c8432777fec68267aa663e6e4ca076 to your computer and use it in GitHub Desktop.
error:
… while calling the 'derivationStrict' builtin
at /builtin/derivation.nix:9:12: (source not available)
… while evaluating derivation 'empty_cross_buildTest'
whose name attribute is located at /nix/store/m707dys0ykz12vnyfljx62dc6lv0hmx7-source/pkgs/stdenv/generic/make-derivation.nix:348:7
… while evaluating attribute 'buildInputs' of derivation 'empty_cross_buildTest'
at /nix/store/m707dys0ykz12vnyfljx62dc6lv0hmx7-source/pkgs/stdenv/generic/make-derivation.nix:395:7:
394| depsHostHost = elemAt (elemAt dependencies 1) 0;
395| buildInputs = elemAt (elemAt dependencies 1) 1;
| ^
396| depsTargetTarget = elemAt (elemAt dependencies 2) 0;
… while calling 'getOutput'
at /nix/store/m707dys0ykz12vnyfljx62dc6lv0hmx7-source/lib/attrsets.nix:1083:23:
1082| */
1083| getOutput = output: pkg:
| ^
1084| if ! pkg ? outputSpecified || ! pkg.outputSpecified
… while calling anonymous lambda
at /nix/store/m707dys0ykz12vnyfljx62dc6lv0hmx7-source/pkgs/stdenv/generic/make-derivation.nix:294:13:
293| (map (drv: drv.__spliced.hostHost or drv) (checkDependencyList "depsHostHost" depsHostHost))
294| (map (drv: drv.__spliced.hostTarget or drv) (checkDependencyList "buildInputs" buildInputs'))
| ^
295| ]
… while calling anonymous lambda
at /nix/store/m707dys0ykz12vnyfljx62dc6lv0hmx7-source/lib/lists.nix:165:29:
164| */
165| imap1 = f: list: genList (n: f (n + 1) (elemAt list n)) (length list);
| ^
166|
… from call site
at /nix/store/m707dys0ykz12vnyfljx62dc6lv0hmx7-source/lib/lists.nix:165:32:
164| */
165| imap1 = f: list: genList (n: f (n + 1) (elemAt list n)) (length list);
| ^
166|
… while calling anonymous lambda
at /nix/store/m707dys0ykz12vnyfljx62dc6lv0hmx7-source/pkgs/stdenv/generic/make-derivation.nix:261:73:
260| checkDependencyList = checkDependencyList' [];
261| checkDependencyList' = positions: name: deps: flip imap1 deps (index: dep:
| ^
262| if isDerivation dep || dep == null || builtins.isString dep || builtins.isPath dep then dep
… from call site
at /nix/store/m707dys0ykz12vnyfljx62dc6lv0hmx7-source/pkgs/stdenv/generic/make-derivation.nix:262:8:
261| checkDependencyList' = positions: name: deps: flip imap1 deps (index: dep:
262| if isDerivation dep || dep == null || builtins.isString dep || builtins.isPath dep then dep
| ^
263| else if isList dep then checkDependencyList' ([index] ++ positions) name dep
… while calling 'isDerivation'
at /nix/store/m707dys0ykz12vnyfljx62dc6lv0hmx7-source/lib/attrsets.nix:780:5:
779| # Value to check.
780| value: value.type or null == "derivation";
| ^
781|
… from call site
at /Users/peterkolloch/projects/crate2nix/tests.nix:78:11:
77| else
78| buildTestPkgs.callPackage (./. + "/${customBuild}") {
| ^
79| inherit generatedCargoNix;
… while calling 'callPackageWith'
at /nix/store/m707dys0ykz12vnyfljx62dc6lv0hmx7-source/lib/customisation.nix:153:35:
152| */
153| callPackageWith = autoArgs: fn: args:
| ^
154| let
… from call site
at /nix/store/m707dys0ykz12vnyfljx62dc6lv0hmx7-source/lib/trivial.nix:440:7:
439| { # TODO: Should we add call-time "type" checking like built in?
440| __functor = self: f;
| ^
441| __functionArgs = args;
… while calling anonymous lambda
at /nix/store/m707dys0ykz12vnyfljx62dc6lv0hmx7-source/lib/customisation.nix:96:17:
95| in
96| mirrorArgs (origArgs:
| ^
97| let
… from call site
at /nix/store/m707dys0ykz12vnyfljx62dc6lv0hmx7-source/lib/customisation.nix:98:16:
97| let
98| result = f origArgs;
| ^
99|
… while calling anonymous lambda
at /Users/peterkolloch/projects/crate2nix/sample_projects/empty_cross/default.nix:1:1:
1| { pkgs ? import ../../nix/nixpkgs.nix { config = { }; }
| ^
2| , generatedCargoNix ? ./Cargo.nix { }
… from call site
at /nix/store/547c3q0gk9kqkj88lpdzkk0zj1vk72vh-buildTest_test_empty_cross-crate2nix/crate/Cargo-generated.nix:38:13:
37| # You can override the features with rootCrate.build.override { features = [ "default" "feature1" ... ]; }.
38| build = internal.buildRustCrateWithFeatures {
| ^
39| inherit packageId;
… while calling 'buildRustCrateWithFeatures'
at /nix/store/547c3q0gk9kqkj88lpdzkk0zj1vk72vh-buildTest_test_empty_cross-crate2nix/crate/Cargo-generated.nix:259:5:
258| buildRustCrateWithFeatures =
259| { packageId
| ^
260| , features ? rootFeatures
… from call site
at /nix/store/m707dys0ykz12vnyfljx62dc6lv0hmx7-source/lib/trivial.nix:440:7:
439| { # TODO: Should we add call-time "type" checking like built in?
440| __functor = self: f;
| ^
441| __functionArgs = args;
… while calling anonymous lambda
at /nix/store/m707dys0ykz12vnyfljx62dc6lv0hmx7-source/lib/customisation.nix:96:17:
95| in
96| mirrorArgs (origArgs:
| ^
97| let
… from call site
at /nix/store/m707dys0ykz12vnyfljx62dc6lv0hmx7-source/lib/customisation.nix:98:16:
97| let
98| result = f origArgs;
| ^
99|
… while calling anonymous lambda
at /nix/store/547c3q0gk9kqkj88lpdzkk0zj1vk72vh-buildTest_test_empty_cross-crate2nix/crate/Cargo-generated.nix:273:9:
272| (
273| { features
| ^
274| , crateOverrides
… while calling anonymous lambda
at /nix/store/547c3q0gk9kqkj88lpdzkk0zj1vk72vh-buildTest_test_empty_cross-crate2nix/crate/Cargo-generated.nix:350:49:
349| self = {
350| crates = lib.mapAttrs (packageId: value: buildByPackageIdForPkgsImpl self pkgs packageId) crateConfigs;
| ^
351| target = makeTarget pkgs.stdenv.hostPlatform;
… from call site
at /nix/store/547c3q0gk9kqkj88lpdzkk0zj1vk72vh-buildTest_test_empty_cross-crate2nix/crate/Cargo-generated.nix:350:56:
349| self = {
350| crates = lib.mapAttrs (packageId: value: buildByPackageIdForPkgsImpl self pkgs packageId) crateConfigs;
| ^
351| target = makeTarget pkgs.stdenv.hostPlatform;
… while calling 'buildByPackageIdForPkgsImpl'
at /nix/store/547c3q0gk9kqkj88lpdzkk0zj1vk72vh-buildTest_test_empty_cross-crate2nix/crate/Cargo-generated.nix:356:51:
355| self;
356| buildByPackageIdForPkgsImpl = self: pkgs: packageId:
| ^
357| let
… from call site
at /nix/store/547c3q0gk9kqkj88lpdzkk0zj1vk72vh-buildTest_test_empty_cross-crate2nix/crate/Cargo-generated.nix:423:11:
422| in
423| buildRustCrateForPkgsFunc pkgs
| ^
424| (
… while calling anonymous lambda
at /Users/peterkolloch/projects/crate2nix/sample_projects/empty_cross/default.nix:43:7:
42| in
43| args: fun (args // lib.optionalAttrs isBareMetal {
| ^
44| RUSTC_BOOTSTRAP = true;
… from call site
at /nix/store/m707dys0ykz12vnyfljx62dc6lv0hmx7-source/lib/trivial.nix:440:7:
439| { # TODO: Should we add call-time "type" checking like built in?
440| __functor = self: f;
| ^
441| __functionArgs = args;
… while calling anonymous lambda
at /nix/store/m707dys0ykz12vnyfljx62dc6lv0hmx7-source/lib/customisation.nix:104:34:
103| # Re-call the function but with different arguments
104| overrideArgs = mirrorArgs (newArgs: makeOverridable f (overrideWith newArgs));
| ^
105| # Change the result of the function call by applying g to it
… from call site
at /nix/store/m707dys0ykz12vnyfljx62dc6lv0hmx7-source/lib/trivial.nix:440:7:
439| { # TODO: Should we add call-time "type" checking like built in?
440| __functor = self: f;
| ^
441| __functionArgs = args;
… while calling anonymous lambda
at /nix/store/m707dys0ykz12vnyfljx62dc6lv0hmx7-source/lib/customisation.nix:96:17:
95| in
96| mirrorArgs (origArgs:
| ^
97| let
error: function 'anonymous lambda' called with unexpected argument 'rust'
at /nix/store/m707dys0ykz12vnyfljx62dc6lv0hmx7-source/pkgs/build-support/rust/build-rust-crate/default.nix:7:1:
6|
7| { lib
| ^
8| , stdenv
Did you mean rustc?
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment