forked from pool/v4l-utils
		
	Update to v0.8.5 OBS-URL: https://build.opensuse.org/request/show/76856 OBS-URL: https://build.opensuse.org/package/show/devel:libraries:c_c++/v4l-utils?expand=0&rev=3
		
			
				
	
	
		
			234 lines
		
	
	
		
			7.2 KiB
		
	
	
	
		
			RPMSpec
		
	
	
	
	
	
			
		
		
	
	
			234 lines
		
	
	
		
			7.2 KiB
		
	
	
	
		
			RPMSpec
		
	
	
	
	
	
#
 | 
						|
# spec file for package v4l-utils
 | 
						|
#
 | 
						|
# Copyright (c) 2011 SUSE LINUX Products 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/
 | 
						|
#
 | 
						|
 | 
						|
# norootforbuild
 | 
						|
 | 
						|
 | 
						|
Name:           v4l-utils
 | 
						|
Version:        0.8.5
 | 
						|
Release:        1
 | 
						|
Summary:        Utilities for video4linux and DVB devices
 | 
						|
 | 
						|
# ir-keytable and v4l2-sysfs-path are GPLv2 only
 | 
						|
License:        GPLv2+ and GPLv2
 | 
						|
Url:            http://linuxtv.org/downloads/v4l-utils/
 | 
						|
Group:          Hardware/TV
 | 
						|
Source0:        http://linuxtv.org/downloads/v4l-utils/%{name}-%{version}.tar.bz2
 | 
						|
Source100:      baselibs.conf
 | 
						|
# PATCH-FIX-OPENSUSE disable_rds_compilation.patch asterios.dramis@gmail.com -- Disable compilation of utils/rds (it isn't installed anyway) as it fails to compile with i2c-dev.h from i2c-tools (needs the one from linux-glibc-devel)
 | 
						|
Patch0:         disable_rds_compilation.patch
 | 
						|
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
 | 
						|
 | 
						|
# Only needed to patch broken images in the upstream tarball
 | 
						|
BuildRequires:  ImageMagick
 | 
						|
BuildRequires:  kernel-headers
 | 
						|
BuildRequires:  libqt4-devel
 | 
						|
%if 0%{?suse_version} > 1130
 | 
						|
BuildRequires:  sysfsutils-devel
 | 
						|
%else
 | 
						|
BuildRequires:  sysfsutils
 | 
						|
%endif
 | 
						|
%if 0%{?suse_version}
 | 
						|
BuildRequires:  update-desktop-files
 | 
						|
%endif
 | 
						|
Requires:       libv4l = %{version}
 | 
						|
Requires:       udev
 | 
						|
 | 
						|
%define debug_package_requires libv4l1-0 = %{version}-%{release}
 | 
						|
%define debug_package_requires libv4l2-0 = %{version}-%{release}
 | 
						|
%define debug_package_requires libv4lconvert0 = %{version}-%{release}
 | 
						|
 | 
						|
%description
 | 
						|
v4l-utils is a collection of various video4linux (V4L) and DVB utilities. The
 | 
						|
main v4l-utils package contains cx18-ctl, ir-keytable, ivtv-ctl, v4l2-ctl and
 | 
						|
v4l2-sysfs-path.
 | 
						|
 | 
						|
%package devel-tools
 | 
						|
# decode_tm6000 is GPLv2 only
 | 
						|
License:        GPLv2+ and GPLv2
 | 
						|
Summary:        Utilities for v4l2 / DVB driver development and debugging
 | 
						|
Group:          Hardware/TV
 | 
						|
Requires:       libv4l = %{version}
 | 
						|
 | 
						|
%description devel-tools
 | 
						|
Utilities for v4l2 / DVB driver authors: decode_tm6000, v4l2-compliance and
 | 
						|
v4l2-dbg.
 | 
						|
 | 
						|
%package -n libv4l
 | 
						|
# Some of the decompression helpers are GPLv2, the rest is LGPLv2+
 | 
						|
License:        LGPLv2+ and GPLv2
 | 
						|
Summary:        Collection of video4linux support libraries
 | 
						|
Url:            http://hansdegoede.livejournal.com/3636.html
 | 
						|
