Sophie

Sophie

distrib > Fedora > 15 > i386 > by-pkgid > 4bf4273c3d596fcbd6bbb2a9d3c1e7bd > files > 4

libconcord-0.23-5.fc15.src.rpm

%{!?python_sitearch: %define python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")}
%define mainpkg concordance

Name: libconcord
Version: 0.23
Release: 5%{?dist}
Summary: Library to talk to Logitech Harmony universal remote controls

Group: Development/Libraries
License: GPLv3+
URL: http://phildev.net/concordance/
Source0: http://downloads.sourceforge.net/sourceforge/concordance/%{mainpkg}-%{version}.tar.bz2
Patch0: libconcord-0.23-mime-type-def.patch
Patch1: libconcord-0.23-udev_acl.patch
BuildRoot: %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)

BuildRequires: libusb-devel
BuildRequires: swig
BuildRequires: perl(ExtUtils::MakeMaker)
BuildRequires: python-devel
BuildRequires: python-setuptools-devel
Requires: udev
Requires(post): /sbin/ldconfig
Requires(postun): /sbin/ldconfig

%description
Library to talk to Logitech Harmony universal remote controls


%package devel
Summary: Development libraries for libconcord
Group: Development/Libraries
Requires: %{name} = %{version}-%{release}

%description devel
Development libraries for libconcord


%package perl
Summary: Perl bindings for libconcord
Group: Development/Libraries
Requires: libconcord = %{version}-%{release}
Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))

%description perl
Perl bindings for libconcord


%package python
Summary: Python bindings for libconcord
Group: Development/Libraries
Requires: libconcord = %{version}-%{release}

%description python
Python bindings for libconcord


%prep
%setup -q -n %{mainpkg}-%{version}
%patch0 -p1
%patch1 -p1

%build
cd %{name}
%configure --disable-static --disable-mime-update
make %{_smp_mflags}


# perl bindings
cd bindings/perl
swig -perl5 concord.i
%{__perl} Makefile.PL INSTALLDIRS=vendor INC=-I../../
#sed -i -e 's|LDFLAGS =|LDFLAGS = -L../../|' Makefile
make %{_smp_mflags}
cd -

# python bindings
cd bindings/python
%if 0%{?fedora} > 8
CFLAGS="%{optflags}" %{__python} setup.py build
%else
CFLAGS="%{optflags}" %{__python} -c 'import setuptools; execfile("setup.py")' build
%endif
cd -


%install
rm -rf %{buildroot}

