%define lib_major 0 %define lib_name %mklibname %{name} %{lib_major} %define devel_name %mklibname %{name} -d Summary: C library for parsing command line parameters Name: popt Version: 1.16 Release: %mkrel 4 Epoch: 1 License: MIT Group: System/Libraries Url: http://rpm5.org/files/popt/ Source0: http://rpm5.org/files/popt/%{name}-%{version}.tar.gz Patch0: popt-1.16-pkgconfig-libdir.patch Patch1: popt-1.16-automake-1.12.patch Patch2: popt-1.16-automake-1.13.patch %description Popt is a C library for parsing command line parameters. Popt was heavily influenced by the getopt() and getopt_long() functions, but it improves on them by allowing more powerful argument expansion. Popt can parse arbitrary argv[] style arrays and automatically set variables based on command line arguments. Popt allows command line arguments to be aliased via configuration files and includes utility functions for parsing arbitrary strings into argv[] arrays using shell-like rules. %package -n %{lib_name} Summary: Main %{name} library Group: System/Libraries Requires: %{name}-data = %{epoch}:%{version} Provides: %{name} = %{version}-%{release} %description -n %{lib_name} This package contains the library needed to run programs dynamically linked with the %{name} library. %package -n %{devel_name} Summary: Development headers and libraries for %{name} Group: Development/C Requires: %{lib_name} = %{epoch}:%{version} Requires: %{lib_name} >= 1:1.15-8 Provides: %{name}-devel = %{epoch}:%{version}-%{release} Provides: libpopt-devel = %{epoch}:%{version}-%{release} %description -n %{devel_name} This package contains the header files and libraries needed for developing programs using the %{name} library. %package -n %{name}-data Summary: Data files for %{name} Group: System/Libraries BuildArch: noarch %description -n popt-data This package contains popt data files like locales. %prep %setup -q %patch0 -p1 -b .pkglib64~ %patch1 -p0 -b .am %patch2 -p1 -b .automake-1_13 %build autoreconf -fi %configure2_5x --disable-rpath --disable-static %make %install %makeinstall_std %find_lang %{name} rm -f %{buildroot}%{_libdir}/*.la %files -n %{lib_name} %doc README %{_libdir}/lib%{name}.so.%{lib_major}* %files -n %{devel_name} %{_includedir}/%{name}.h %{_libdir}/pkgconfig/popt.pc %{_libdir}/lib%{name}.so %{_mandir}/man3/popt.* %files -n %{name}-data -f %{name}.lang %changelog * Sun Jan 13 2013 umeabot <umeabot> 1:1.16-4.mga3 + Revision: 378067 - Mass Rebuild - https://wiki.mageia.org/en/Feature:Mageia3MassRebuild * Thu Jan 10 2013 cjw <cjw> 1:1.16-3.mga3 + Revision: 344488 - patch2: fix build with automake 1.13 * Fri Jul 27 2012 fwang <fwang> 1:1.16-2.mga3 + Revision: 274959 - fix build with automake 1.12 - drop .la file, move to prefix * Sat Jan 08 2011 blino <blino> 1:1.16-1.mga1 + Revision: 453 - imported package popt