I think I did the move right, but please do doublecheck it :-) - Move wayland to build_gl. - Drop vaapi-dummy-driver Recommends, package does not exist anymore. - Move wayland to build_gl. - Drop vaapi-dummy-driver Recommends, package does not exist anymore. OBS-URL: https://build.opensuse.org/request/show/518926 OBS-URL: https://build.opensuse.org/package/show/X11:XOrg/libva?expand=0&rev=94
304 lines
8.1 KiB
RPMSpec
304 lines
8.1 KiB
RPMSpec
#
|
|
# spec file for package libva
|
|
#
|
|
# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
|
|
#
|
|
# All modifications and additions to the file contributed by third parties
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
# upon. The license for this file, and modifications and additions to the
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
# license for the pristine package is not an Open Source License, in which
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
# published by the Open Source Initiative.
|
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
#
|
|
|
|
|
|
#
|
|
|
|
%if 0%{?suse_version} <= 1315 && !0%{?is_opensuse}
|
|
%bcond_with wayland
|
|
%else
|
|
%bcond_without wayland
|
|
%endif
|
|
|
|
%define build_gl 0
|
|
|
|
Name: libva
|
|
%define _name libva
|
|
Version: 1.8.3
|
|
Release: 0
|
|
Summary: Video Acceleration (VA) API for Linux
|
|
License: MIT
|
|
Group: System/Libraries
|
|
Url: http://freedesktop.org/wiki/Software/vaapi
|
|
Source0: https://github.com/01org/libva/releases/download/%{version}/%{_name}-%{version}.tar.bz2
|
|
Source1: https://github.com/01org/libva/releases/download/%{version}/%{_name}-%{version}.tar.bz2.sha1sum
|
|
Source2: baselibs.conf
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
|
BuildRequires: gcc-c++
|
|
BuildRequires: libtool
|
|
BuildRequires: pkg-config
|
|
BuildRequires: xz
|
|
BuildRequires: pkgconfig(libdrm)
|
|
BuildRequires: pkgconfig(libudev)
|
|
BuildRequires: pkgconfig(x11)
|
|
BuildRequires: pkgconfig(xext)
|
|
BuildRequires: pkgconfig(xfixes)
|
|
BuildRequires: pkgconfig(xrandr)
|
|
BuildRequires: pkgconfig(xv)
|
|
%if %{build_gl}
|
|
BuildRequires: pkgconfig(egl)
|
|
BuildRequires: pkgconfig(gl)
|
|
%if %{with wayland}
|
|
BuildRequires: pkgconfig(wayland-client) >= 1.0.0
|
|
BuildRequires: pkgconfig(wayland-scanner) >= 1.0.0
|
|
%endif
|
|
%endif
|
|
|
|
%description
|
|
The libva library implements the Video Acceleration (VA) API for Linux.
|
|
The library loads a hardware dependendent driver.
|
|
|
|
%if %{build_gl}
|
|
%package -n libva-egl1
|
|
Summary: Video Acceleration (VA) API for Linux -- VA/EGL Backend
|
|
Group: System/Libraries
|
|
Supplements: libva1
|
|
|
|
%description -n libva-egl1
|
|
The libva library implements the Video Acceleration (VA) API for Linux.
|
|
The library loads a hardware dependendent driver.
|
|
|
|
This is the VA/EGL runtime library
|
|
|
|
%package -n libva-glx1
|
|
Summary: Video Acceleration (VA) API for Linux -- VA/GLX Backend
|
|
Group: System/Libraries
|
|
Supplements: libva1
|
|
|
|
%description -n libva-glx1
|
|
The libva library implements the Video Acceleration (VA) API for Linux.
|
|
The library loads a hardware dependendent driver.
|
|
|
|
This is the VA/GLX runtime library
|
|
|
|
%if %{with wayland}
|
|
%package -n libva-wayland1
|
|
Summary: Video Acceleration (VA) API for Linux -- Wayland support
|
|
Group: System/Libraries
|
|
|
|
%description -n libva-wayland1
|
|
The libva library implements the Video Acceleration (VA) API for Linux.
|
|
The library loads a hardware dependendent driver.
|
|
%endif
|
|
|
|
%if %{with wayland}
|
|
%package -n vaapi-wayland-tools
|
|
Summary: Video Acceleration (VA) API for Linux - Wayland support
|
|
Group: System/Libraries
|
|
|
|
%description -n vaapi-wayland-tools
|
|
The libva library implements the Video Acceleration (VA) API for Linux.
|
|
The library loads a hardware dependendent driver.
|
|
%endif
|
|
|
|
%package devel
|
|
Summary: Video Acceleration (VA) API for Linux -- gl development files
|
|
Group: Development/Languages/C and C++
|
|
BuildRequires: libva-devel = %{version}
|
|
Requires: libva-egl1 = %{version}
|
|
Requires: libva-glx1 = %{version}
|
|
%if %{with wayland}
|
|
Requires: libva-wayland1 = %{version}
|
|
%endif
|
|
Requires: pkgconfig(egl)
|
|
Requires: pkgconfig(gl)
|
|
|
|
%description devel
|
|
The libva library implements the Video Acceleration (VA) API for Linux.
|
|
The library loads a hardware dependendent driver.
|
|
|
|
This package provides the development environment for libva gl packages.
|
|
%else #build_gl
|
|
|
|
%package -n libva1
|
|
Summary: Video Acceleration (VA) API for Linux
|
|
Group: System/Libraries
|
|
|
|
%description -n libva1
|
|
The libva library implements the Video Acceleration (VA) API for Linux.
|
|
The library loads a hardware dependendent driver.
|
|
|
|
This is the core runtime library
|
|
|
|
%package -n libva-drm1
|
|
Summary: Video Acceleration (VA) API for Linux -- VA/DRM Backend
|
|
Group: System/Libraries
|
|
Supplements: libva1
|
|
|
|
%description -n libva-drm1
|
|
The libva library implements the Video Acceleration (VA) API for Linux.
|
|
The library loads a hardware dependendent driver.
|
|
|
|
This is the VA/DRM runtime library
|
|
|
|
%package -n libva-x11-1
|
|
Summary: Video Acceleration (VA) API for Linux -- VA/X11 Backend
|
|
Group: System/Libraries
|
|
Supplements: libva1
|
|
|
|
%description -n libva-x11-1
|
|
The libva library implements the Video Acceleration (VA) API for Linux.
|
|
The library loads a hardware dependendent driver.
|
|
|
|
This is the VA/X11 runtime library
|
|
|
|
%package devel
|
|
Summary: Video Acceleration (VA) API for Linux -- development files
|
|
Group: Development/Languages/C and C++
|
|
Requires: libva-drm1 = %{version}
|
|
Requires: libva-x11-1 = %{version}
|
|
Requires: libva1 = %{version}
|
|
Requires: pkgconfig(libdrm)
|
|
Requires: pkgconfig(x11)
|
|
Requires: pkgconfig(xfixes)
|
|
Recommends: libva-gl-devel
|
|
|
|
%description devel
|
|
The libva library implements the Video Acceleration (VA) API for Linux.
|
|
The library loads a hardware dependendent driver.
|
|
|
|
This package provides the development environment for libva.
|
|
|
|
%endif #build_gl
|
|
|
|
%prep
|
|
%setup -q -n %{_name}-%{version}
|
|
# Add "libva-wayland1" to baselibs.conf when enabling wayland build;
|
|
# ugly I know ...This is needed since otherwise source validator
|
|
#
|
|
# osc service run source_validator
|
|
#
|
|
# fails on sle
|
|
%if %{with wayland}
|
|
echo libva-wayland1 >> $RPM_SOURCE_DIR/baselibs.conf
|
|
%endif
|
|
|
|
%build
|
|
[ -d m4 ] || mkdir m4
|
|
autoreconf -v --install
|
|
%configure \
|
|
%if %{build_gl}
|
|
--enable-glx \
|
|
--enable-egl \
|
|
--disable-wayland \
|
|
%if %{with wayland}
|
|
--enable-wayland \
|
|
%else
|
|
--disable-wayland \
|
|
%endif
|
|
%endif
|
|
--with-drivers-path=%{_libdir}/dri
|
|
make %{?_smp_mflags}
|
|
|
|
%install
|
|
%makeinstall
|
|
find %{buildroot} -name '*.la' -delete -print
|
|
|
|
%if %{build_gl}
|
|
# remove all files packaged during without gl mode
|
|
%{__rm} -rf %{buildroot}%{_bindir}/{avcenc,h264encode,jpegenc,loadjpeg,mpeg2vaenc,mpeg2vldemo,putsurface,vainfo}
|
|
%{__rm} -rf `find %{buildroot}%{_includedir}/va/* | grep -v "egl\|glx\|wayland"`
|
|
%{__rm} -rf `find %{buildroot}%{_libdir}/libva* | grep -v "egl\|glx\|wayland"`
|
|
%{__rm} -rf `find %{buildroot}%{_libdir}/pkgconfig/libva*.pc | grep -v "egl\|glx\|wayland"`
|
|
%endif
|
|
|
|
%if %{build_gl}
|
|
%post -n libva-egl1 -p /sbin/ldconfig
|
|
|
|
%postun -n libva-egl1 -p /sbin/ldconfig
|
|
|
|
%post -n libva-glx1 -p /sbin/ldconfig
|
|
|
|
%postun -n libva-glx1 -p /sbin/ldconfig
|
|
|
|
%if %{with wayland}
|
|
%post -n libva-wayland1 -p /sbin/ldconfig
|
|
|
|
%postun -n libva-wayland1 -p /sbin/ldconfig
|
|
%endif
|
|
|
|
%else
|
|
|
|
%post -n libva1 -p /sbin/ldconfig
|
|
|
|
%postun -n libva1 -p /sbin/ldconfig
|
|
|
|
%post -n libva-drm1 -p /sbin/ldconfig
|
|
|
|
%postun -n libva-drm1 -p /sbin/ldconfig
|
|
|
|
%post -n libva-x11-1 -p /sbin/ldconfig
|
|
|
|
%postun -n libva-x11-1 -p /sbin/ldconfig
|
|
%endif
|
|
|
|
%if %{build_gl}
|
|
%files -n libva-glx1
|
|
%defattr(-, root, root)
|
|
%{_libdir}/libva-glx.so.*
|
|
|
|
%files -n libva-egl1
|
|
%defattr(-, root, root)
|
|
%{_libdir}/libva-egl.so.*
|
|
|
|
%if %{with wayland}
|
|
%files -n vaapi-wayland-tools
|
|
%defattr(-,root,root)
|
|
|
|
%files -n libva-wayland1
|
|
%defattr(-, root, root)
|
|
%{_libdir}/libva-wayland.so.*
|
|
%endif
|
|
|
|
%files devel
|
|
%defattr(-,root,root,-)
|
|
%{_libdir}/libva-glx.so
|
|
%{_libdir}/libva-egl.so
|
|
%{_includedir}/va
|
|
%{_libdir}/pkgconfig/libva*.pc
|
|
%if %{with wayland}
|
|
%{_libdir}/libva-wayland.so
|
|
%endif
|
|
|
|
%else
|
|
|
|
%files -n libva1
|
|
%defattr(-, root, root)
|
|
%doc COPYING
|
|
%{_libdir}/libva.so.*
|
|
%{_libdir}/libva-tpi.so.*
|
|
|
|
%files -n libva-x11-1
|
|
%defattr(-, root, root)
|
|
%{_libdir}/libva-x11.so.*
|
|
|
|
%files -n libva-drm1
|
|
%defattr(-, root, root)
|
|
%{_libdir}/libva-drm.so.*
|
|
|
|
%files devel
|
|
%defattr(-,root,root,-)
|
|
%{_libdir}/libva.so
|
|
%{_libdir}/libva-tpi.so
|
|
%{_libdir}/libva-x11.so
|
|
%{_libdir}/libva-drm.so
|
|
%{_includedir}/va
|
|
%{_libdir}/pkgconfig/libva*.pc
|
|
%endif
|
|
|
|
%changelog
|