cd %{name}
make DESTDIR=%{buildroot} install
make DESTDIR=%{buildroot} install_udev
mkdir -p %{buildroot}/lib/udev/rules.d
mv %{buildroot}/etc/udev/rules.d/* %{buildroot}/lib/udev/rules.d/

find %{buildroot} -type f -name \*.a -exec %{__rm} -f {} \;
find %{buildroot} -type f -name \*.la -exec %{__rm}  -f {} \;

# perl bindings
cd bindings/perl
make pure_install PERL_INSTALL_ROOT=%{buildroot}
find %{buildroot} -type f -name .packlist -exec rm -f {} ';'
find %{buildroot} -type f -name '*.bs' -a -size 0 -exec rm -f {} ';'
find %{buildroot} -depth -type d -exec rmdir {} 2>/dev/null ';'
%{__chmod} 755 %{buildroot}%{perl_vendorarch}/auto/concord/concord.so
cd -

# python bindings
cd bindings/python
%if 0%{?fedora} > 8
%{__python} setup.py install -O1 --skip-build --root %{buildroot} --install-purelib %{python_sitearch}
%else
%{__python} -c 'import setuptools; execfile("setup.py")' install -O1 --skip-build --root %{buildroot} --install-purelib %{python_sitearch}
%endif
cd -


#%check
#cd %{name}
#
## perl bindings
#cd bindings/perl
#make test
#cd -


%clean
rm -rf %{buildroot}


%post
/sbin/ldconfig
/sbin/udevadm control --reload-rules
update-mime-database %{_datadir}/mime &> /dev/null || :

%postun
/sbin/ldconfig
/sbin/udevadm control --reload-rules
update-mime-database %{_datadir}/mime &> /dev/null || :


%files
%defattr(-, root, root, -)
%doc Changelog CodingStyle LICENSE SubmittingPatches
%doc %{name}/README %{name}/INSTALL.linux
/lib/udev/rules.d/*.rules
%{_datadir}/mime/packages/%{name}.xml
%{_libdir}/*.so.*

%files devel
%defattr(-, root, root)
%doc TODO
%{_includedir}/*.h
%{_libdir}/*.so

%files perl
%defattr(-, root, root)
%doc %{name}/bindings/perl/README
%{perl_vendorarch}/auto/*
%{perl_vendorarch}/concord.pm

%files python
#%doc %{name}/bindings/python/README
%defattr(-, root, root)
%{python_sitearch}/*


%changelog
* Thu Mar 17 2011 Bill Nottingham <notting@redhat.com> - 0.23-5
- don't require hal or polkit; the udev rules are enough
- put udev rules in /lib, not /etc

* Thu Mar 17 2011 Adam Williamson <awilliam@redhat.com> - 0.23-4
- udev_acl.patch: change to ID_REMOTE_CONTROL per upstream request

* Thu Mar 17 2011 Adam Williamson <awilliam@redhat.com> - 0.23-3
- add udev_acl.patch: add ID_PROGRAMMABLE_REMOTE so udev can set acls

* Mon Feb 07 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.23-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild

* Fri Nov 19 2010 Adam Williamson <awilliam@redhat.com> - 0.23-1
- new version 0.23

* Wed Jul 21 2010 David Malcolm <dmalcolm@redhat.com> - 0.21-10
- Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild

* Tue Jun 01 2010 Marcela Maslanova <mmaslano@redhat.com> - 0.21-9
- Mass rebuild with perl-5.12.0

* Fri Dec  4 2009 Stepan Kasal <skasal@redhat.com> - 0.21-8
- rebuild against perl 5.10.1

* Fri Jul 31 2009 Douglas E. Warner <silfreed@silfreed.net> 0.21-7
- updating mime patch with different source:
  http://stuff.onse.fi/concordance-mime2.patch
  https://sourceforge.net/tracker/?func=detail&aid=2807865&group_id=201579&atid=978130

* Thu Jul 30 2009 Douglas E. Warner <silfreed@silfreed.net> 0.21-6
- updated patch w/ autoreconf run

* Fri Jul 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.21-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild

* Wed Jun 17 2009 Douglas E. Warner <silfreed@silfreed.net> 0.21-4
- updated patch w/ autoreconf run

* Wed Jun 17 2009 Douglas E. Warner <silfreed@silfreed.net> 0.21-3
- adding a mime-type definition so other packages can handle them appropriately
  (bug#506536)

* Wed Jun 17 2009 Douglas E. Warner <silfreed@silfreed.net> 0.21-2
- fixing name of hal policy to allow device to be accessed from non-root user
  properly (bug#506371)

* Tue Mar 10 2009 Douglas E. Warner <silfreed@silfreed.net> 0.21-1
- moving policykit rule generation from concordnace to here
- including new upstream install for policykit/hal/udev rules
- removing registered marks
- supports updating firmware on 5** remotes
- improved IR learning support

* Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.20-8
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild

* Fri Jan 30 2009 Douglas E. Warner <silfreed@silfreed.net> 0.20-7
- removing registered marks
 
* Sat Nov 29 2008 Ignacio Vazquez-Abrams <ivazqueznet+rpm@gmail.com> - 0.20-6
- Rebuild for Python 2.6

* Sat May 03 2008 Douglas E. Warner <silfreed@silfreed.net> 0.20-5
- fixing TODO file included twice
- adding bindings docs

* Sat May 03 2008 Douglas E. Warner <silfreed@silfreed.net> 0.20-4
- installing python packages to sitearch again
- adding additional docs

* Wed Apr 23 2008 Douglas E. Warner <silfreed@silfreed.net> 0.20-3
- fixed Source0 url to downloads.sourceforge.net instead of dl.sourceforge.net
- fixing mode of concord.so
- fixing python egg generation; adding buildrequire for python-setuptools-devel

* Tue Apr 22 2008 Douglas E. Warner <silfreed@silfreed.net> 0.20-2
- fixed Source0 url
- changing to build/install dir rather than setting it in setup macro
- adding perl/python bindings

* Mon Apr 21 2008 Douglas E. Warner <silfreed@silfreed.net> 0.20-1
- update to 0.20
- removing unneeded gcc 4.3 patch

* Mon Mar 24 2008 Douglas E. Warner <silfreed@silfreed.net> 0.20-0.3.20080318cvs
- moved Requires ldconfig to post/postun
- adding patch for gcc 4.3 to define extra headers

* Tue Mar 18 2008 Douglas E. Warner <silfreed@silfreed.net> 0.20-0.2.20080318cvs
- adding devel dependancy on main package
- moved TODO from main package to devel
- fixed license to be GPLv3+, not GPLv2+
- disabling static linking
- removing static libraries

* Tue Mar 18 2008 Douglas E. Warner <silfreed@silfreed.net> 0.20-0.1.20080318cvs
- Initial RPM release.