File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1313 nixpkgs ,
1414 crane ,
1515 flake-utils ,
16+ lib ,
1617 ...
1718 } :
1819 flake-utils . lib . eachDefaultSystem (
2324 libPath = with pkgs ; lib . makeLibraryPath [ wayland vulkan-loader ] ;
2425
2526 commonArgs = {
26- src = craneLib . cleanCargoSource ./. ;
27+ src = lib . fileset . toSource {
28+ root = ./. ;
29+ fileset = lib . fileset . unions [
30+ ( craneLib . fileset . commonCargoSources ./. )
31+ ( lib . fileset . maybeMissing ./assets )
32+ ] ;
33+ } ;
2734 strictDeps = true ;
2835
2936 buildInputs = with pkgs ; [ makeWrapper libxkbcommon ] ;
3037 } ;
3138
32- waystart = craneLib . buildPackage (
33- commonArgs
34- // {
35- cargoArtifacts = craneLib . buildDepsOnly commonArgs ;
39+ cargoArtifacts = craneLib . buildDepsOnly ( commonArgs // {
40+ pname = "waystart-deps" ;
41+ } ) ;
42+
43+ waystartClippy = craneLib . cargoClippy ( commonArgs // {
44+ inherit cargoArtifacts ;
45+ cargoClippyExtraArgs = "--all-targets -- --deny warnings" ;
46+ } ) ;
47+
48+ waystart = craneLib . buildPackage ( commonArgs // {
49+ inherit cargoArtifacts ;
3650 postInstall = ''
3751 wrapProgram "$out/bin/waystart" --prefix LD_LIBRARY_PATH : "${ libPath } "
3852 '' ;
3953 }
4054 ) ;
4155 in
4256 {
43- checks = { inherit waystart ; } ;
57+ checks = { inherit waystart waystartClippy ; } ;
4458 packages . default = waystart ;
4559 apps . default = flake-utils . lib . mkApp {
4660 drv = waystart ;
You can’t perform that action at this time.
0 commit comments