Summary: A file compression utility Name: lzlib Version: 0.7 Release: 1 License: BSD Group: Applications/File URL: http://www.nongnu.org/lzip/lzlib.html Source0: http://www.very-clever.com/download/nongnu/lzip/%{name}-%{version}.tar.gz Patch0: %{name}-%{version}-aix.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root %description The lzlib compression library provides in-memory LZMA compression and decompression functions, including integrity checking of the uncompressed data. The compressed data format used by the library is the lzip format. Compression/decompression is done by repeteadly calling a couple of read/write functions until all the data has been processed by the library. This interface is safer and less error prone than the traditional zlib interface. Lzlib will correctly decompress a data stream which is the concatenation of two or more compressed data streams. The result is the concatenation of the corresponding uncompressed data streams. Integrity testing of concatenated compressed data streams is also supported. All the library functions are thread safe. The library does not install any signal handler. The decoder checks the consistency of the compressed data, so the library should never crash even in case of corrupted input. Lzlib implements a simplified version of the LZMA (Lempel-Ziv-Markov chain-Algorithm) algorithm. The original LZMA algorithm was designed by Igor Pavlov. For a description of the LZMA algorithm, see the lzip manual. The library is available as 32-bit and 64-bit. %package devel Summary: Header files developing apps which will use bzip2 Group: Development/Libraries Requires: %{name} = %{version}-%{release} %description devel Header files of lzlib functions, for developing apps which will use the library. If you are compiling a 32-bit program, no special compiler options are needed. If you are compiling a 64-bit program, you have to compile and link your application with "cc -q64" or "gcc -maix64". %prep %setup -q %patch0 %build # setup environment for 32-bit and 64-bit builds export AR="ar -X32_64" # first build the 64-bit version export OBJECT_MODE=64 ./configure \ --prefix=%{_prefix} \ CC=xlc CXX=xlC CFLAGS=-O CXXFLAGS=-O gmake liblz.a CreateExportList -X64 %{name}.exp liblz.a ${CXX} -qmkshrobj liblz.a -o shr64.o -bE:%{name}.exp rm -f %{name}.exp gmake clean # now build the 32-bit version export OBJECT_MODE=32 gmake liblz.a CreateExportList -X32 %{name}.exp liblz.a ${CXX} -qmkshrobj liblz.a -o shr.o -bE:%{name}.exp rm -f liblz.a ${AR} -rv liblz.a shr64.o shr.o # make minilzip rm -f minilzip gmake minilzip %install [ "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT mkdir -p ${RPM_BUILD_ROOT}%{_bindir} mkdir -p ${RPM_BUILD_ROOT}%{_libdir} mkdir -p ${RPM_BUILD_ROOT}%{_includedir} mkdir -p ${RPM_BUILD_ROOT}%{_infodir} cp minilzip ${RPM_BUILD_ROOT}%{_bindir} chmod 0755 ${RPM_BUILD_ROOT}%{_bindir}/* /usr/bin/strip ${RPM_BUILD_ROOT}%{_bindir}/* || : cp liblz.a ${RPM_BUILD_ROOT}%{_libdir} chmod 0644 ${RPM_BUILD_ROOT}%{_libdir}/* cp %{name}.h ${RPM_BUILD_ROOT}%{_includedir} chmod 0644 ${RPM_BUILD_ROOT}%{_includedir}/* cp doc/%{name}.info ${RPM_BUILD_ROOT}%{_infodir} gzip --best ${RPM_BUILD_ROOT}%{_infodir}/* chmod 0644 ${RPM_BUILD_ROOT}%{_infodir}/* ( cd ${RPM_BUILD_ROOT} for dir in bin include lib do mkdir -p usr/${dir} cd usr/${dir} ln -sf ../..%{_prefix}/${dir}/* . cd - done ) %clean [ "${RPM_BUILD_ROOT}" != "/" ] && rm -rf ${RPM_BUILD_ROOT} %files %defattr(-,root,system,-) %doc AUTHORS COPYING ChangeLog INSTALL README %{_bindir}/* %{_libdir}/* %{_infodir}/* /usr/bin/* /usr/lib/* %files devel %defattr(-,root,system,-) %{_includedir}/* /usr/include/* %changelog * Tue Dec 15 2009 Michael Perzl - 0.7-1 - updated to version 0.7 * Thu Jul 09 2009 Michael Perzl - 0.5-1 - updated to version 0.5 * Wed Jul 08 2009 Michael Perzl - 0.4-1 - first version for AIX V5.1 and higher