%define name concordance %define version 0.21 %define cvs 0 %define rel 2 %define subrel 1 %define major 1 %define libname %mklibname concord %major %define devname %mklibname concord -d Summary: Command-line Logitech Harmony remote programmer Name: %{name} Version: %{version} %if %cvs Release: %mkrel 1.%cvs.%rel %else Release: %mkrel %{rel} %endif License: GPLv3+ URL: http://www.phildev.net/harmony/ %if %cvs Source: concordance-%{cvs}.tar.lzma %else Source: http://downloads.sourceforge.net/concordance/concordance-%{version}.tar.bz2 %endif Patch0: concordance-mime.patch Patch1: consnoop-includes.patch Patch2: concordance-clean-udev-rules.patch Patch3: concordance-udev-acl.patch BuildRoot: %{_tmppath}/%{name}-root Group: System/Configuration/Hardware BuildRequires: libusb-devel BuildRequires: python-devel BuildRequires: swig BuildRequires: perl-devel BuildRequires: chrpath %description This command-line software allows you to program your Logitech Harmony remote using a configuration object retreived from the Harmony website. %package -n libconcord-common Summary: Common files of libconcord Group: System/Libraries %description -n libconcord-common Common files required by Logitech Harmony remote programmer library. %package -n %libname Summary: System library of libconcord Group: System/Libraries Requires: libconcord-common >= %{version}-%{release} %description -n %libname Logitech Harmony remote programmer library for applications that use it. %package -n %devname Summary: Development headers for libconcord Group: Development/C Requires: %libname = %version Provides: concord-devel = %version-%release %description -n %devname Development headers for developing applications that use libconcord, a Logitech Harmony remote programmer library. %package -n perl-concord Summary: Perl bindings for libconcord Group: Development/Perl %description -n perl-concord Perl bindings for libconcord, a Logitech Harmony remote programmer library. %package -n python-libconcord Summary: Python bindings for libconcord Group: Development/Python Requires: %libname %description -n python-libconcord Python bindings for libconcord, a Logitech Harmony remote programmer library. %prep %if %cvs %setup -q -n concordance autoreconf -i libconcord concordance %else %setup -q %endif %patch0 -p1 %patch1 -p1 %patch2 -p1 %patch3 -p1 %build cd libconcord # patch0 autoreconf -f libtoolize -f %configure2_5x --disable-static --disable-mime-update %make %if %{mdkversion} >= 201000 # Not needed on older releases, logged-in users have already access to USB devices %make udev_acl1 %endif cd bindings/perl swig -perl5 concord.i %{__perl} Makefile.PL INSTALLDIRS=vendor INC=-I../.. LIBS="-L../../.libs -lconcord" %make cd ../../.. cd concordance %configure2_5x CPPFLAGS=-I../libconcord LDFLAGS="%{?ldflags} -L../libconcord" %make cd .. cd consnoop %make CXXFLAGS="%optflags %{?ldflags}" %install rm -rf %{buildroot} %makeinstall_std -C libconcord \ %if %{mdkversion} >= 201000 install_udev_acl1 %endif # %makeinstall_std -C libconcord/bindings/perl chrpath -d %{buildroot}%{perl_vendorarch}/auto/concord/concord.so %makeinstall_std -C concordance cd libconcord/bindings/python python setup.py install --root=%{buildroot} cd - # useful or not? include for now: install -m755 consnoop/consnoop %{buildroot}%{_bindir} rm -f %{buildroot}%{_libdir}/libconcord.la %clean rm -rf %{buildroot} %post -n libconcord-common # apply new/updated rules /sbin/udevadm trigger --subsystem-match=usb --attr-match=idVendor=046d --attr-match=idProduct="c1*" /sbin/udevadm trigger --subsystem-match=usb --attr-match=idVendor=0400 --attr-match=idProduct="c359" %files %defattr(-,root,root) %doc concordance/README %doc Changelog %{_bindir}/concordance %{_mandir}/man1/concordance* %files -n libconcord-common %defattr(-,root,root) %if %{mdkversion} >= 201000 /lib/udev/rules.d/60-libconcord.rules %endif %{_datadir}/mime/packages/libconcord.xml %files -n %{libname} %defattr(-,root,root) %{_libdir}/libconcord.so.%{major}* %files -n %{devname} %defattr(-,root,root) %doc libconcord/README %{_bindir}/consnoop %{_libdir}/libconcord.so %{_includedir}/libconcord.h %files -n perl-concord %defattr(-,root,root) %{perl_vendorarch}/concord.pm %{perl_vendorarch}/auto/concord %files -n python-libconcord %defattr(-,root,root) %{py_sitedir}/libconcord* %changelog * Sat Sep 04 2010 Anssi Hannula <anssi@mandriva.org> 0.21-2.1mdv2010.1 + Revision: 575836 - workaround kde bug mdvbz#59929 (file associations not working properly) * Wed Jun 23 2010 Anssi Hannula <anssi@mandriva.org> 0.21-2mdv2010.1 + Revision: 548753 - add udev rules to apply ACL to the Harmony remotes (udev-acl.patch) - clean the udev exception rules a bit (clean-udev-rules.patch) - move mime types to the new subpackage libconcord-common - add release to devel provides * Sun Jul 12 2009 Anssi Hannula <anssi@mandriva.org> 0.21-1mdv2010.1 + Revision: 395311 - add missing include (includes.patch, fixes build with current toolchain) - new version - new major - add mime type files (mime.patch based on patch from Adam Williamson, replacing the used mimetype with the ones reported by logitech server) * Sat Jan 03 2009 Funda Wang <fwang@mandriva.org> 0.20-1.20081101.2mdv2009.1 + Revision: 323756 - rebuild * Sun Nov 02 2008 Anssi Hannula <anssi@mandriva.org> 0.20-1.20081101.1mdv2009.1 + Revision: 299196 - initial Mandriva release