%define subver 1.2 %define age 0 %define microver 5 Summary: The GNU Image Manipulation Program. Name: gimp Version: %{subver}.%{microver} Release: 1 Epoch: 1 License: GPL, LGPL Group: Applications/Multimedia URL: http://www.gimp.org/ BuildRoot: %{_tmppath}/%{name}-%{version}-root Obsoletes: gimp-data-min Obsoletes: gimp-libgimp Requires: gtk+ >= 1.2.0 Requires: gimp-print-plugin BuildRequires: gtk+-devel BuildRequires: glib-devel Requires: /usr/bin/desktop-file-install Source0: ftp://ftp.gimp.org/pub/gimp/v%{subver}/v%{version}/%{name}-%{version}.tar.bz2 Source1: gimp.desktop Source2: gimp.png Source3: filter-gimp-perl-requires.sh Patch0: gimp-1.1.23-perlpath.patch Patch3: gimp-1.2.3-wget-fix.patch.bz2 Patch4: gimp-1.2.5-perl-plugin.patch %define __perl_requires %{SOURCE3} %define debug_package %{nil} # gcc breaks with -g # workaround for compiler bug on s390/s390x %ifarch s390 s390x %define optflags -O2 %endif %description The GIMP (GNU Image Manipulation Program) is a powerful image composition and editing program, which can be extremely useful for creating logos and other graphics for webpages. The GIMP has many of the tools and filters you would expect to find in similar commercial offerings, and some interesting extras as well. The GIMP provides a large image manipulation toolbox, including channel operations and layers, effects, sub-pixel imaging and anti-aliasing, and conversions, all with multi-level undo. The GIMP includes a scripting facility, but many of the included scripts rely on fonts that we cannot distribute. The GIMP FTP site has a package of fonts that you can install by yourself, which includes all the fonts needed to run the included scripts. Some of the fonts have unusual licensing requirements; all the licenses are documented in the package. Get ftp://ftp.gimp.org/pub/gimp/fonts/freefonts-0.10.tar.gz and ftp://ftp.gimp.org/pub/gimp/fonts/sharefonts-0.10.tar.gz if you are so inclined. Alternatively, choose fonts which exist on your system before running the scripts. %package devel Summary: The GIMP plug-in and extension development kit. Group: Applications/Multimedia Requires: gtk+-devel, gimp = %{epoch}:%{version} %description devel The gimp-devel package contains the static libraries and header files for writing GNU Image Manipulation Program (GIMP) plug-ins and extensions. %package perl Summary: Perl extensions and plug-ins for the GIMP. Group: Applications/Multimedia Requires: gimp = %{epoch}:%{version} Requires: perl Provides: perl(Gimp::Util) Provides: perl(of) BuildPreReq: perl-PDL Gtk-Perl perl gimp-print-devel %description perl The gimp-perl package contains Perl extensions and plug-ins for the GIMP image manipulation program. %prep %setup -q %patch0 -p1 -b .perlpath %patch3 -p1 %patch4 -p1 %build #AUTOMAKE=automake-1.4 autoreconf if [ ! -f configure ]; then CFLAGS="$RPM_OPT_FLAGS" ./autogen.sh --quiet $MYARCH_FLAGS --prefix=%{_prefix} else LIBAA="disable" CFLAGS="$RPM_OPT_FLAGS" %configure fi make %{?smp_mflags} %install sed "s,\(=/\)\([a-z]\),=$RPM_BUILD_ROOT/\2,g" gimptool-1.2 > tmptool chmod 755 tmptool [ -n "$RPM_BUILD_ROOT" -a "$RPM_BUILD_ROOT" != / ] && rm -rf $RPM_BUILD_ROOT rootdir=`pwd` pushd plug-ins/perl PREFIX=$RPM_BUILD_ROOT/usr INSTALLDIRS=vendor GIMPTOOL=$rootdir/tmptool \ CFLAGS=-I$(cd ../..;pwd) LDFLAGS=-L$(cd ../../libgimp/.libs;pwd) \ perl Makefile.PL PREFIX=$RPM_BUILD_ROOT/usr INSTALLDIRS=vendor \ --disable-gimptest < /dev/null perl -pi -e "s!-Wl,-rpath,$installarchlib/CORE!!g" Makefile for I in `find -name Makefile`; do sed "s,/usr/bin/gimptool,$rootdir/tmptool,g" $I > $I- mv $I- $I done popd mkdir -p $RPM_BUILD_ROOT/%{_infodir} $RPM_BUILD_ROOT/%{_includedir} \ $RPM_BUILD_ROOT/%{_libdir} $RPM_BUILD_ROOT/%{_bindir} \ $RPM_BUILD_ROOT/%{_libdir}/gimp/%{subver}/plug-ins # makeinstall macro won't work here - libexec is overriden make prefix=$RPM_BUILD_ROOT/%{_prefix} \ bindir=$RPM_BUILD_ROOT/%{_bindir} \ libdir=$RPM_BUILD_ROOT/%{_libdir} \ mandir=$RPM_BUILD_ROOT/%{_mandir} \ infodir=$RPM_BUILD_ROOT/%{_infodir} \ datadir=$RPM_BUILD_ROOT/%{_datadir} \ includedir=$RPM_BUILD_ROOT/%{_includedir} \ gimpsysconfdir=$RPM_BUILD_ROOT/%{_sysconfdir}/gimp/%{subver} \ gimpplugindir=$RPM_BUILD_ROOT/%{_libdir}/gimp/%{subver} \ gimpdatadir=$RPM_BUILD_ROOT/%{_datadir}/gimp/%{subver} \ GIMPTOOL=`pwd`/tmptool \ install # remove the perl temp file to satisfy rpmlint rm -f `find $RPM_BUILD_ROOT%{_libdir}/perl5/ -name ".packlist"` # Strip the executables strip $RPM_BUILD_ROOT/%{_bindir}/gimp # Only strip execuable files and leave scripts alone. strip `file $RPM_BUILD_ROOT/%{_libdir}/gimp/%{subver}/plug-ins/* | grep ELF | cut -d':' -f 1` # Compress down the online documentation. if [ -d $RPM_BUILD_ROOT/%{_mandir} ]; then find $RPM_BUILD_ROOT/%{_mandir} -type f -exec gzip -9nf {} \; fi # # This perl madness will drive me batty # eval perl '-V:archname' find $RPM_BUILD_ROOT/%{_libdir}/perl5 -type f -print | sed "s@^$RPM_BUILD_ROOT@@g" | grep -v perllocal.pod > gimp-perl # Don't ship the print plug-in, but instead get it from gimp-print. rm -f %{buildroot}%{_libdir}/gimp/*/plug-ins/print # # Plugins and modules change often (grab the executeable ones) # echo "%defattr (0755, root, root)" > gimp-plugin-files find $RPM_BUILD_ROOT/%{_libdir}/gimp/%{subver} -type f -exec file {} \; | grep -v perl | cut -d':' -f 1 | sed "s@^$RPM_BUILD_ROOT@@g" | grep -v %{_libdir}/gimp/%{subver}/modules/.*\.a$ | grep -v %{_libdir}/gimp/%{subver}/modules/.*\.la$ >>gimp-plugin-files # # Now pull the perl ones out. # echo "%defattr (0755, root, root)" > gimp-perl-plugin-files echo "%dir %{_libdir}/gimp/%{subver}/plug-ins" >> gimp-perl-plugin-files find $RPM_BUILD_ROOT/%{_libdir}/gimp/%{subver} -type f -exec file {} \; | grep perl | cut -d':' -f 1 | sed "s@^$RPM_BUILD_ROOT@@g" >>gimp-perl-plugin-files # # Auto detect the lang files. # if [ -f /usr/lib/rpm/find-lang.sh ] ; then /usr/lib/rpm/find-lang.sh $RPM_BUILD_ROOT %{name} /usr/lib/rpm/find-lang.sh $RPM_BUILD_ROOT gimp-std-plugins /usr/lib/rpm/find-lang.sh $RPM_BUILD_ROOT gimp-script-fu /usr/lib/rpm/find-lang.sh $RPM_BUILD_ROOT gimp-perl /usr/lib/rpm/find-lang.sh $RPM_BUILD_ROOT gimp-libgimp cat %{name}.lang gimp-std-plugins.lang gimp-script-fu.lang \ gimp-libgimp.lang > gimp-all.lang fi # # Tips # echo "%defattr (644, root, root, 555)" >gimp-tips-files echo "%{_datadir}/gimp/%{subver}/tips/gimp_tips.txt" >> gimp-tips-files for I in `ls $RPM_BUILD_ROOT/%{_datadir}/gimp/%{subver}/tips/gimp*.[a-z]*.txt | sed "s@^$RPM_BUILD_ROOT/@@g"`; do tip_lang=`basename $I | cut -d'.' -f2` echo "%lang($tip_lang) $I" >> gimp-tips-files done # # Build the master filelists generated from the above mess. # cat gimp-plugin-files gimp-all.lang gimp-tips-files > gimp.files echo "%defattr (555, root, root, 555)" > gimp-perl-files cat gimp-perl gimp-perl-plugin-files >> gimp-perl-files cat gimp-perl.lang >> gimp-perl-files # install desktop entry mkdir -p %{buildroot}/%{_datadir}/applications mkdir -p %{buildroot}/%{_datadir}/mc/templates mkdir -p $RPM_BUILD_ROOT%{_datadir}/applications desktop-file-install \ --vendor gnome \ --dir $RPM_BUILD_ROOT%{_datadir}/applications \ --add-category "Application;Graphics;X-Red-Hat-Base" \ $RPM_SOURCE_DIR/gimp.desktop install -m 644 $RPM_SOURCE_DIR/gimp.desktop %{buildroot}/%{_datadir}/mc/templates mkdir -p %{buildroot}/usr/share/pixmaps install -m 644 $RPM_SOURCE_DIR/gimp.png %{buildroot}/%{_datadir}/pixmaps # files we don't ship rm -f %{buildroot}%{_bindir}/escputil* \ %{buildroot}%{_mandir}/man1/escputil* \ %{buildroot}%{_bindir}/embedxpm \ %{buildroot}%{_mandir}/man1/embedxpm* \ %{buildroot}%{_bindir}/scm2perl \ %{buildroot}%{_mandir}/man1/scm2perl* \ %{buildroot}%{_bindir}/scm2scm \ %{buildroot}%{_mandir}/man1/scm2scm* rm -rf %{buildroot}%{_datadir}/gimp/*/devel-docs find %{buildroot}%{_libdir}/perl5 -name perllocal.pod | xargs rm -f %clean [ -n "$RPM_BUILD_ROOT" -a "$RPM_BUILD_ROOT" != / ] && rm -rf $RPM_BUILD_ROOT %post -p /sbin/ldconfig %postun -p /sbin/ldconfig %files -f gimp.files %defattr (0644, root, root, 0755) %doc AUTHORS COPYING ChangeLog MAINTAINERS NEWS README TODO %doc docs/*.txt docs/*.ps ABOUT-NLS README.i18n README.perl README.win32 TODO %attr(-,root,root) %config(missingok) /%{_datadir}/applications/*.desktop %attr(-,root,root) %config(missingok) /%{_datadir}/mc/templates/gimp.desktop %{_datadir}/pixmaps/gimp.png %dir %{_datadir}/gimp/%{subver} %dir %{_datadir}/gimp/%{subver}/tips %dir %{_libdir}/gimp/%{subver} %dir %{_libdir}/gimp/%{subver}/modules %dir %{_libdir}/gimp/%{subver}/plug-ins %{_datadir}/gimp/%{subver}/brushes/ %{_datadir}/gimp/%{subver}/fractalexplorer/ %{_datadir}/gimp/%{subver}/gfig/ %{_datadir}/gimp/%{subver}/gflare/ %{_datadir}/gimp/%{subver}/gimpressionist/ %{_datadir}/gimp/%{subver}/gradients/ %{_datadir}/gimp/%{subver}/help/ %{_datadir}/gimp/%{subver}/palettes/ %{_datadir}/gimp/%{subver}/patterns/ %{_datadir}/gimp/%{subver}/scripts/ %{_sysconfdir}/gimp/%{subver}/gimprc %{_sysconfdir}/gimp/%{subver}/gimprc_user %{_sysconfdir}/gimp/%{subver}/gtkrc %{_sysconfdir}/gimp/%{subver}/gtkrc_user %{_sysconfdir}/gimp/%{subver}/unitrc %{_sysconfdir}/gimp/%{subver}/ps-menurc %{_datadir}/gimp/%{subver}/gimp_logo.ppm %{_datadir}/gimp/%{subver}/gimp_splash.ppm %defattr (0755, root, root) %{_datadir}/gimp/%{subver}/user_install %{_libdir}/libgimp-%{subver}.so.%{age}.0.%{microver} %{_libdir}/libgimp-%{subver}.so.%{age} %{_libdir}/libgimpui-%{subver}.so.%{age}.0.%{microver} %{_libdir}/libgimpui-%{subver}.so.%{age} %{_libdir}/libgck-%{subver}.so.%{age}.0.%{microver} %{_libdir}/libgck-%{subver}.so.%{age} %{_bindir}/gimp %{_bindir}/gimp-%{subver} %{_bindir}/gimp-remote* %defattr (0644, root, root) %{_mandir}/man1/gimp.1* %{_mandir}/man1/gimp-%{subver}.1* %{_mandir}/man5/gimprc.5* %{_mandir}/man5/gimprc-%{subver}.5* %{_mandir}/man1/gimp-remote* %files devel %defattr (0755, root, root, 0755) %{_bindir}/gimptool %{_bindir}/gimptool-%{subver} %{_bindir}/gimp-config %{_libdir}/*.so %{_libdir}/*.la %dir %{_libdir}/gimp/%{subver}/modules %{_libdir}/gimp/%{subver}/modules/*.la %defattr (0644, root, root, 0755) %{_datadir}/aclocal/gimp.m4 %{_libdir}/*.a %{_libdir}/gimp/%{subver}/modules/*.a %{_includedir}/libgimp/ %{_includedir}/gck/ %{_mandir}/man1/gimptool.1* %{_mandir}/man1/gimptool-%{subver}.1* %files perl -f gimp-perl-files %defattr (0755, root, root, 0755) %{_bindir}/gimpdoc %{_bindir}/xcftopnm %{_mandir}/man1/xcftopnm* %{_mandir}/man3/* %changelog * Wed Oct 15 2003 Matt Wilson 1:1.2.5-1 - 1.2.5 (#101225) * Sun Jun 8 2003 Tim Powers 1:1.2.3-20.1 - build for RHEL * Fri Jun 6 2003 Matt Wilson 1:1.2.3-20 - add epoch to the version requirements of subpackages - ship gimp-remote (#85344) * Wed Jun 04 2003 Elliot Lee - rebuilt * Wed Jun 4 2003 Than Ngo 1:1.2.3-18 - fix build problem with gcc 3.3 - workaround for compiler bug on s390/s390x * Wed Feb 19 2003 Tim Waugh 1:1.2.3-16 - Require gimp-print-plugin (bug #80437). * Wed Jan 22 2003 Tim Powers - rebuilt * Sat Jan 4 2003 Jeff Johnson 1:3-14 - use internal dep generator. * Sat Dec 14 2002 Tim Powers 1:3-13 - don't use rpms internal dep generator * Mon Dec 9 2002 Tim Powers 1:1.23-12 - rebuild to pick up some plug-ins - add some BuildPreReq's on some perl packages for the gimp-perl package * Tue Nov 5 2002 Tim Waugh 1.2.3-11 - Don't ship the print plug-in. This comes from gimp-print instead. * Tue Nov 5 2002 Tim Waugh 1.2.3-10 - Use %%{_libdir}. - Don't use previously-installed gimptool when building. - Build requires glib-devel. - Don't install files not shipped. - Clean up doc files in manifest. - Ship more translations. - Ship xcftopnm man page, and gimp-perl man pages. * Fri Aug 30 2002 Tim Powers - filter out gimp-perl dep on perl(PDL::LiteF) * Fri Aug 30 2002 Matt Wilson - use desktop-file-install - nuke rpath in perl plugin * Mon Aug 19 2002 Matt Wilson - fix up gimp-perl madness to work with 5.8.0 (#66610, #68782) - added gimp-1.2.3-newperl.patch.bz2 from Mandrake's gimp package - added gimp-1.2.3-wget-fix.patch.bz2 from Mandrake's gimp package - fix desktop file (#71021) * Thu May 23 2002 Tim Powers - automated rebuild * Mon Apr 15 2002 Matt Wilson - filter .la files from main gimp package (#43317, #57571, #56667, #51591, #63371) * Tue Mar 19 2002 Matt Wilson - added missing man pages (#61426) - removed esputil man page (#58919) * Fri Mar 15 2002 Matt Wilson - added /usr/bin/{gimp-config,gimptool}-1.2 * Mon Mar 11 2002 Matt Wilson - 1.2.3, based on changes from Ed Halley below: - removed gimp-1.2.1-locale.patch as the patch was incorporated upstream - linked new versioned gimp-1.2 executable to traditional gimp name * Mon Feb 25 2002 Than Ngo 1.2.1-11 - rebuild in new enviroment * Thu Jan 31 2002 Bill Nottingham - escputil lives in ghostscript now * Thu Jan 31 2002 Jeremy Katz - add silly perl dependencies that don't get automatically found * Wed Jan 30 2002 Jeremy Katz - rebuild in new environment * Thu Jul 19 2001 Tim Powers - remove the perl temp files to pacify rpmlint * Tue Jun 19 2001 Matt Wilson - added versioned requires to gimp-devel and gimp-perl * Tue Apr 3 2001 Matt Wilson - added gimp-1.2.1-locale.patch, which I've checked in to gimp CVS, to correctly set up the locale in plug-ins (#34214) * Mon Apr 2 2001 Preston Brown - some gimp-perl files weren't defattr'd (#34325) * Fri Mar 30 2001 Trond Eivind Glomsrød - Don't include embedxpm, as it depends on a non-included perl module (#=33249) - move gimpdoc and xcftopnm to gimp-perl, as they are dependant on the perl Gimp module * Thu Mar 01 2001 Owen Taylor - Rebuild for GTK+-1.2.9 include paths * Mon Jan 22 2001 Matt Wilson - 1.2.1 * Mon Dec 25 2000 Matt Wilson - 1.2.0 * Wed Dec 20 2000 Matt Wilson - 1.1.31 * Thu Dec 14 2000 Matt Wilson - 1.1.30 - merge changes from CVS into rpm-4.0 style spec file - removed va_arg patch * Mon Aug 21 2000 Matt Wilson - 1.1.25 * Fri Aug 11 2000 Jonathan Blandford - Up Epoch and release * Tue Aug 8 2000 Matt Wilson - fixed directory mode on %%{_defaultdocdir}/gimp-%%{version} * Wed Aug 2 2000 Matt Wilson - rebuild against new libpng * Mon Jul 31 2000 Matt Wilson - muck with modules filelist generation to avoid getting files owned by two packages * Mon Jul 17 2000 Matt Wilson - disable aa plugin - moved the group back to Applications/Multimedia - added desktop entry back into the file list * Thu Jul 13 2000 Prospector - automatic rebuild * Fri Jul 1 2000 Matt Wilson - 1.1.24 * Sat Jun 17 2000 Matt Wilson - use root, not bin for the default owner. * Fri Jun 16 2000 Preston Brown - add back missing system .desktop entry * Sat Jun 10 2000 Matt Wilson - rebuilt against fixed gcc * Mon Jun 5 2000 Matt Wilson - defattr for gimp-perl * Sun Jun 4 2000 Matt Wilson - drop out all of \.a$ from the main package list * Sat Jun 3 2000 Matt Wilson - 1.1.23 - use __NO_MATH_INLINES for now on ix86 - massive FHS surgery * Tue May 16 2000 Matt Wilson - 1.1.22 * Mon Apr 24 2000 Matt Wilson - 1.1.20 * Fri Apr 14 2000 Matt Wilson - include subdirs in the help find - remove gimp-help-files generation - both gimp and gimp-perl own prefix/lib/gimp/1.1/plug-ins - both gimp and gimp-devel own prefix/lib/gimp/1.1/modules * Thu Apr 13 2000 Matt Wilson - 1.1.19 - get all .mo files * Wed Jan 19 2000 Gregory McLean - Version 1.1.15 * Wed Dec 22 1999 Gregory McLean - Version 1.1.14 - Added some auto %files section generation scriptlets