%define LIBVER 62.0.0 Summary: A library for manipulating JPEG image format files. Name: libjpeg Version: 6b Release: 5 License: IBM_ILA URL: http://www.ijg.org Group: System Environment/Libraries Source0: ftp://ftp.uu.net/graphics/jpeg/jpegsrc.v6b.tar.gz Source1: IBM_ILA Patch0: jpeg-6b-aixltconf.patch Prefix: %{_prefix} Buildroot: /var/tmp/libjpeg-root %package devel Summary: Development tools for programs which will use the libjpeg library. Group: Development/Libraries Requires: libjpeg %define stdlib lib %define liblink ../.. %define DEFCC cc %description The libjpeg package contains a library of functions for manipulating JPEG images, as well as simple client programs for accessing the libjpeg functions. Libjpeg client programs include cjpeg, djpeg, jpegtran, rdjpgcom and wrjpgcom. Cjpeg compresses an image file into JPEG format. Djpeg decompresses a JPEG file into a regular image file. Jpegtran can perform various useful transformations on JPEG files. Rdjpgcom displays any text comments included in a JPEG file. Wrjpgcom inserts text comments into a JPEG file. %description devel The libjpeg-devel package includes the header files and static libraries necessary for developing programs which will manipulate JPEG files using the libjpeg library. If you are going to develop programs which will manipulate JPEG images, you should install libjpeg-devel. You'll also need to have the libjpeg package installed. %prep %setup -q -n jpeg-6b %patch0 -p1 -b .aixlt # Add license info cat $RPM_SOURCE_DIR/IBM_ILA > LICENSE cat README >> LICENSE %build # Use the default compiler for this platform - gcc otherwise if [[ -z "$CC" ]] then if test "X`type %{DEFCC} 2>/dev/null`" != 'X'; then export CC=%{DEFCC} else export CC=gcc fi fi if test "X$CC" != "Xgcc" then export RPM_OPT_FLAGS=`echo $RPM_OPT_FLAGS | sed 's:-fsigned-char::'` export CFLAGS="$RPM_OPT_FLAGS" fi %define optflag "$RPM_OPT_FLAGS" %configure \ --enable-shared --enable-static --prefix=$RPM_BUILD_ROOT%{_prefix} \ --exec_prefix=$RPM_BUILD_ROOT%{_prefix} make %ifnarch armv4l #FIX MEEE: we know this will fail on arm LD_LIBRARY_PATH=$PWD make test %endif %install rm -rf $RPM_BUILD_ROOT %ifos linux mkdir -p $RPM_BUILD_ROOT/usr/{lib,include,bin,man/man1} %else for i in lib include bin man/man1 do mkdir -p $RPM_BUILD_ROOT%{_prefix}/$i done %endif make prefix=$RPM_BUILD_ROOT%{_prefix} install /usr/bin/strip $RPM_BUILD_ROOT%{_prefix}/bin/* || : (cd $RPM_BUILD_ROOT for dir in bin include do mkdir -p usr/$dir cd usr/$dir ln -sf ../..%{prefix}/$dir/* . cd - done mkdir -p usr/%{stdlib} cd usr/%{stdlib} ln -sf %{liblink}%{prefix}/lib/* . ) %ifarch ppc || %ifarch rs6000 && %ifnos linux ( cd $RPM_BUILD_ROOT/%{prefix}/lib # Create a compatibility member to mitigate differences with Bull Freeware # offering COMPATMEMBER=shr.o for lib in *.a do /usr/bin/dump -Tv $lib |/usr/bin/awk 'match($4,"EXP|Exp") { print $NF }' > tmp.exp libbase=`print $lib | sed -e 's/.a$//' -e 's/^lib//'` ld -L. -bI:tmp.exp -bE:tmp.exp -l$libbase -bM:SRE -bnoentry -o $COMPATMEMBER /usr/bin/strip -e $COMPATMEMBER # Make shr.o a load-only module /usr/bin/ar -r $lib $COMPATMEMBER rm -f $COMPATMEMBER tmp.exp done ) %endif %clean rm -rf $RPM_BUILD_ROOT %files %defattr(-,root,root) %doc usage.doc LICENSE %{_prefix}/bin/* /usr/bin/* %{_prefix}/lib/*.a /usr/%{stdlib}/*.a %{_prefix}/man/*/* %files devel %defattr(-,root,root) %doc libjpeg.doc coderules.doc LICENSE %{_prefix}/include/*.h %ifos linux %{_prefix}/lib/*.a %endif /usr/include/*.h %changelog * Fri Nov 22 2002 David Clissold - Add IBM ILA license. * Wed Mar 07 2001 Marc Stephenson - Update to libtool 1.3.5a - Add logic for default compiler - Add compatibility member for Bull freeware * Fri Feb 16 2001 aixtoolbox - Account for different standard lib location in IA64 32-bit ABI * Fri Oct 27 2000 pkgmgr - Modify for AIX Freeware distribution * Sat Feb 5 2000 Bernhard Rosenkränzer - rebuild to get compressed man pages - fix description - some minor tweaks to the spec file - add docs - fix build on alpha (alphaev6 stuff) * Sun Mar 21 1999 Cristian Gafton - auto rebuild in the new build environment (release 9) * Wed Jan 13 1999 Cristian Gafton - patch to build on arm - build for glibc 2.1 * Mon Oct 12 1998 Cristian Gafton - strip binaries * Mon Aug 3 1998 Jeff Johnson - fix buildroot problem. * Tue Jun 09 1998 Prospector System - translations modified for de * Thu Jun 04 1998 Marc Ewing - up to release 4 - remove patch that set (improper) soname - libjpeg now does it itself * Thu May 07 1998 Prospector System - translations modified for de, fr, tr * Fri May 01 1998 Cristian Gafton - fixed build on manhattan * Wed Apr 08 1998 Cristian Gafton - upgraded to version 6b * Wed Oct 08 1997 Donnie Barnes - new package to remove jpeg stuff from libgr and put in it's own package