Loading pkgs/by-name/sh/shader-slang/package.nix +26 −3 Original line number Diff line number Diff line Loading @@ -13,6 +13,7 @@ unordered_dense, versionCheckHook, gitUpdater, runCommandCC, # Required for compiling to SPIR-V or GLSL withGlslang ? true, Loading Loading @@ -119,10 +120,32 @@ stdenv.mkDerivation (finalAttrs: { versionCheckProgramArg = "-v"; doInstallCheck = true; passthru.updateScript = gitUpdater { passthru = { updateScript = gitUpdater { rev-prefix = "v"; ignoredVersions = "*-draft"; }; tests.hello = runCommandCC "compile-hello-world" { # Intermediate files generated by slangc trigger this warning NIX_CFLAGS_COMPILE = "-Wno-error=format-security"; } '' cat > hello.slang << EOF export __extern_cpp int main() { printf("Hello, world!\n"); return 0; } EOF ${lib.getExe finalAttrs.finalPackage} hello.slang -target executable -o hello ./hello | grep "Hello, world!" touch $out ''; }; meta = { description = "Shading language that makes it easier to build and maintain large shader codebases in a modular and extensible fashion"; Loading Loading
pkgs/by-name/sh/shader-slang/package.nix +26 −3 Original line number Diff line number Diff line Loading @@ -13,6 +13,7 @@ unordered_dense, versionCheckHook, gitUpdater, runCommandCC, # Required for compiling to SPIR-V or GLSL withGlslang ? true, Loading Loading @@ -119,10 +120,32 @@ stdenv.mkDerivation (finalAttrs: { versionCheckProgramArg = "-v"; doInstallCheck = true; passthru.updateScript = gitUpdater { passthru = { updateScript = gitUpdater { rev-prefix = "v"; ignoredVersions = "*-draft"; }; tests.hello = runCommandCC "compile-hello-world" { # Intermediate files generated by slangc trigger this warning NIX_CFLAGS_COMPILE = "-Wno-error=format-security"; } '' cat > hello.slang << EOF export __extern_cpp int main() { printf("Hello, world!\n"); return 0; } EOF ${lib.getExe finalAttrs.finalPackage} hello.slang -target executable -o hello ./hello | grep "Hello, world!" touch $out ''; }; meta = { description = "Shading language that makes it easier to build and maintain large shader codebases in a modular and extensible fashion"; Loading