depot/third_party/nixpkgs/pkgs/development/libraries/spirv-headers/default.nix
Default email 4d5a95770c Project import generated by Copybara.
GitOrigin-RevId: 3c5319ad3aa51551182ac82ea17ab1c6b0f0df89
2023-03-04 15:14:45 +03:00

28 lines
795 B
Nix

{ lib, stdenv, fetchFromGitHub, cmake }:
stdenv.mkDerivation rec {
pname = "spirv-headers";
version = "1.3.239.0";
src = fetchFromGitHub {
owner = "KhronosGroup";
repo = "SPIRV-Headers";
rev = "sdk-${version}";
hash = "sha256-bjiWGSmpEbydXtCLP8fRZfPBvdCzBoJxKXTx3BroQbg=";
};
nativeBuildInputs = [ cmake ];
# https://github.com/KhronosGroup/SPIRV-Headers/issues/282
postPatch = ''
substituteInPlace SPIRV-Headers.pc.in \
--replace '$'{prefix}/@CMAKE_INSTALL_INCLUDEDIR@ @CMAKE_INSTALL_FULL_INCLUDEDIR@
'';
meta = with lib; {
description = "Machine-readable components of the Khronos SPIR-V Registry";
homepage = "https://github.com/KhronosGroup/SPIRV-Headers";
license = licenses.mit;
maintainers = [ maintainers.ralith ];
};
}