forked from mirrors/nixpkgs
zenith: use buildFeatures
This commit is contained in:
parent
08e50b55cb
commit
59a143e206
|
@ -18,12 +18,13 @@ rustPlatform.buildRustPackage rec {
|
||||||
sha256 = "1bn364rmp0q86rd7vgv4n7x09cdf9m4njcaq92jnk85ni6h147ax";
|
sha256 = "1bn364rmp0q86rd7vgv4n7x09cdf9m4njcaq92jnk85ni6h147ax";
|
||||||
};
|
};
|
||||||
|
|
||||||
cargoBuildFlags = lib.optionals nvidiaSupport [ "--features" "nvidia" ];
|
|
||||||
cargoSha256 = "0c2mk2bcz4qjyqmf11yqhnhy4pqxr77b3c1gvr5jfmjshx4ff7v2";
|
cargoSha256 = "0c2mk2bcz4qjyqmf11yqhnhy4pqxr77b3c1gvr5jfmjshx4ff7v2";
|
||||||
|
|
||||||
nativeBuildInputs = lib.optional nvidiaSupport makeWrapper;
|
nativeBuildInputs = lib.optional nvidiaSupport makeWrapper;
|
||||||
buildInputs = lib.optionals stdenv.isDarwin [ IOKit ];
|
buildInputs = lib.optionals stdenv.isDarwin [ IOKit ];
|
||||||
|
|
||||||
|
buildFeatures = lib.optional nvidiaSupport "nvidia";
|
||||||
|
|
||||||
postInstall = lib.optionalString nvidiaSupport ''
|
postInstall = lib.optionalString nvidiaSupport ''
|
||||||
wrapProgram $out/bin/zenith \
|
wrapProgram $out/bin/zenith \
|
||||||
--suffix LD_LIBRARY_PATH : "/run/opengl-driver/lib"
|
--suffix LD_LIBRARY_PATH : "/run/opengl-driver/lib"
|
||||||
|
|
Loading…
Reference in a new issue