]> git.pld-linux.org Git - packages/thunderbird.git/blob - icedove.spec
- little update
[packages/thunderbird.git] / icedove.spec
1 #
2 # Conditional builds
3 %bcond_without  enigmail        # don't build enigmail - GPG/PGP support
4 %bcond_without  gnomeui         # disable gnomeui support
5 %bcond_without  gnomevfs        # disable GNOME comp. (gconf+libgnome+gnomevfs) and gnomevfs ext.
6 %bcond_without  gnome           # disable all GNOME components (gnome+gnomeui+gnomevfs)
7 %bcond_without  ldap            # disable e-mail address lookups in LDAP directories
8 #
9 %if %{without gnome}
10 %undefine       with_gnomeui
11 %undefine       with_gnomevfs
12 %endif
13 %define         enigmail_ver            1.0.0
14
15 Summary:        Icedove - email client
16 Summary(pl.UTF-8):      Icedove - klient poczty
17 Name:           icedove
18 Version:        3.0
19 Release:        0.1
20 License:        MPL 1.1 or GPL v2+ or LGPL v2.1+
21 Group:          Applications/Networking
22 Source0:        http://releases.mozilla.org/pub/mozilla.org/thunderbird/releases/%{version}/source/thunderbird-%{version}.source.tar.bz2
23 # Source0-md5:  9a564ac2489b1b0f9348dc298b913f6c
24 Source1:        http://www.mozilla-enigmail.org/download/source/enigmail-%{enigmail_ver}.tar.gz
25 # Source1-md5:  e3a6d379f1a72ac023751bdde2de750a
26 Source2:        %{name}-branding.tar.bz2
27 # Source2-md5:  e775b8cb658de32f30b403bc9b7950bf
28 Source3:        %{name}-rm_nonfree.sh
29 Source4:        %{name}.desktop
30 Source5:        %{name}.sh
31 Source6:        %{name}-enigmail.manifest
32 Patch0:         %{name}-branding.patch
33 Patch1:         %{name}-enigmail-shared.patch
34 Patch2:         %{name}-gcc.patch
35 Patch3:         %{name}-fonts.patch
36 Patch4:         %{name}-install.patch
37 Patch5:         %{name}-myspell.patch
38 Patch6:         %{name}-prefs.patch
39 Patch7:         %{name}-breakpad.patch
40 URL:            http://www.pld-linux.org/Packages/Icedove
41 %{?with_gnomevfs:BuildRequires: GConf2-devel >= 1.2.1}
42 BuildRequires:  automake
43 BuildRequires:  freetype-devel >= 1:2.1.8
44 %{?with_gnomevfs:BuildRequires: gnome-vfs2-devel >= 2.0}
45 BuildRequires:  gtk+2-devel >= 1:2.0.0
46 BuildRequires:  libIDL-devel >= 0.8.0
47 %{?with_gnomevfs:BuildRequires: libgnome-devel >= 2.0}
48 %{?with_gnomeui:BuildRequires:  libgnomeui-devel >= 2.2.0}
49 BuildRequires:  libjpeg-devel >= 6b
50 BuildRequires:  libpng-devel >= 1.2.0
51 BuildRequires:  libstdc++-devel
52 BuildRequires:  myspell-devel
53 BuildRequires:  nspr-devel >= 1:4.8
54 BuildRequires:  nss-devel >= 1:3.12.0
55 BuildRequires:  pango-devel >= 1:1.1.0
56 BuildRequires:  sed >= 4.0
57 BuildRequires:  xorg-lib-libXext-devel
58 BuildRequires:  xorg-lib-libXft-devel >= 2.1
59 BuildRequires:  xorg-lib-libXinerama-devel
60 BuildRequires:  xorg-lib-libXp-devel
61 BuildRequires:  xorg-lib-libXt-devel
62 Requires:       myspell-common
63 Requires:       nspr >= 1:4.6.1
64 Requires:       nss >= 1:3.11.3
65 Obsoletes:      mozilla-thunderbird
66 Obsoletes:      mozilla-thunderbird-dictionary-en-US
67 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
68
69 %define         filterout_cpp           -D_FORTIFY_SOURCE=[0-9]+
70
71 # iceweasel/icedove/iceape provide their own versions
72 %define         _noautoreqdep           libgfxpsshar.so libgkgfx.so libgtkxtbin.so libjsj.so libxpcom_compat.so libxpcom_core.so libxpistub.so
73 %define         _noautoprovfiles        %{_libdir}/%{name}/components
74 # we don't want these to satisfy xulrunner-devel
75 %define         _noautoprov             libgtkembedmoz.so libldap50.so libmozjs.so libprldap50.so libssldap50.so libxpcom.so libxul.so
76 # and as we don't provide them, don't require either
77 %define         _noautoreq              libgtkembedmoz.so libldap50.so libmozjs.so libprldap50.so libssldap50.so libxpcom.so libxul.so
78
79 %description
80 Icedove is an open-source,fast and portable email client.
81
82 %description -l pl.UTF-8
83 Icedove jest open sourcowym, szybkim i przenośnym klientem poczty.
84
85 %package addon-enigmail
86 Summary:        Extension for the authentication and encryption features provided by GnuPG
87 Summary(pl.UTF-8):      Rozszerzenie do uwierzytelniania i szyfrowania zapewnianego przez GnuPG
88 License:        MPL/LGPL
89 Group:          Applications/Networking
90 URL:            http://enigmail.mozdev.org/
91 Requires:       %{name} = %{version}-%{release}
92 Obsoletes:      mozilla-thunderbird-addon-enigmail
93
94 %description addon-enigmail
95 Enigmail is an extension to the Icedove mail client which allows users
96 to access the authentication and encryption features provided by
97 GnuPG.
98
99 Main Features:
100 - Encrypt/sign mail when sending, decrypt/authenticate received mail
101 - Support for inline-PGP (RFC 2440) and PGP/MIME (RFC 3156)
102 - Per-Account based encryption and signing defaults
103 - Per-Recipient rules for automated key selection, and
104   enabling/disabling encryption and signing
105 - OpenPGP key management interface
106
107 %description addon-enigmail -l pl.UTF-8
108 Enigmail to rozszerzenie klienta pocztowego Icedove pozwalające
109 użytkownikom na dostęp do uwierzytelniania i szyfrowania zapewnianego
110 przez GnuPG.
111
112 Główne możliwości:
113 - szyfrowanie/podpisywanie poczty przy wysyłaniu,
114   odszyfrowywanie/uwierzytelnianie poczty odebranej
115 - obsługa inline-PGP (RFC 2440) i PGP/MIME (RFC 3156)
116 - ustawienia domyślne szyfrowania i podpisywania dla każdego konta
117 - reguły automatycznego wyboru kluczy i włączenia szyfrowania oraz
118   podpisywania dla każdego adresata
119 - interfejs do zarządzania kluczami OpenPGP
120
121 %prep
122 %setup -q -c -a2
123 cd comm-1.9.1
124 %{?with_enigmail:tar xvfz %{SOURCE1} -C mailnews/extensions}
125 /bin/sh %{SOURCE3}
126 %patch0 -p1
127 %{?with_enigmail:%patch1 -p1}
128 %patch2 -p1
129 %patch3 -p1
130 %patch4 -p1
131 #%patch5 -p1
132 %patch6 -p0
133 %patch7 -p1
134
135 %build
136 cd comm-1.9.1
137 export CFLAGS="%{rpmcflags} `%{_bindir}/pkg-config mozilla-nspr --cflags-only-I`"
138 export CXXFLAGS="%{rpmcflags} `%{_bindir}/pkg-config mozilla-nspr --cflags-only-I`"
139
140 cp -f %{_datadir}/automake/config.* mozilla/build/autoconf
141 cp -f %{_datadir}/automake/config.* mozilla/nsprpub/build/autoconf
142 cp -f %{_datadir}/automake/config.* directory/c-sdk/config/autoconf
143
144 cat << 'EOF' > .mozconfig
145
146 mk_add_options MOZ_OBJDIR=@TOPSRCDIR@/obj-%{_target_cpu}
147
148 ac_add_options --prefix=%{_prefix}
149 ac_add_options --exec-prefix=%{_exec_prefix}
150 ac_add_options --bindir=%{_bindir}
151 ac_add_options --sbindir=%{_sbindir}
152 ac_add_options --sysconfdir=%{_sysconfdir}
153 ac_add_options --datadir=%{_datadir}
154 ac_add_options --includedir=%{_includedir}
155 ac_add_options --libdir=%{_libdir}
156 ac_add_options --libexecdir=%{_libexecdir}
157 ac_add_options --localstatedir=%{_localstatedir}
158 ac_add_options --sharedstatedir=%{_sharedstatedir}
159 ac_add_options --mandir=%{_mandir}
160 ac_add_options --infodir=%{_infodir}
161 %if %{?debug:1}0
162 ac_add_options --enable-debug
163 ac_add_options --enable-debug-modules
164 %else
165 ac_add_options --disable-debug
166 ac_add_options --disable-debug-modules
167 %endif
168 %if %{with tests}
169 ac_add_options --enable-tests
170 %else
171 ac_add_options --disable-tests
172 %endif
173 %if %{with gnomeui}
174 ac_add_options --enable-gnomeui
175 %else
176 ac_add_options --disable-gnomeui
177 %endif
178 %if %{with gnomevfs}
179 ac_add_options --enable-gnomevfs
180 %else
181 ac_add_options --disable-gnomevfs
182 %endif
183 %if %{with ldap}
184 ac_add_options --enable-ldap
185 %else
186 ac_add_options --disable-ldap
187 %endif
188 ac_add_options --enable-calendar
189 ac_add_options --disable-installer
190 ac_add_options --disable-jsd
191 ac_add_options --disable-xprint
192 ac_add_options --disable-permissions
193 ac_add_options --disable-pref-extensions
194 ac_add_options --enable-canvas
195 ac_add_options --enable-crypto
196 ac_add_options --enable-default-toolkit="gtk2"
197 ac_add_options --enable-mathml
198 ac_add_options --enable-optimize="%{rpmcflags}"
199 ac_add_options --enable-pango
200 ac_add_options --enable-reorder
201 ac_add_options --enable-static
202 ac_add_options --disable-strip
203 ac_add_options --disable-strip-libs
204 ac_add_options --enable-system-cairo
205 ac_add_options --enable-system-myspell
206 ac_add_options --enable-svg
207 ac_add_options --enable-xft
208 ac_add_options --enable-application=mail
209 ac_add_options --enable-default-toolkit=cairo-gtk2
210 ac_add_options --enable-xinerama
211 ac_add_options --with-system-jpeg
212 ac_add_options --with-system-nspr
213 ac_add_options --with-system-nss
214 ac_add_options --with-system-png
215 ac_add_options --with-system-zlib
216 ac_add_options --with-pthreads
217 ac_add_options --enable-single-profile
218 ac_add_options --disable-profilesharing
219 ac_add_options --with-distribution-id=org.pld-linux
220 #ac_add_options --with-branding=icedove/branding
221 ac_add_options --with-default-mozilla-five-home=%{_libdir}/%{name}
222 EOF
223
224 %{__make} -j1 -f client.mk build \
225         CC="%{__cc}" \
226         CXX="%{__cxx}"
227
228 %if %{with enigmail}
229         cd mailnews/extensions/enigmail
230         ./makemake -r
231         %{__make} -C ../../../obj-%{_target_cpu}/mailnews/extensions/enigmail
232 %endif
233
234 %install
235 rm -rf $RPM_BUILD_ROOT
236 install -d $RPM_BUILD_ROOT{%{_bindir},%{_libdir},%{_pixmapsdir},%{_desktopdir}} \
237                $RPM_BUILD_ROOT%{_datadir}/%{name}
238 install -d $RPM_BUILD_ROOT%{_libdir}/%{name}
239
240 cd comm-1.9.1
241 %{__make} -C obj-%{_target_cpu}/mail/installer stage-package \
242         DESTDIR=$RPM_BUILD_ROOT \
243         MOZ_PKG_APPDIR=%{_libdir}/%{name} \
244         PKG_SKIP_STRIP=1
245
246 # move arch independant ones to datadir
247 mv $RPM_BUILD_ROOT%{_libdir}/%{name}/chrome $RPM_BUILD_ROOT%{_datadir}/%{name}/chrome
248 mv $RPM_BUILD_ROOT%{_libdir}/%{name}/defaults $RPM_BUILD_ROOT%{_datadir}/%{name}/defaults
249 mv $RPM_BUILD_ROOT%{_libdir}/%{name}/greprefs $RPM_BUILD_ROOT%{_datadir}/%{name}/greprefs
250 mv $RPM_BUILD_ROOT%{_libdir}/%{name}/icons $RPM_BUILD_ROOT%{_datadir}/%{name}/icons
251 #mv $RPM_BUILD_ROOT%{_libdir}/%{name}/init.d $RPM_BUILD_ROOT%{_datadir}/%{name}/init.d
252 mv $RPM_BUILD_ROOT%{_libdir}/%{name}/isp $RPM_BUILD_ROOT%{_datadir}/%{name}/isp
253 mv $RPM_BUILD_ROOT%{_libdir}/%{name}/res $RPM_BUILD_ROOT%{_datadir}/%{name}/res
254 ln -s ../../share/%{name}/chrome $RPM_BUILD_ROOT%{_libdir}/%{name}/chrome
255 ln -s ../../share/%{name}/defaults $RPM_BUILD_ROOT%{_libdir}/%{name}/defaults
256 ln -s ../../share/%{name}/greprefs $RPM_BUILD_ROOT%{_libdir}/%{name}/greprefs
257 ln -s ../../share/%{name}/icons $RPM_BUILD_ROOT%{_libdir}/%{name}/icons
258 ln -s ../../share/%{name}/init.d $RPM_BUILD_ROOT%{_libdir}/%{name}/init.d
259 ln -s ../../share/%{name}/isp $RPM_BUILD_ROOT%{_libdir}/%{name}/isp
260 ln -s ../../share/%{name}/res $RPM_BUILD_ROOT%{_libdir}/%{name}/res
261
262 rm -rf $RPM_BUILD_ROOT%{_libdir}/%{name}/dictionaries
263 ln -s %{_datadir}/myspell $RPM_BUILD_ROOT%{_libdir}/%{name}/dictionaries
264
265 %{__sed} -e 's,@LIBDIR@,%{_libdir},' %{SOURCE5} > $RPM_BUILD_ROOT%{_bindir}/icedove
266 ln -s %{name} $RPM_BUILD_ROOT%{_bindir}/thunderbird
267 ln -s %{name} $RPM_BUILD_ROOT%{_bindir}/mozilla-thunderbird
268
269 install %{SOURCE4} $RPM_BUILD_ROOT%{_desktopdir}/%{name}.desktop
270
271 %if %{with enigmail}
272 _enig_dir=$RPM_BUILD_ROOT%{_libdir}/%{name}/extensions/\{847b3a00-7ab1-11d4-8f02-006008948af5\}
273 install -d $_enig_dir/chrome
274 install -d $_enig_dir/components
275 install -d $_enig_dir/defaults/preferences
276 mv -f $RPM_BUILD_ROOT%{_libdir}/%{name}/chrome/enigmail.jar $_enig_dir/chrome
277 #mv -f $RPM_BUILD_ROOT%{_libdir}/%{name}/chrome/enigmail-skin-seamonkey.jar $_enig_dir/chrome
278 mv -f $RPM_BUILD_ROOT%{_libdir}/%{name}/components/enig* $_enig_dir/components
279 mv -f $RPM_BUILD_ROOT%{_libdir}/%{name}/components/libenigmime.so $_enig_dir/components
280 #mv -f $RPM_BUILD_ROOT%{_libdir}/%{name}/components/libipc.so $_enig_dir/components
281 mv -f $RPM_BUILD_ROOT%{_libdir}/%{name}/components/ipc.xpt $_enig_dir/components
282 mv -f $RPM_BUILD_ROOT%{_libdir}/%{name}/defaults/preferences/enigmail.js $_enig_dir/defaults/preferences
283 cp -f mailnews/extensions/enigmail/package/install.rdf $_enig_dir
284 rm -rf $RPM_BUILD_ROOT%{_libdir}/%{name}/defaults/preferences
285 rm -f $RPM_BUILD_ROOT%{_libdir}/%{name}/chrome/enigmail-en-US.jar
286 rm -f $RPM_BUILD_ROOT%{_libdir}/%{name}/chrome/enigmail-skin.jar
287 rm -f $RPM_BUILD_ROOT%{_libdir}/%{name}/chrome/enigmime.jar
288 rm -rf $RPM_BUILD_ROOT%{_libdir}/%{name}/components/enig*
289 rm -f $RPM_BUILD_ROOT%{_libdir}/%{name}/components/libenigmime.so
290 rm -f $RPM_BUILD_ROOT%{_libdir}/%{name}/components/ipc.xpt
291 cp -f %{SOURCE6} $_enig_dir/chrome.manifest
292 #cp -f icedove/branding/content/icon64.png $RPM_BUILD_ROOT%{_pixmapsdir}/icedove.png
293 %endif
294
295 # win32 stuff
296 rm -f $RPM_BUILD_ROOT%{_libdir}/%{name}/dirver
297
298 %clean
299 rm -rf $RPM_BUILD_ROOT
300
301 %pretrans
302 if [ -d %{_libdir}/%{name}/dictionaries ] && [ ! -L %{_libdir}/%{name}/dictionaries ]; then
303         mv -v %{_libdir}/%{name}/dictionaries{,.rpmsave}
304 fi
305 for d in chrome defaults greprefs icons init.d isp res; do
306         if [ -d %{_libdir}/%{name}/$d ] && [ ! -L %{_libdir}/%{name}/$d ]; then
307                 install -d %{_datadir}/%{name}
308                 mv %{_libdir}/%{name}/$d %{_datadir}/%{name}/$d
309         fi
310 done
311 exit 0
312
313 %files
314 %defattr(644,root,root,755)
315 %attr(755,root,root) %{_bindir}/icedove
316 %attr(755,root,root) %{_bindir}/mozilla-thunderbird
317 %attr(755,root,root) %{_bindir}/thunderbird
318 %dir %{_libdir}/%{name}
319 %{_libdir}/%{name}/*.ini
320 %dir %{_libdir}/%{name}/components
321 %attr(755,root,root) %{_libdir}/%{name}/components/*.so
322 %{_libdir}/%{name}/components/*.js
323 %{_libdir}/%{name}/components/*.xpt
324 %attr(755,root,root) %{_libdir}/%{name}/*.so
325 %attr(755,root,root) %{_libdir}/%{name}/*.sh
326 %attr(755,root,root) %{_libdir}/%{name}/*-bin
327 %attr(755,root,root) %{_libdir}/%{name}/mozilla-xremote-client
328 #%attr(755,root,root) %{_libdir}/%{name}/reg*
329 #%attr(755,root,root) %{_libdir}/%{name}/icedove
330 %{_libdir}/%{name}/*.txt
331 #%attr(755,root,root) %{_libdir}/%{name}/x*
332
333 # symlinks
334 %{_libdir}/%{name}/chrome
335 %{_libdir}/%{name}/defaults
336 %{_libdir}/%{name}/dictionaries
337 %{_libdir}/%{name}/greprefs
338 %{_libdir}/%{name}/icons
339 %{_libdir}/%{name}/init.d
340 %{_libdir}/%{name}/isp
341 %{_libdir}/%{name}/res
342
343 %{_libdir}/%{name}/dependentlibs.list
344 %{_libdir}/%{name}/updater
345 %{_libdir}/%{name}/update.locale
346 #%{_pixmapsdir}/*.png
347 %{_desktopdir}/*.desktop
348
349 %dir %{_datadir}/%{name}
350 %{_datadir}/%{name}/chrome
351 %{_datadir}/%{name}/defaults
352 %{_datadir}/%{name}/greprefs
353 %{_datadir}/%{name}/icons
354 #%{_datadir}/%{name}/init.d
355 %{_datadir}/%{name}/isp
356 %{_datadir}/%{name}/res
357
358 %dir %{_libdir}/%{name}/modules
359 %{_libdir}/%{name}/modules/*.js*
360 %dir %{_libdir}/%{name}/modules/activity
361 %{_libdir}/%{name}/modules/activity/*.js
362 %dir %{_libdir}/%{name}/modules/gloda
363 %{_libdir}/%{name}/modules/gloda/*.js
364
365 %dir %{_libdir}/%{name}/extensions
366 %{_libdir}/%{name}/extensions/{972ce4c6-7e08-4474-a285-3208198ce6fd}
367
368 %if %{with enigmail}
369 %files addon-enigmail
370 %defattr(644,root,root,755)
371 %{_libdir}/%{name}/extensions/{847b3a00-7ab1-11d4-8f02-006008948af5}
372 %endif
This page took 0.157597 seconds and 4 git commands to generate.