nixpkgs/pkgs/development/libraries/vaapi-vdpau/default.nix

41 lines
2.2 KiB
Nix
Raw Normal View History

{ stdenv, fetchurl, fetchpatch, libvdpau, libGLU, libGL, libva, pkg-config }:
2019-07-26 00:20:17 +01:00
stdenv.mkDerivation rec {
2019-07-27 01:32:52 +01:00
pname = "libva-vdpau-driver";
version = "0.7.4";
src = fetchurl {
2019-07-27 01:32:52 +01:00
url = "https://www.freedesktop.org/software/vaapi/releases/${pname}/${pname}-${version}.tar.bz2";
sha256 = "1fcvgshzyc50yb8qqm6v6wn23ghimay23ci0p8sm8gxcy211jp0m";
};
2019-07-26 00:20:17 +01:00
patches = [
(fetchpatch { url = "https://src.fedoraproject.org/rpms/libva-vdpau-driver/raw/0ad71107e28a60ea453ac70e895cf64342bd58d0/f/libva-vdpau-driver-0.7.4-glext-85.patch";
sha256 = "0f0v7cl7kna3jcfnxw48b9mfl0hpacw72df9vym96sa2206vqlb0"; })
(fetchpatch { url = "https://src.fedoraproject.org/rpms/libva-vdpau-driver/raw/0ad71107e28a60ea453ac70e895cf64342bd58d0/f/libva-vdpau-driver-0.7.4-drop-h264-api.patch";
sha256 = "0q5w83jbf4qqmhwf54h906pzxgvhqv7g2vrkw7jzgnrxhhj9sj60"; })
(fetchpatch { url = "https://src.fedoraproject.org/rpms/libva-vdpau-driver/raw/0ad71107e28a60ea453ac70e895cf64342bd58d0/f/libva-vdpau-driver-0.7.4-fix_type.patch";
sha256 = "0s5dk6aa4sm0iyicnf2fwfsrqbvr58nbp77mhjg5bvwlar7znqv7"; })
(fetchpatch { url = "https://src.fedoraproject.org/rpms/libva-vdpau-driver/raw/0ad71107e28a60ea453ac70e895cf64342bd58d0/f/sigfpe-crash.patch";
sha256 = "15snqf60ib0xb3cnav5b2r55qv8lv2fa4p6jwxajh8wbvqpw0ibz"; })
(fetchpatch { url = "https://src.fedoraproject.org/rpms/libva-vdpau-driver/raw/0ad71107e28a60ea453ac70e895cf64342bd58d0/f/implement-vaquerysurfaceattributes.patch";
sha256 = "1dapx3bqqblw6l2iqqw1yff6qifam8q4m2rq343kwb3dqhy2ymy5"; })
(fetchpatch { url = "https://gitweb.gentoo.org/repo/gentoo.git/plain/x11-libs/libva-vdpau-driver/files/libva-vdpau-driver-0.7.4-include-linux-videodev2.h.patch";
sha256 = "1m4is6lk580mppsx2mvdv1xifj6gvx724si4qynsm9qrdfdc9fby"; })
];
nativeBuildInputs = [ pkg-config ];
2019-11-10 16:44:34 +00:00
buildInputs = [ libvdpau libGLU libGL libva ];
2019-07-27 01:32:52 +01:00
postPatch = ''
sed -i -e "s,LIBVA_DRIVERS_PATH=.*,LIBVA_DRIVERS_PATH=$out/lib/dri," configure
'';
2019-07-27 01:32:52 +01:00
meta = with stdenv.lib; {
2019-07-26 00:20:17 +01:00
homepage = "https://cgit.freedesktop.org/vaapi/vdpau-driver";
2019-07-27 01:32:52 +01:00
license = licenses.gpl2Plus;
description = "VDPAU driver for the VAAPI library";
2019-07-27 01:32:52 +01:00
platforms = platforms.linux;
};
}