mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-19 12:11:28 +00:00
buildRustCrateTests: add test case for rlib linking
This commit is contained in:
parent
406e0c9d51
commit
78faab1be0
|
@ -185,7 +185,20 @@ let
|
|||
"test tests_bar ... ok"
|
||||
];
|
||||
};
|
||||
|
||||
linkAgainstRlibCrate = {
|
||||
crateName = "foo";
|
||||
src = mkFile "src/main.rs" ''
|
||||
extern crate somerlib;
|
||||
fn main() {}
|
||||
'';
|
||||
dependencies = [
|
||||
(mkCrate {
|
||||
crateName = "somerlib";
|
||||
type = [ "rlib" ];
|
||||
src = mkLib "src/lib.rs";
|
||||
})
|
||||
];
|
||||
};
|
||||
};
|
||||
brotliCrates = (callPackage ./brotli-crates.nix {});
|
||||
in lib.mapAttrs (key: value: mkTest (value // lib.optionalAttrs (!value?crateName) { crateName = key; })) cases // {
|
||||
|
|
Loading…
Reference in a new issue