/[packages]/updates/5/gimp/current/SPECS/gimp.spec
ViewVC logotype

Annotation of /updates/5/gimp/current/SPECS/gimp.spec

Parent Directory Parent Directory | Revision Log Revision Log


Revision 24845 - (hide annotations) (download)
Wed Jan 19 21:54:23 2011 UTC (13 years, 3 months ago) by ahmad
Original Path: cauldron/gimp/current/SPECS/gimp.spec
File size: 8565 byte(s)
- drop old/unneeded scriptlets
- use gtk-doc generic BR
SILENT: clean spec

1 ahmad 24820 %define name gimp
2     %define version 2.6.11
3 ahmad 24845 %define release %mkrel 4
4 ahmad 24820 %define lib_major 0
5    
6     # optional compile flags
7     %define enable_python 1
8     %{?_without_python: %global enable_python 0}
9    
10     %define enable_lzw 0
11     %{?_with_lzw: %global enable_lzw 1}
12    
13     %define req_gtk_version 2.12.1
14    
15     %define api_version 2.0
16     %define abi_version 2.6
17     %define libname %mklibname %{name} %{api_version}_%{lib_major}
18     %define devlibname %mklibname -d %{name}%{api_version}
19    
20     Summary: The GNU Image Manipulation Program
21     Name: %name
22     Epoch: 1
23     Version: %{version}
24     Release: %{release}
25     License: GPLv2+
26     Group: Graphics
27     URL: http://www.gimp.org/
28     BuildRoot: %{_tmppath}/%{name}-%{version}-buildroot
29    
30     Source0: ftp://ftp.gimp.org/pub/gimp/v%{abi_version}/gimp-%version.tar.bz2
31     Source1: ftp://ftp.gimp.org/pub/gimp/v%{abi_version}/gimp-%version.tar.bz2.md5
32     Source13: gimp-scripting-sample.pl
33     Patch0: gimp-2.6.4-fix-str-fmt.patch
34     Patch1: gimp-2.6.4-fix-linking.patch
35     #gw fix name in desktop file and disable startup notification
36     Patch6: gimp-2.5.1-desktopentry.patch
37     BuildRequires: libxfixes-devel
38     BuildRequires: gegl-devel >= 0.0.18
39     BuildRequires: imagemagick
40     BuildRequires: aalib-devel
41 ahmad 24845 BuildRequires: gtk-doc >= 1.11-3
42 ahmad 24820 BuildRequires: libexif-devel
43     BuildRequires: libart_lgpl-devel
44     BuildRequires: libgtk+2.0-devel >= %{req_gtk_version}
45     BuildRequires: libgnomeui2-devel
46     BuildRequires: libalsa-devel
47     BuildRequires: libpoppler-glib-devel >= 0.4.1
48     BuildRequires: libmng-devel
49     BuildRequires: libpng-devel
50     BuildRequires: libtiff-devel
51     BuildRequires: perl
52     BuildRequires: xpm-devel
53     BuildRequires: librsvg-devel >= 2.14.0
54     BuildRequires: libxmu-devel
55     BuildRequires: intltool
56     # mail plugin
57     BuildRequires: sendmail-command
58     # help browser
59     BuildRequires: libwebkitgtk-devel
60     # print plugin
61     #BuildRequires: libgimpprint-devel >= 4.2.0
62     # python plugin
63     %if %enable_python
64     BuildRequires: pygtk2.0-devel >= 2.10.4
65     BuildRequires: python-devel
66     %endif
67     BuildRequires: automake
68     BuildRequires: lcms-devel
69     BuildRequires: libwmf-devel >= 0.2.8
70     BuildRequires: libhal-devel
71     BuildRequires: libxext-devel
72     BuildRequires: desktop-file-utils
73     Provides: gimp1_3 gimp2_0 gimp2_2 gimp2.6
74     Obsoletes: gimp1_3 gimp2_0 gimp2_2 gimp2.6
75     # workaround libgimp not bumping its major on API/ABI changes:
76     Requires: %{libname} = %epoch:%{version}
77     Requires(post): desktop-file-utils
78     Requires(postun): desktop-file-utils
79     Conflicts: perl-Gimp < 2.2
80     Conflicts: gutenprint-gimp2 < 5.0.1
81     Suggests: gimp-help-2
82    
83     %description
84     The GIMP is an image manipulation program suitable for photo retouching,
85     image composition and image authoring. Many people find it extremely useful
86     in creating logos and other graphics for web pages. The GIMP has many of the
87     tools and filters you would expect to find in similar commercial offerings,
88     and some interesting extras as well.
89    
90     The GIMP provides a large image manipulation toolbox, including channel
91     operations and layers, effects, sub-pixel imaging and anti-aliasing,
92     and conversions, all with multi-level undo.
93    
94     This version of The GIMP includes a scripting facility, but many of the
95     included scripts rely on fonts that we cannot distribute. The GIMP ftp
96     site has a package of fonts that you can install by yourself, which
97     includes all the fonts needed to run the included scripts. Some of the
98     fonts have unusual licensing requirements; all the licenses are documented
99     in the package. Get them in ftp://ftp.gimp.org/pub/gimp/fonts/ if you are so
100     inclined. Alternatively, choose fonts which exist on your system before
101     running the scripts.
102    
103     Build Options:
104     --without python Disable pygimp (default enabled)
105     --with lzw Enable LZW compression in GIF (default disabled)
106    
107     %package -n %{devlibname}
108     Summary: GIMP plugin and extension development kit
109     Group: Development/GNOME and GTK+
110     Requires: libgtk+2.0-devel >= %{req_gtk_version}
111     Epoch: 1
112     License: LGPLv2+
113     Requires: %{libname} = %epoch:%{version}
114     Provides: gimp-devel = %{version}-%{release}
115     Provides: gimp2.6-devel = %{version}-%{release}
116     Provides: libgimp-devel = %{version}-%{release}
117    
118     %description -n %{devlibname}
119     Static libraries and header files for writing GIMP plugins and extensions.
120    
121     %package -n %libname
122     Summary: GIMP libraries
123     Group: System/Libraries
124     Epoch: 1
125     License: LGPLv2+
126     Provides: libgimp%{api_version} = %{version}-%{release}
127     Obsoletes: %mklibname gimp 2.6_2.0_0
128    
129     %description -n %libname
130     This is the library that provides core GIMP functionality.
131     It enable other programs to use GIMP's features but is mainly intended
132     to be used by the GIMP and its "external" plugins.
133    
134     %package python
135     Summary: GIMP python extension
136     Group: Graphics
137     Epoch: 1
138     Requires: pygtk2.0
139     Obsoletes: gimp1_3-python, gimp2_0-python, gimp2_2-python
140    
141     %description python
142     This package contains the python modules for GIMP, which act as a
143     wrapper to libgimp allowing the writing of plug-ins for Gimp.
144     This is similar to script-fu, except that you can use the full set
145     of Python extension modules from the plug-in, and you write plug-in
146     in python instead of in scheme.
147    
148     %prep
149     %setup -q -n gimp-%version
150     %patch0 -p1 -b .fix-str-fmt
151     %patch1 -p1 -b .fix-linking
152     %patch6 -p1 -b .desktopentry
153    
154     #needed by patch1
155     autoreconf -fi -I m4macros
156    
157     %build
158    
159     %configure2_5x --enable-default-binary=yes \
160     --enable-mp=yes \
161     %if %enable_python
162     --enable-python=yes \
163     %else
164     --enable-python=no \
165     %endif
166     %if %enable_lzw
167     --with-gif-compression=lzw \
168     %else
169     --with-gif-compression=rle \
170     %endif
171     --enable-gtk-doc=yes
172    
173     %make
174    
175     %install
176 ahmad 24845 rm -fr %{buildroot}
177 ahmad 24820
178     %makeinstall_std
179    
180     #clean unpackaged files
181 ahmad 24845 rm -f %{buildroot}%{_libdir}/gimp/%{api_version}/*/*.a
182 ahmad 24820 find %buildroot -name \*la|xargs chmod 644
183    
184     # workaround broken help system
185 ahmad 24845 HELP_DIR=%{buildroot}%_datadir/gimp/%api_version/help/C
186 ahmad 24820 [[ -d $HELP_DIR ]] || mkdir -p $HELP_DIR
187     HELP_IDX=$HELP_DIR/introduction.html
188     echo -e '<HTML><HEAD><TITLE>GIMP Base Library</HEAD>\n<BODY><UL>' > $HELP_IDX
189    
190 ahmad 24845 /bin/ls %{buildroot}%_datadir/gtk-doc/html/*/index.html | sed -e "s@%{buildroot}@@g" >> $HELP_IDX
191 ahmad 24820 perl -pi -e 's!(.*/html/)([^/]*)(/index.html)!<LI><A HREF="\1\2\3">\2</A>!g' $HELP_IDX
192    
193     echo '</UL></BODY></HTML>' >> $HELP_IDX
194    
195     %find_lang gimp20 --all-name
196    
197     %if %enable_python
198     chmod 755 %buildroot%_libdir/gimp/%{api_version}/plug-ins/*.py
199     mkdir -p %{buildroot}%{_libdir}/python%{pyver}/site-packages
200     echo %_libdir/gimp/%{api_version}/python > %{buildroot}%{_libdir}/python%{pyver}/site-packages/gimp.pth
201     echo %_libdir/gimp/%{api_version}/plug-ins >> %{buildroot}%{_libdir}/python%{pyver}/site-packages/gimp.pth
202     %endif
203    
204     desktop-file-install --vendor="" \
205     --add-category="X-MandrivaLinux-CrossDesktop" \
206 ahmad 24845 --dir %{buildroot}%{_datadir}/applications %{buildroot}%{_datadir}/applications/*
207 ahmad 24820
208     %clean
209 ahmad 24845 rm -rf %{buildroot}
210 ahmad 24820
211     %files -f gimp20.lang
212     %defattr(-,root,root,0755)
213     %{_bindir}/gimp
214     %{_bindir}/gimp-%abi_version
215     %{_bindir}/gimp-console
216     %{_bindir}/gimp-console-%abi_version
217     %{_datadir}/applications/*
218     %{_datadir}/gimp
219     %dir %{_libdir}/gimp/%{api_version}
220     %dir %{_libdir}/gimp/%{api_version}/environ
221     %{_libdir}/gimp/%{api_version}/interpreters
222     %{_libdir}/gimp/%{api_version}/environ/default.env
223     %{_libdir}/gimp/%{api_version}/modules
224     %{_libdir}/gimp/%{api_version}/plug-ins
225     %exclude %{_libdir}/gimp/%{api_version}/plug-ins/*.py
226     %{_mandir}/man1/gimp*
227     %{_mandir}/man5/gimp*
228     %_datadir/icons/hicolor/*/apps/gimp.png
229     %_datadir/icons/hicolor/scalable/apps/gimp.svg
230     %config(noreplace) %{_sysconfdir}/gimp
231    
232     %doc AUTHORS NEWS README README.i18n docs/Wilber*
233    
234     %files -n %{devlibname}
235     %defattr(-,root,root,0755)
236     %doc ChangeLog
237     %doc %{_datadir}/gtk-doc/html/*
238     %{_bindir}/gimptool-*
239     %{_datadir}/aclocal/*.m4
240     %{_includedir}/*
241     %{_libdir}/lib*.la
242     %{_libdir}/lib*.so
243     %{_libdir}/pkgconfig/*
244     %{_mandir}/man1/gimptool-*
245    
246     %files -n %libname
247     %defattr(-,root,root,755)
248     # explicitly list all libs to avoid old libtool issue
249     %{_libdir}/libgimpconfig-%{api_version}.so.%{lib_major}*
250     %{_libdir}/libgimp-%{api_version}.so.%{lib_major}*
251     %{_libdir}/libgimpthumb-%{api_version}.so.%{lib_major}*
252     %{_libdir}/libgimpbase-%{api_version}.so.%{lib_major}*
253     %{_libdir}/libgimpcolor-%{api_version}.so.%{lib_major}*
254     %{_libdir}/libgimpmath-%{api_version}.so.%{lib_major}*
255     %{_libdir}/libgimpmodule-%{api_version}.so.%{lib_major}*
256     %{_libdir}/libgimpui-%{api_version}.so.%{lib_major}*
257     %{_libdir}/libgimpwidgets-%{api_version}.so.%{lib_major}*
258    
259     %if %enable_python
260     %files python
261     %defattr(-,root,root,755)
262     %{_libdir}/gimp/%{api_version}/environ/pygimp.env
263     %{_libdir}/gimp/%{api_version}/python
264     %{_libdir}/gimp/%{api_version}/plug-ins/*.py
265     %{_libdir}/python%{pyver}/site-packages/*.pth
266     %endif
267    
268    

  ViewVC Help
Powered by ViewVC 1.1.30