mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-17 15:22:59 +01:00
Merge pull request #66358 from Ralith/openxr-loader
openxr-loader: init at 1.0.1
This commit is contained in:
commit
6f27f6c494
2 changed files with 42 additions and 0 deletions
40
pkgs/development/libraries/openxr-loader/default.nix
Normal file
40
pkgs/development/libraries/openxr-loader/default.nix
Normal file
|
@ -0,0 +1,40 @@
|
|||
{ stdenv, fetchFromGitHub, cmake, python3, libX11, libXxf86vm, libXrandr }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "openxr-loader";
|
||||
version = "1.0.1";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "KhronosGroup";
|
||||
repo = "OpenXR-SDK-Source";
|
||||
rev = "release-${version}";
|
||||
sha256 = "1sif2w2vm793j6493364i6pp6s6yqi7fwa6iky5abzmzda51cg5q";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ cmake python3 ];
|
||||
buildInputs = [ libX11 libXxf86vm libXrandr ];
|
||||
enableParallelBuilding = true;
|
||||
|
||||
cmakeFlags = [ "-DBUILD_TESTS=OFF" ];
|
||||
|
||||
outputs = [ "out" "dev" "layers" ];
|
||||
|
||||
postInstall = ''
|
||||
mkdir -p "$layers/share"
|
||||
mv "$out/share/openxr" "$layers/share"
|
||||
# Use absolute paths in manifests so no LD_LIBRARY_PATH shenanigans are necessary
|
||||
for file in "$layers/share/openxr/1/api_layers/explicit.d/"*; do
|
||||
substituteInPlace "$file" --replace '"library_path": "lib' "\"library_path\": \"$layers/lib/lib"
|
||||
done
|
||||
mkdir -p "$layers/lib"
|
||||
mv "$out/lib/libXrApiLayer"* "$layers/lib"
|
||||
'';
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
description = "Khronos OpenXR loader";
|
||||
homepage = https://www.khronos.org/openxr;
|
||||
platforms = platforms.linux;
|
||||
license = licenses.asl20;
|
||||
maintainers = [ maintainers.ralith ];
|
||||
};
|
||||
}
|
|
@ -14709,6 +14709,8 @@ in
|
|||
|
||||
openxpki = callPackage ../servers/openxpki { };
|
||||
|
||||
openxr-loader = callPackage ../development/libraries/openxr-loader { };
|
||||
|
||||
osrm-backend = callPackage ../servers/osrm-backend { };
|
||||
|
||||
p910nd = callPackage ../servers/p910nd { };
|
||||
|
|
Loading…
Reference in a new issue