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