depot/third_party/nixpkgs/pkgs/development/libraries/libva/default.nix
Default email 8ac5e011d6 Project import generated by Copybara.
GitOrigin-RevId: 2c3273caa153ee8eb5786bc8141b85b859e7efd7
2020-04-24 19:36:52 -04:00

47 lines
1.4 KiB
Nix

{ stdenv, lib, fetchFromGitHub, autoreconfHook, pkgconfig
, libXext, libdrm, libXfixes, wayland, libffi, libX11
, libGL, mesa
, minimal ? false, libva-minimal
, buildPackages
}:
stdenv.mkDerivation rec {
name = "libva-${lib.optionalString minimal "minimal-"}${version}";
version = "2.6.1";
# update libva-utils and vaapiIntel as well
src = fetchFromGitHub {
owner = "01org";
repo = "libva";
rev = version;
sha256 = "1x34kf38p5rf52bf54ljr9f7knnbilm7kbszqnfk3lzsqrfc7r2g";
};
outputs = [ "dev" "out" ];
nativeBuildInputs = [ autoreconfHook pkgconfig wayland ];
buildInputs = [ libdrm ]
++ lib.optionals (!minimal) [ libva-minimal libX11 libXext libXfixes wayland libffi libGL ];
# TODO: share libs between minimal and !minimal - perhaps just symlink them
enableParallelBuilding = true;
configureFlags = [
# Add FHS paths for non-NixOS applications.
"--with-drivers-path=${mesa.drivers.driverLink}/lib/dri:/usr/lib/dri:/usr/lib32/dri"
"ac_cv_path_WAYLAND_SCANNER=${buildPackages.wayland}/bin/wayland-scanner"
] ++ lib.optionals (!minimal) [ "--enable-glx" ];
installFlags = [
"dummy_drv_video_ladir=$(out)/lib/dri"
];
meta = with stdenv.lib; {
description = "VAAPI library: Video Acceleration API";
homepage = "http://www.freedesktop.org/wiki/Software/vaapi";
license = licenses.mit;
maintainers = with maintainers; [ ];
platforms = platforms.unix;
};
}