%define with_libexpat0 1 %define expat0_ver 1.95.8 Name: expat Version: 2.0.1 Release: 1mamba Summary: Expat is an XML parser written in C Group: Development/Applications Vendor: openmamba Distribution: openmamba Packager: Silvan Calarco URL: http://expat.sourceforge.net/ Source0: http://puzzle.dl.sourceforge.net/sourceforge/expat/expat-%{version}.tar.gz Source1: http://puzzle.dl.sourceforge.net/sourceforge/expat/expat-%{expat0_ver}.tar.gz License: GPL BuildRoot: %{_tmppath}/%{name}-%{version}-root %description Expat is an XML parser library written in C. It is a stream-oriented parser in which an application registers handlers for things the parser might find in the XML document (like start tags). This project aims to maintain Expat for both current and future users while improving the API to allow more reliable and robust access from "scripting" languages such as Python and Perl. %package -n libexpat Group: Development/Libraries Summary: Main library for expat %description -n libexpat This package contains the library needed to run programs dynamically linked with expat. %package -n libexpat-devel Group: Development/Libraries Summary: Development environment for the expat XML parser Requires: libexpat = %{version}-%{release} %description -n libexpat-devel Development environment for the expat XML parser. %if %{with_libexpat0} %package -n libexpat0 Group: Development/Libraries Summary: Main library for expat 1.95.x %description -n libexpat0 This package contains the library needed to run programs dynamically linked with expat 1.95.x. %endif %prep %setup -q -a1 %build %if %{with_libexpat0} cd expat-%{expat0_ver} %configure %make cd .. %endif %configure %make %install [ "%{buildroot}" != / ] && rm -rf "%{buildroot}" %if %{with_libexpat0} make -C expat-%{expat0_ver} installlib \ libdir=%{buildroot}%{_libdir} \ includedir=%{buildroot}%{_includedir} rm -fr %{buildroot}%{_includedir} rm -f %{buildroot}%{_libdir}/libexpat.{a,la,so} %endif %makeinstall #man1dir=%{buildroot}%{_mandir}/man1 %clean [ "%{buildroot}" != / ] && rm -rf "%{buildroot}" %post -n libexpat -p /sbin/ldconfig %postun -n libexpat -p /sbin/ldconfig %if %{with_libexpat0} %post -n libexpat0 -p /sbin/ldconfig %postun -n libexpat0 -p /sbin/ldconfig %endif %files %defattr(-,root,root) %{_bindir}/xmlwf %{_mandir}/man1/xmlwf.* %files -n libexpat %defattr(-,root,root) %{_libdir}/libexpat.so.* %if %{with_libexpat0} %exclude %{_libdir}/libexpat.so.0 %exclude %{_libdir}/libexpat.so.0.5.0 %endif %files -n libexpat-devel %defattr(-,root,root) %{_includedir}/*.h %{_libdir}/libexpat.a %{_libdir}/libexpat.la %{_libdir}/libexpat.so %if %{with_libexpat0} %files -n libexpat0 %defattr(-,root,root) %{_libdir}/libexpat.so.0 %{_libdir}/libexpat.so.0.5.0 %endif %changelog * Wed Sep 26 2007 Silvan Calarco 2.0.1-1mamba - update to 2.0.1 * Mon May 07 2007 Silvan Calarco 2.0.0-3mamba - revert to expat includes in %{includedir} * Fri Apr 27 2007 Silvan Calarco 2.0.0-2mamba - includes moved to %{_includedir}/expat subdir * Mon May 22 2006 Davide Madrisan 2.0.0-1qilnx - update to version 2.0.0 by autospec - fixed package groups - added post and postun scripts for libexpat - new package libexpat0 (compatibility libraries) * Sun Oct 30 2005 Silvan Calarco 1.95.8-1qilnx - update to version 1.95.8 by autospec * Mon May 12 2003 Silvan Calarco 1.95.6-3qilnx - added lfs patch that solves an XML_Status declaration problem in expat.h * Mon May 12 2003 Silvan Calarco 1.95.6-2qilnx - added libexpat.so in devel package * Mon May 12 2003 Silvan Calarco 1.95.6-1qilnx - First build