nixpkgs/pkgs/development/libraries/vulkan-loader/default.nix

39 lines
1.1 KiB
Nix
Raw Normal View History

2018-06-27 03:35:34 +00:00
{ stdenv, fetchFromGitHub, cmake, python3, vulkan-headers, pkgconfig,
xlibsWrapper, libxcb, libXrandr, libXext, wayland, libGL_driver }:
let version = "1.1.85"; in
2018-06-27 03:35:34 +00:00
assert version == vulkan-headers.version;
stdenv.mkDerivation rec {
name = "vulkan-loader-${version}";
inherit version;
2016-04-02 19:35:14 +00:00
src = fetchFromGitHub {
owner = "KhronosGroup";
2018-06-27 03:35:34 +00:00
repo = "Vulkan-Loader";
rev = "sdk-${version}";
2018-08-17 06:05:04 +00:00
sha256 = "16i4s1adfh822ahj3ywp279lv6szwd2sn2q5pmvpg2kk6mbh410d";
2016-04-02 19:35:14 +00:00
};
2018-06-27 03:35:34 +00:00
nativeBuildInputs = [ pkgconfig ];
buildInputs = [ cmake python3 xlibsWrapper libxcb libXrandr libXext wayland ];
enableParallelBuilding = true;
2016-04-02 19:35:14 +00:00
2016-08-31 20:57:37 +00:00
cmakeFlags = [
"-DFALLBACK_DATA_DIRS=${libGL_driver.driverLink}/share:/usr/local/share:/usr/share"
2018-06-27 03:35:34 +00:00
"-DVULKAN_HEADERS_INSTALL_DIR=${vulkan-headers}"
2016-08-31 20:57:37 +00:00
];
2018-06-27 03:35:34 +00:00
outputs = [ "out" "dev" ];
2018-06-27 03:35:34 +00:00
postInstall = ''
cp -r "${vulkan-headers}/include" "$dev"
2017-03-27 02:28:30 +00:00
'';
2016-04-02 19:35:14 +00:00
meta = with stdenv.lib; {
description = "LunarG Vulkan loader";
2018-06-27 20:12:57 +00:00
homepage = https://www.lunarg.com;
2016-04-02 19:35:14 +00:00
platforms = platforms.linux;
license = licenses.asl20;
2017-04-01 19:28:59 +00:00
maintainers = [ maintainers.ralith ];
2016-04-02 19:35:14 +00:00
};
}