%define pkg_name libxdiff Summary: Create diffs/patches for text/binary files Name: libxdiff0 Version: 0.22 Release: 0 License: LGPL Group: Development/Libraries Source0: http://www.xmailserver.org/%{pkg_name}-%{version}.tar.bz2 Patch0: am-fixes.patch Patch1: libxdiff-0.22-visibility.patch URL: http://www.xmailserver.org/xdiff-lib.html BuildRoot: %{_tmppath}/%{name}-%{version}-build BuildRequires: autoconf automake libtool %description The LibXDiff library implements basic and yet complete functionalities to create file differences/patches to both binary and text files. It uses memory files as file abstraction to achieve both performance and portability. For binary files, it implements (with some modification) the algorithm described in "File System Support for Delta Compression" by Joshua P. MacDonald. For text files, it follows directives described in "An O(ND) Difference Algorithm and Its Variations" by Eugene W. Myers. Memory files used by the library are basically a collection of buffers that store the file content %package -n libxdiff-devel Summary: Header files for libxdiff library Group: Development/Libraries Requires: %{name} = %{version} %description -n libxdiff-devel Header files for libxdiff library. %prep %setup -q -n %{pkg_name}-%{version} %patch0 %patch1 %build autoreconf -fi CFLAGS="%{optflags} -fno-strict-aliasing" CXXFLAGS="%{optflags} -fno-strict-aliasing" %if 0%{?suse_version} > 1000 CFLAGS="$CFLAGS -fstack-protector" CXXFLAGS="$CXXFLAGS -fstack-protector" %endif export CFLAGS export CXXFLAGS %configure --enable-hidden-symbols --with-pic --disable-static --disable-rpath make %{?_smp_mflags} %install %{__make} install DESTDIR=%{buildroot} %post -p /sbin/ldconfig %postun -p /sbin/ldconfig %files %defattr(-,root,root) %{_libdir}/libxdiff.so.0* %files -n libxdiff-devel %defattr(-,root,root) %doc AUTHORS %{_libdir}/lib*.so %{_includedir}/xdiff.h %{_mandir}/man3/xdiff.3* %exclude %{_libdir}/*.la %changelog