forked from mirrors/nixpkgs
shaderc: fix glslc on aarch64-darwin
This commit is contained in:
parent
b286501a5e
commit
fe3b7c5e9d
|
@ -1,4 +1,4 @@
|
|||
{ lib, stdenv, fetchFromGitHub, cmake, darwin, python3 }:
|
||||
{ lib, stdenv, fetchFromGitHub, cmake, python3, autoSignDarwinBinariesHook, cctools }:
|
||||
# Like many google projects, shaderc doesn't gracefully support separately compiled dependencies, so we can't easily use
|
||||
# the versions of glslang and spirv-tools used by vulkan-loader. Exact revisions are taken from
|
||||
# https://github.com/google/shaderc/blob/known-good/known_good.json
|
||||
|
@ -23,7 +23,8 @@ let
|
|||
rev = "0c28b6451d77774912e52949c1e57fa726edf113";
|
||||
sha256 = "sha256-KpCMceTV/BRaoJe1qeXhKYQNQqdGaM6Q9nklpJKzHFY=";
|
||||
};
|
||||
in stdenv.mkDerivation rec {
|
||||
in
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "shaderc";
|
||||
version = "2021.0";
|
||||
|
||||
|
@ -42,7 +43,9 @@ in stdenv.mkDerivation rec {
|
|||
ln -s ${spirv-headers} third_party/spirv-tools/external/spirv-headers
|
||||
'';
|
||||
|
||||
nativeBuildInputs = [ cmake python3 ] ++ lib.optionals stdenv.isDarwin [ darwin.cctools ];
|
||||
nativeBuildInputs = [ cmake python3 ]
|
||||
++ lib.optionals stdenv.isDarwin [ cctools ]
|
||||
++ lib.optionals (stdenv.isDarwin && stdenv.isAarch64) [ autoSignDarwinBinariesHook ];
|
||||
|
||||
postInstall = ''
|
||||
moveToOutput "lib/*.a" $static
|
||||
|
|
|
@ -26453,7 +26453,9 @@ with pkgs;
|
|||
|
||||
session-desktop = callPackage ../applications/networking/instant-messengers/session-desktop { };
|
||||
|
||||
shaderc = callPackage ../development/compilers/shaderc { };
|
||||
shaderc = callPackage ../development/compilers/shaderc {
|
||||
inherit (darwin) autoSignDarwinBinariesHook cctools;
|
||||
};
|
||||
|
||||
shades-of-gray-theme = callPackage ../data/themes/shades-of-gray { };
|
||||
|
||||
|
|
Loading…
Reference in a new issue