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