##### GENERAL STUFF ##### %define major 0 %define libname %mklibname gpio %{major} Summary: I/O library for GPhoto 2.x Name: libgpio Version: 0.0.2 Release: %mkrel 16 License: LGPL Group: Graphics ##### SOURCE FILES ##### Source: libgpio.tar.bz2 Patch0: libgpio-alpha.patch Patch1: libgpio-includes.patch Patch2: libgpio-lib64.patch ##### ADDITIONAL DEFINITIONS ##### BuildRequires: libusb-devel automake1.7 BuildRoot: %{_tmppath}/%{name}-buildroot ##### SUB-PACKAGES ##### %description libgpio is a library for different I/O operations done by GPhoto 2.0 %package -n %{libname} Summary: I/O library for GPhoto 2.x Group: Graphics Provides: libgpio = %{version}-%{release} %description -n %{libname} libgpio is a library for different I/O operations done by GPhoto 2.0 %package -n %{libname}-devel Summary: Headers and links to compile against the "%{libname}" library Requires: %{libname} = %{version}-%{release} Provides: libgpio-devel = %{version}-%{release} Group: Graphics %description -n %{libname}-devel This package contains all files which one needs to compile programs using the "%{libname}" library. %prep %setup -q -n libgpio %patch -p1 -b .alpha %patch1 -p1 -b .includes %patch2 -p1 -b .lib64 %build # "autogen" is needed because we have a CVS snapshot. # (cjw) do not run autogen.sh directly libtoolize --copy --force aclocal-1.7 autoheader automake-1.7 -a -c --gnu autoconf %configure %make ##### INSTALL ##### %install rm -rf $RPM_BUILD_ROOT %makeinstall # Install the README files of the source tarball in the doc directory #cp *.txt $RPM_BUILD_ROOT%{_defaultdocdir}/%{name} %if %mdkversion < 200900 %post -n %{libname} -p /sbin/ldconfig %endif %if %mdkversion < 200900 %postun -n %{libname} -p /sbin/ldconfig %endif %clean rm -rf $RPM_BUILD_ROOT %files -n %{libname} %defattr(-,root,root) %{_libdir}/*.so.* %{_libdir}/gpio/*.so.* %files -n %{libname}-devel %defattr(-,root,root) %{_libdir}/*.so %{_libdir}/*.la %{_libdir}/*.a %{_libdir}/*.sh %{_libdir}/gpio/*.so %{_libdir}/gpio/*.la %{_libdir}/gpio/*.a %{_bindir}/* %{_includedir}/gpio/* %changelog * Fri Jul 25 2008 Thierry Vignaud <tvignaud@mandriva.com> 0.0.2-16mdv2009.0 + Revision: 248723 - rebuild + Pixel <pixel@mandriva.com> - do not call ldconfig in %%post/%%postun, it is now handled by filetriggers - fix %%post/%%postun (wrong subpackage) * Wed Jan 02 2008 Olivier Blin <oblin@mandriva.com> 0.0.2-14mdv2008.1 + Revision: 140924 - restore BuildRoot + Thierry Vignaud <tvignaud@mandriva.com> - kill re-definition of %%buildroot on Pixel's request * Mon Aug 27 2007 Thierry Vignaud <tvignaud@mandriva.com> 0.0.2-14mdv2008.0 + Revision: 72212 - BuildRequires: automake1.7 - use %%mkrel * Thu Jan 12 2006 Christiaan Welvaart <cjw@daneel.dyndns.org> 0.0.2-13mdk - do not use autogen.sh for building * Fri Sep 19 2003 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 0.0.2-12mdk - fix package name * Tue Sep 02 2003 Till Kamppeter <till@mandrakesoft.com> 0.0.2-11mdk - Corrected BuildRequires: no major numbers for libraries (needed to build on 64-bit systems). * Tue Sep 02 2003 Till Kamppeter <till@mandrakesoft.com> 0.0.2-10mdk - Used the mklibname macro. * Tue Jul 22 2003 Per Øyvind Karlsen <peroyvind@sintrax.net> 0.0.2-9mdk - rebuild - don't rm -rf $RPM_BUILD_ROOT in %%prep