rpms/gimp/devel gimp.spec,1.153,1.154
Nils Philippsen (nphilipp)
fedora-extras-commits at redhat.com
Mon Jan 28 11:19:18 UTC 2008
Author: nphilipp
Update of /cvs/pkgs/rpms/gimp/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv28734
Modified Files:
gimp.spec
Log Message:
don't package static libraries (#430330)
use %bcond_... macros for package options
Index: gimp.spec
===================================================================
RCS file: /cvs/pkgs/rpms/gimp/devel/gimp.spec,v
retrieving revision 1.153
retrieving revision 1.154
diff -u -r1.153 -r1.154
--- gimp.spec 17 Dec 2007 09:40:37 -0000 1.153
+++ gimp.spec 28 Jan 2008 11:18:40 -0000 1.154
@@ -2,7 +2,7 @@
# Use the following --with/--without <option> switches to control how the
# package will be built:
#
-# modular_x: modular X deps
+# modular_x: modular X dependencies
# lcms: lcms support
# python: python support
# mp: multi processor support
@@ -13,31 +13,31 @@
# convenience: install convenience symlinks
%if 0%{?fedora}%{?rhel} == 0 || 0%{?fedora} >= 5 || 0%{?rhel} >= 5
-%define _enable_modularX 0%{!?_without_modular_x:1}
-%define _enable_lcms 0%{!?_without_lcms:1}
+%bcond_without modular_x
+%bcond_without lcms
%else
-%define _enable_modularX 0%{?_with_modular_x:1}
-%define _enable_lcms 0%{?_with_lcms:1}
+%bcond_with modular_x
+%bcond_with lcms
%endif
%if 0%{?fedora}%{?rhel} == 0 || 0%{?fedora} >= 7 || 0%{?rhel} >= 6
-%define _enable_gutenprint 0%{!?_without_gutenprint:1}
-%define _enable_xdg_open 0%{!?_without_xdg_open:1}
+%bcond_without gutenprint
+%bcond_without xdg_open
%else
-%define _enable_gutenprint 0%{?_with_gutenprint:1}
-%define _enable_xdg_open 0%{?_with_xdg_open:1}
+%bcond_with gutenprint
+%bcond_with xdg_open
%endif
%if 0%{?fedora}%{?rhel} == 0 || 0%{?fedora} >= 8 || 0%{?rhel} >= 6
-%define _enable_print 0%{!?_without_print:1}
+%bcond_without print
%else
-%define _enable_print 0%{?_with_print:1}
+%bcond_with print
%endif
-%define _enable_python 0%{!?_without_python:1}
-%define _enable_mp 0%{!?_without_mp:1}
-%define _enable_static 0%{!?_without_static:1}
-%define _enable_convenience %{!?_without_convenience:1}
+%bcond_without python
+%bcond_without mp
+%bcond_without convenience
+%bcond_with static
#
#
@@ -51,7 +51,7 @@
%define age 0
%define minorver 400
%define microver %(ver=%{version}; echo ${ver##*.*.})
-Release: 1%{?dist}
+Release: 2%{?dist}
Epoch: 2
License: GPLv2+
Group: Applications/Multimedia
@@ -84,7 +84,7 @@
BuildRequires: python-devel
BuildRequires: pygtk2-devel >= 2.10.4
BuildRequires: pygobject2-devel
-%if %_enable_modularX
+%if %{with modular_x}
BuildRequires: libX11-devel
BuildRequires: libXmu-devel
%else
@@ -94,7 +94,7 @@
BuildRequires: intltool
BuildRequires: gettext
BuildRequires: findutils
-%if %_enable_lcms
+%if %{with lcms}
BuildRequires: lcms-devel
%endif
Requires: desktop-file-utils >= 0.9
@@ -103,8 +103,8 @@
Requires: pango >= 1.12.2
Requires: freetype >= 2.1.7
Requires: fontconfig >= 2.2.0
-%if ! %_enable_print
-%if %_enable_gutenprint
+%if ! %{with print}
+%if %{with gutenprint}
Requires: gutenprint-plugin
%else
Requires: gimp-print-plugin
@@ -113,7 +113,7 @@
Requires(post): /usr/bin/update-desktop-database
Requires(postun): /usr/bin/update-desktop-database
Requires: hicolor-icon-theme
-%if %_enable_xdg_open
+%if %{with xdg_open}
Requires: xdg-utils
%else
Requires: htmlview
@@ -161,25 +161,25 @@
cat << EOF
Build options:
-modular X: %_enable_modularX
-LCMS support: %_enable_lcms
-Python support: %_enable_python
-MP support: %_enable_mp
-build static libs: %_enable_static
-build internal print plugin: %_enable_print
-include convenience symlinks: %_enable_convenience
-build the print plugin: %_enable_print
-%if ! %_enable_print
+modular X: %{with modular_x}
+LCMS support: %{with lcms}
+Python support: %{with python}
+MP support: %{with mp}
+build static libs: %{with static}
+build internal print plugin: %{with print}
+include convenience symlinks: %{with convenience}
+build the print plugin: %{with print}
+%if ! %{with print}
prefer gutenprint over (external) gimp-print plugin:
- %_enable_gutenprint
+ %{with gutenprint}
%endif
-use xdg-open instead of htmlview: %_enable_xdg_open
+use xdg-open instead of htmlview: %{with xdg_open}
EOF
%setup -q -n gimp-%{version}
-%if %_enable_xdg_open
+%if %{with xdg_open}
%patch1 -p1 -b .xdg-open
%else
%patch0 -p1 -b .htmlview
@@ -193,27 +193,27 @@
CFLAGS="%optflags -fomit-frame-pointer" \
%configure \
--disable-perl \
-%if %_enable_python
+%if %{with python}
--enable-python \
%else
--disable-python \
%endif
-%if %_enable_mp
+%if %{with mp}
--enable-mp \
%else
--disable-mp \
%endif
-%if %_enable_static
+%if %{with static}
--enable-static \
%else
--disable-static \
%endif
-%if %_enable_print
+%if %{with print}
--with-print \
%else
--without-print \
%endif
-%if %_enable_lcms
+%if %{with lcms}
--with-lcms \
%else
--without-lcms \
@@ -247,7 +247,8 @@
# Plugins and modules change often (grab the executeable ones)
#
echo "%defattr (-, root, root)" > gimp-plugin-files
-find %{buildroot}%{_libdir}/gimp/%{interfacever} -type f | sed "s@^%{buildroot}@@g" | egrep -v 'modules/.*\.a$|modules/.*\.la$' >>gimp-plugin-files
+find %{buildroot}%{_libdir}/gimp/%{interfacever} -type f | sed "s@^%{buildroot}@@g" | grep -v '\.a$' >> gimp-plugin-files
+
# .pyc and .pyo files don't exist yet
grep "\.py$" gimp-plugin-files > gimp-plugin-files-py
for file in $(cat gimp-plugin-files-py); do
@@ -256,6 +257,11 @@
done
done >> gimp-plugin-files
+%if %{with static}
+echo "%defattr (-, root, root)" > gimp-static-files
+find %{buildroot}%{_libdir}/gimp/%{interfacever} -type f | sed "s@^%{buildroot}@@g" | grep '\.a$' >> gimp-static-files
+%endif
+
#
# Auto detect the lang files.
#
@@ -273,7 +279,7 @@
#
cat gimp-plugin-files gimp-all.lang > gimp.files
-%if %_enable_convenience
+%if %{with convenience}
# install convenience symlinks
ln -snf gimp-%{binver} %{buildroot}%{_bindir}/gimp
ln -snf gimp-%{binver}.1 %{buildroot}%{_mandir}/man1/gimp.1
@@ -380,7 +386,7 @@
%{_bindir}/gimp-console-%{binver}
%{_sbindir}/gimp-plugin-mgr
-%if %_enable_convenience
+%if %{with convenience}
%{_bindir}/gimp
%{_bindir}/gimp-remote
%{_bindir}/gimptool
@@ -393,7 +399,7 @@
%{_mandir}/man1/gimp-console-%{binver}.1*
%{_mandir}/man5/gimprc-%{binver}.5*
-%if %_enable_convenience
+%if %{with convenience}
%{_mandir}/man1/gimp.1*
%{_mandir}/man1/gimp-remote.1*
%{_mandir}/man1/gimptool.1*
@@ -425,17 +431,19 @@
%{_libdir}/libgimpwidgets-%{interfacever}.so.%{age}.%{minorver}.%{microver}
%{_libdir}/libgimpwidgets-%{interfacever}.so.%{age}
+%if %{with static}
+%files devel -f gimp-static-files
+%else
%files devel
+%endif
%defattr (-, root, root, 0755)
%doc HACKING README.i18n
%doc %{_datadir}/gtk-doc/*
%{_libdir}/*.so
-%{_libdir}/*.a
%dir %{_libdir}/gimp
%dir %{_libdir}/gimp/%{interfacever}
%dir %{_libdir}/gimp/%{interfacever}/modules
-%{_libdir}/gimp/%{interfacever}/modules/*.a
%ifnos linux
%{_libdir}/*.la
%{_libdir}/gimp/%{interfacever}/modules/*.la
@@ -445,6 +453,10 @@
%{_libdir}/pkgconfig/*
%changelog
+* Mon Jan 28 2008 Nils Philippsen <nphilipp at redhat.com> - 2:2.4.3-2
+- don't package static libraries (#430330)
+- use %%bcond_... macros for package options
+
* Mon Dec 17 2007 Nils Philippsen <nphilipp at redhat.com> - 2:2.4.3-1
- version 2.4.3
More information about the fedora-extras-commits
mailing list