Group:          System/Libraries
 | 
						|
 | 
						|
%description -n libv4l
 | 
						|
libv4l is a collection of libraries which adds a thin abstraction layer on
 | 
						|
top of video4linux2 devices. The purpose of this (thin) layer is to make it
 | 
						|
easy for application writers to support a wide variety of devices without
 | 
						|
having to write separate code for different devices in the same class. libv4l
 | 
						|
consists of 3 different libraries: libv4lconvert, libv4l1 and libv4l2.
 | 
						|
 | 
						|
%package -n libv4l1-0
 | 
						|
License:        LGPLv2+
 | 
						|
Summary:        Video4linux support library
 | 
						|
Group:          System/Libraries
 | 
						|
Requires:       libv4l
 | 
						|
 | 
						|
%description -n libv4l1-0
 | 
						|
libv4l1 offers the (deprecated) v4l1 API on top of v4l2 devices, independent
 | 
						|
of the drivers for those devices supporting v4l1 compatibility (which many
 | 
						|
v4l2 drivers do not).
 | 
						|
 | 
						|
This package contains shared lib for packages that use libv4l1.so.0
 | 
						|
 | 
						|
%package -n libv4l2-0
 | 
						|
License:        LGPLv2+
 | 
						|
Summary:        Video4linux support library
 | 
						|
Group:          System/Libraries
 | 
						|
Requires:       libv4l
 | 
						|
 | 
						|
%description -n libv4l2-0
 | 
						|
libv4l2 offers the v4l2 API on top of v4l2 devices, while adding for the
 | 
						|
application transparent libv4lconvert conversion where necessary.
 | 
						|
 | 
						|
This package contains shared lib for packages that use libv4l2.so.0
 | 
						|
 | 
						|
%package -n libv4lconvert0
 | 
						|
License:        LGPLv2+
 | 
						|
Summary:        Video4linux support library
 | 
						|
Group:          System/Libraries
 | 
						|
Requires:       libv4l
 | 
						|
 | 
						|
%description -n libv4lconvert0
 | 
						|
libv4lconvert offers functions to convert from any (known) pixel-format
 | 
						|
to V4l2_PIX_FMT_BGR24 or V4l2_PIX_FMT_YUV420.
 | 
						|
 | 
						|
This package contains shared lib for packages that use libv4lconvert.so.0
 | 
						|
 | 
						|
%package -n libv4l-devel
 | 
						|
License:        LGPLv2+
 | 
						|
Summary:        Development files for libv4l
 | 
						|
Group:          Development/Libraries/C and C++
 | 
						|
Requires:       libv4l1-0 = %{version}
 | 
						|
Requires:       libv4l2-0 = %{version}
 | 
						|
Requires:       libv4lconvert0 = %{version}
 | 
						|
 | 
						|
%description -n libv4l-devel
 | 
						|
The libv4l-devel package contains libraries and header files for
 | 
						|
developing applications that use libv4l.
 | 
						|
 | 
						|
%package -n     qv4l2
 | 
						|
License:        GPLv2+
 | 
						|
Summary:        Video4linux test control and streaming test application
 | 
						|
Group:          Hardware/TV
 | 
						|
Requires:       libv4l = %{version}
 | 
						|
 | 
						|
%description -n qv4l2
 | 
						|
qv4l2 is a test control and streaming test application for video4linux.
 | 
						|
 | 
						|
%prep
 | 
						|
%setup -q
 | 
						|
%patch0
 | 
						|
 | 
						|
%build
 | 
						|
make CFLAGS="%{optflags} -fno-strict-aliasing" CXXFLAGS="%{optflags}" %{?_smp_mflags}
 | 
						|
 | 
						|
%install
 | 
						|
make install PREFIX=%{_prefix} LIBDIR=%{_libdir} DESTDIR=%{buildroot}
 | 
						|
 | 
						|
# Patch image with wrong dimensions - fix rpmlint warning "wrong-icon-size"
 | 
						|
mogrify -extent "36x36" -background transparent -gravity "south" %{buildroot}%{_datadir}/icons/hicolor/32x32/apps/qv4l2.png
 | 
						|
mogrify -scale 32x32 -background transparent %{buildroot}%{_datadir}/icons/hicolor/32x32/apps/qv4l2.png
 | 
						|
 | 
						|
