depot/third_party/nixpkgs/pkgs/development/libraries/egl-wayland/default.nix
Default email f34ce41345 Project import generated by Copybara.
GitOrigin-RevId: b73c2221a46c13557b1b3be9c2070cc42cf01eb3
2024-07-27 08:49:29 +02:00

65 lines
1.2 KiB
Nix

{ lib
, stdenv
, fetchFromGitHub
, eglexternalplatform
, pkg-config
, meson
, ninja
, wayland-scanner
, libGL
, libX11
, libdrm
, wayland
, wayland-protocols
}:
stdenv.mkDerivation rec {
pname = "egl-wayland";
version = "1.1.14";
outputs = [ "out" "dev" ];
src = fetchFromGitHub {
owner = "Nvidia";
repo = pname;
rev = version;
hash = "sha256-MD+D/dRem3ONWGPoZ77j2UKcOCUuQ0nrahEQkNVEUnI=";
};
postPatch = ''
# Declares an includedir but doesn't install any headers
# CMake's `pkg_check_modules(NAME wayland-eglstream IMPORTED_TARGET)` considers this an error
sed -i -e '/includedir/d' wayland-eglstream.pc.in
'';
depsBuildBuild = [
pkg-config
];
nativeBuildInputs = [
meson
ninja
pkg-config
wayland-scanner
];
buildInputs = [
libGL
libX11
libdrm
wayland
wayland-protocols
];
propagatedBuildInputs = [
eglexternalplatform
];
meta = with lib; {
description = "EGLStream-based Wayland external platform";
homepage = "https://github.com/NVIDIA/egl-wayland/";
license = licenses.mit;
platforms = platforms.linux;
maintainers = with maintainers; [ hedning ];
};
}