%if 0%{?suse_version}
 | 
						|
%suse_update_desktop_file -N "QV4l2" -G "V4L2 Test Utility" -r qv4l2 Qt AudioVideo Video TV
 | 
						|
%endif
 | 
						|
 | 
						|
%clean
 | 
						|
rm -rf %{buildroot}
 | 
						|
 | 
						|
%post -n libv4l1-0 -p /sbin/ldconfig
 | 
						|
 | 
						|
%postun -n libv4l1-0 -p /sbin/ldconfig
 | 
						|
 | 
						|
%post -n libv4l2-0 -p /sbin/ldconfig
 | 
						|
 | 
						|
%postun -n libv4l2-0 -p /sbin/ldconfig
 | 
						|
 | 
						|
%post -n libv4lconvert0 -p /sbin/ldconfig
 | 
						|
 | 
						|
%postun -n libv4lconvert0 -p /sbin/ldconfig
 | 
						|
 | 
						|
%files
 | 
						|
%defattr(-,root,root,-)
 | 
						|
%doc COPYING ChangeLog README TODO
 | 
						|
%dir %{_sysconfdir}/rc_keymaps
 | 
						|
%config(noreplace) %{_sysconfdir}/rc_keymaps/*
 | 
						|
%config(noreplace) %{_sysconfdir}/rc_maps.cfg
 | 
						|
/lib/udev/rules.d/70-infrared.rules
 | 
						|
%{_bindir}/cx18-ctl
 | 
						|
%{_bindir}/ir-keytable
 | 
						|
%{_bindir}/ivtv-ctl
 | 
						|
%{_bindir}/v4l2-ctl
 | 
						|
%{_bindir}/v4l2-sysfs-path
 | 
						|
%{_mandir}/man1/ir-keytable.1%{ext_man}
 | 
						|
 | 
						|
%files devel-tools
 | 
						|
%defattr(-,root,root,-)
 | 
						|
%doc COPYING ChangeLog README TODO
 | 
						|
%{_bindir}/decode_tm6000
 | 
						|
%{_bindir}/v4l2-compliance
 | 
						|
%{_sbindir}/v4l2-dbg
 | 
						|
 | 
						|
%files -n libv4l
 | 
						|
%defattr(-,root,root,-)
 | 
						|
%doc COPYING.LIB ChangeLog README README.lib TODO
 | 
						|
%{_libdir}/libv4l/
 | 
						|
 | 
						|
%files -n libv4l1-0
 | 
						|
%defattr(-,root,root,-)
 | 
						|
%{_libdir}/libv4l1.so.*
 | 
						|
 | 
						|
%files -n libv4l2-0
 | 
						|
%defattr(-,root,root,-)
 | 
						|
%{_libdir}/libv4l2.so.*
 | 
						|
 | 
						|
%files -n libv4lconvert0
 | 
						|
%defattr(-,root,root,-)
 | 
						|
%{_libdir}/libv4lconvert.so.*
 | 
						|
 | 
						|
%files -n libv4l-devel
 | 
						|
%defattr(-,root,root,-)
 | 
						|
%doc README.lib-multi-threading
 | 
						|
%{_includedir}/libv4l*.h
 | 
						|
%{_libdir}/libv4l*.so
 | 
						|
%{_libdir}/pkgconfig/*.pc
 | 
						|
 | 
						|
%files -n qv4l2
 | 
						|
%defattr(-,root,root,-)
 | 
						|
%doc COPYING ChangeLog README TODO
 | 
						|
%{_bindir}/qv4l2
 | 
						|
%{_datadir}/applications/qv4l2.desktop
 | 
						|
%dir %{_datadir}/icons/hicolor
 | 
						|
%dir %{_datadir}/icons/hicolor/??x??
 | 
						|
%dir %{_datadir}/icons/hicolor/??x??/apps
 | 
						|
%dir %{_datadir}/icons/hicolor/scalable
 | 
						|
%dir %{_datadir}/icons/hicolor/scalable/apps
 | 
						|
%{_datadir}/icons/hicolor/*/apps/qv4l2.*
 | 
						|
 | 
						|
%changelog
 |