/[packages]/cauldron/xulrunner/current/SPECS/xulrunner.spec
ViewVC logotype

Annotation of /cauldron/xulrunner/current/SPECS/xulrunner.spec

Parent Directory Parent Directory | Revision Log Revision Log


Revision 47731 - (hide annotations) (download)
Sun Feb 6 16:20:19 2011 UTC (10 years, 8 months ago) by ahmad
File size: 13275 byte(s)
- remove pref("layout.css.visited_links_enabled", false); , the most scary/big parts
  have been fixed upstream ages ago, and this option isn't disabled by default upstream
  c.f.:
  http://dbaron.org/mozilla/visited-privacy
  https://bugzilla.mozilla.org/show_bug.cgi?id=147777

1 dmorgan 18113 #
2     # WARNING, READ FIRST:
3     #
4     # This is a special package that needs special treatment. Due to the amount of
5     # security updates it needs, it's common to ship new upstream versions instead of patching.
6     # That means this package MUST be BUILDABLE for stable official releases.
7     # This also means only STABLE upstream releases, NO betas.
8     # This is a discussed topic. Please, do not flame it again.
9    
10     # (tpg) DO NOT FORGET TO SET EXACT XULRUNNER and FIREFOX VERSIONS !
11     %define ffver 4.0
12     %define version_internal 2.0
13    
14 erwan 42315 %define prel b10
15 dmorgan 18113
16     # (tpg) define release here
17 dmorgan 18121 #if %mageia_branch == Cauldron
18     # Cauldron
19 ahmad 47731 %define release %mkrel -c %prel 4
20 dmorgan 18121 #else
21 dmorgan 18113 # Old distros
22 dmorgan 18121 #define subrel 1
23     #define release %mkrel 0
24     #endif
25 dmorgan 18113
26     # (tpg) DO NOT FORGET TO SET EXACT MAJOR!
27     # in this case %{major} == %{version_internal}
28     %define major %{version_internal}
29     %define libname %mklibname %{name} %{major}
30     %define develname %mklibname %{name} -d
31     %define develunstname %mklibname %{name}-unstable -d
32     %define sname firefox
33    
34     # (tpg) various directory defines
35     %define mozappdir %{_libdir}/%{name}-%{version_internal}
36    
37     %define nss_libname %mklibname nss 3
38     %define nspr_libname %mklibname nspr 4
39    
40     # this seems fragile, so require the exact version or later (#58754)
41     %define sqlite3_version %(pkg-config --modversion sqlite3 &>/dev/null && pkg-config --modversion sqlite3 2>/dev/null || echo 0)
42     %define nss_version %(pkg-config --modversion nss &>/dev/null && pkg-config --modversion nss 2>/dev/null || echo 0)
43    
44     %define _use_syshunspell 1
45    
46     Summary: XUL Runtime for Gecko Applications
47     Name: xulrunner
48     Version: %{version_internal}
49     Release: %{release}
50     License: MPLv1.1 or GPLv2+ or LGPLv2+
51     Group: Development/Other
52     Url: http://developer.mozilla.org/en/docs/XULRunner
53     Source0: ftp://ftp.mozilla.org/pub/mozilla.org/%{sname}/releases/%{ffver}/source/%{sname}-%{ffver}%prel.source.tar.bz2
54     Source1: %{SOURCE0}.asc
55     Patch1: xulrunner-1.9.1-max-path-len.patch
56     Patch5: mozilla-nongnome-proxies.patch
57     Patch7: %{name}-1.9.1-pluginsdir2.patch
58     # Fedora patches:
59     # use 1.9 as xulrunner version in the dirname and not the complete version string
60     Patch8: xulrunner-1.9.0.1-version.patch
61     Patch9: xulrunner-ipc-stl.patch
62     Patch10: xulrunner-1.9.2-pkgconfig.patch
63     # (salem) this patch does not work properly on ff3
64     #Patch11: xulrunner-1.9.0.1-theme-selection.patch
65     Patch12: xulrunner-1.9.0.5-fix-string-format.patch
66     Patch14: xulrunner-1.9.1-jemalloc.patch
67     Patch15: xulrunner-1.9.1-gtk2.patch
68     Patch16: xulrunner-1.9.1-java-make-j1.patch
69     Patch17: xulrunner-1.9.2-public-opearator-delete.patch
70     Patch19: xulrunner-1.9.2-fix-plugins-cflags.patch
71     Patch20: xulrunner-1.9.2-helper-app.patch
72     Patch21: xulrunner-1.9.2-kde-integration.patch
73     Patch25: xulrunner-1.9.2-realpath.patch
74     Patch26: mozilla-1.9.2-gtk2.diff
75 dmorgan 43415 Patch27: xulrunner-2.0b4-missing-linking-libraries.patch
76     # Patch from fedora: fix build
77     Patch28: xulrunner-2.0-system-cairo.patch
78     Patch29: xulrunner-2.0-system-cairo-tee.patch
79     Patch30: xulrunner-2.0-os2cc.patch
80    
81 dmorgan 18113 BuildRequires: zlib-devel
82     BuildRequires: bzip2-devel
83 dmorgan 43417 #(Dmorgan) Enable when libpng >= 1.4.1 will be in mageia
84     #BuildRequires: libpng-devel >= 1.4.1
85 dmorgan 18113 %if %_use_syshunspell
86     BuildRequires: libhunspell-devel
87     %endif
88     BuildRequires: libIDL2-devel
89     BuildRequires: gtk+2-devel
90 dmorgan 43415 BuildRequires: libxt-devel
91     BuildRequires: libevent-devel
92 dmorgan 18113 BuildRequires: startup-notification-devel
93     BuildRequires: dbus-glib-devel
94 dmorgan 43415 BuildRequires: libsqlite3-devel >= 3.7.4
95     BuildRequires: autoconf2.1
96 dmorgan 18113 BuildRequires: libgnome-vfs2-devel
97     BuildRequires: libgnome2-devel
98     BuildRequires: libgnomeui2-devel
99     BuildRequires: java-rpmbuild
100     BuildRequires: java-1.5.0-devel
101     BuildRequires: zip
102     BuildRequires: doxygen
103     BuildRequires: makedepend
104     BuildRequires: valgrind
105     BuildRequires: rootcerts
106     BuildRequires: python
107     BuildRequires: nspr-devel >= 2:4.8.7
108 dmorgan 43416 BuildRequires: nss-static-devel >= 2:3.12.9
109 dmorgan 18113 BuildRequires: pango-devel
110     BuildRequires: libalsa-devel
111     BuildRequires: libnotify-devel
112     BuildRequires: mesagl-devel
113     BuildRequires: cairo-devel >= 1.8.8
114     BuildRequires: yasm
115     BuildRequires: libproxy-devel
116     Requires: %{libname} = %{version}-%{release}
117     Conflicts: xulrunner < %{version}
118     BuildRoot: %{_tmppath}/%{name}-%{version}-buildroot
119    
120     %description
121     XULRunner is a Mozilla runtime package that can be used to
122     bootstrap XUL+XPCOM applications that are as rich as Firefox
123     and Thunderbird. It will provide mechanisms for installing,
124     upgrading, and uninstalling these applications. XULRunner will
125     also provide libxul, a solution which allows the embedding of
126     Mozilla technologies in other projects and products.
127    
128     %package -n %{libname}
129     Summary: Dynamic libraries for %{name}
130     Group: System/Libraries
131     Requires: %{libname} = %{version}-%{release}
132     Conflicts: xulrunner < %{version}
133     Obsoletes: %{mklibname xulrunner 1.9.2} < %{version}-%{release}
134     Requires: rootcerts
135     # (tpg) manually pull dependancies on libnss3 and libnspr4, why ? see above
136     Requires: %{nss_libname} >= 2:%{nss_version}
137     Requires: %{nspr_libname} >= 2:4.8.7
138     # (salem) bug #42680 for noarch packages
139     Provides: libxulrunner = %{version}-%{release}
140     Requires: %{mklibname sqlite3_ 0} >= %{sqlite3_version}
141    
142     %description -n %{libname}
143     Dynamic libraries for %{name}.
144    
145     %package -n %{develname}
146     Summary: Development files for %{name}
147     Group: Development/Other
148     Requires: %{name} = %{version}-%{release}
149     Obsoletes: xulrunner-devel < 1.9.2
150     Obsoletes: %{mklibname mozilla-firefox -d} < 0:3
151     Obsoletes: %{mklibname %{name}-unstable -d}
152     Provides: %{name}-devel = %{version}-%{release}
153     # (tpg) see above why
154     Requires: nss-devel
155     Requires: libalsa-devel
156    
157     %description -n %{develname}
158     Development files and headers for %{name}.
159    
160     %prep
161     %setup -qn mozilla-central
162     #%patch1 -p1 -b .pathlen rediff
163     %patch5 -p0 -b .proxy
164     %patch7 -p1 -b .plugins
165     %patch8 -p1 -b .version
166    
167     #%patch10 -p1 -b .pkgconfig rediff
168     #%patch12 -p0 -b .strformat rediff
169     #%patch14 -p1 -b .jemalloc rediff
170     #%patch15 -p1 -b .gtk2
171     %patch16 -p1 -b .java_make-j1
172     %patch17 -p1
173     #%patch19 -p1 rediff
174     #%patch20 -p1 rediff
175     #%patch21 -p1 -b .kde-integration rediff?
176     %patch25 -p1
177    
178     %patch27 -p0
179 dmorgan 43415 %patch28 -p1
180     %patch29 -p1
181     %patch30 -p1
182 dmorgan 18113
183 dmorgan 43415 autoconf-2.13
184    
185 dmorgan 18113 # needed to regenerate certdata.c
186     pushd security/nss/lib/ckfw/builtins
187     perl ./certdata.perl < /etc/pki/tls/mozilla/certdata.txt
188     popd
189    
190     #(tpg) correct the xulrunner version
191     sed -i -e 's#INTERNAL_VERSION#%{version_internal}#g' xulrunner/installer/Makefile.in
192    
193     %build
194     %serverbuild
195     export PREFIX="%{_prefix}"
196     export LIBDIR="%{_libdir}"
197     export CFLAGS="$(echo %{optflags} | sed -e 's/-Wall//')"
198     export CXXFLAGS="$CFLAGS"
199     export LDFLAGS="%ldflags -Wl,-rpath,%{mozappdir}"
200    
201     # (tpg) don't use macro here
202 dmorgan 43415 # (fhimpe) Starting from Firefox 4.0b10, at least sqlite 3.6.4 is needed
203 dmorgan 18113 ./configure --build=%{_target_platform} \
204     --host=%_host --target=%_target_platform \
205     --prefix=%{_prefix} \
206     --bindir=%{_bindir} \
207     --libdir=%{_libdir} \
208     --includedir=%{_includedir} \
209     --datadir=%{_datadir} \
210     --sysconfdir=%{_sysconfdir} \
211     --enable-application=xulrunner \
212     --with-pthreads \
213     --with-system-jpeg \
214     --with-system-zlib \
215     --with-system-bz2 \
216 dmorgan 43415 --with-system-libevent \
217 dmorgan 43417 --without-system-png \
218 dmorgan 18113 --with-system-nspr \
219 dmorgan 43415 --with-system-nss \
220 dmorgan 18113 --enable-system-sqlite \
221     --enable-system-cairo \
222     %if %_use_syshunspell
223     --enable-system-hunspell \
224     %endif
225     --disable-javaxpcom \
226     --enable-pango \
227     --enable-svg \
228     --enable-canvas \
229     --enable-crypto \
230     --disable-crashreporter \
231     --disable-installer \
232     --disable-updater \
233     --enable-optimize \
234     --enable-jemalloc \
235     --disable-wrap-malloc \
236     --enable-valgrind \
237     --disable-strip \
238     --enable-install-strip \
239     --enable-startup-notification \
240     --enable-default-toolkit=cairo-gtk2 \
241     --enable-shared-js \
242     --with-java-include-path=%{java_home}/include \
243     --with-java-bin-path=%{java_home}/bin \
244     --enable-image-encoder=all \
245     --enable-image-decoders=all \
246     --enable-places \
247     --enable-storage \
248     --enable-safe-browsing \
249     --enable-url-classifier \
250     --enable-gnomevfs \
251     --enable-gnomeui \
252     --disable-faststart \
253     --enable-smil \
254     --disable-tree-freetype \
255     --enable-canvas3d \
256     --disable-coretext \
257     --enable-extensions=default \
258     --enable-necko-protocols=all \
259     --disable-necko-wifi \
260     --disable-tests \
261     --disable-mochitest \
262     --enable-xtf \
263     --enable-wave \
264     --enable-webm \
265     --enable-ogg \
266     --enable-xpcom-fastload \
267     --enable-gio \
268     --enable-dbus \
269     --enable-libproxy \
270 dmorgan 43415 --enable-chrome-format=jar \
271 blino 20086 --with-distribution-id=org.%{_vendor}
272 dmorgan 18113
273     %__perl -p -i -e 's|\-0|\-9|g' config/make-jars.pl
274    
275     # (tpg) on x86_64 fails when parallel compiling is on
276     # java.lang.OutOfMemoryError
277     # since 3.6 it does not
278     %make
279    
280     %install
281     rm -rf %{buildroot}
282    
283     %makeinstall_std
284    
285     #install -p dist/sdk/bin/regxpcom %{buildroot}%{mozappdir}
286    
287     rm -rf %{buildroot}%{_libdir}/%{name}-devel-%{version_internal}/sdk/lib/*.so
288     pushd %{buildroot}%{mozappdir}
289     for i in *.so; do
290     ln -s %{mozappdir}/$i %{buildroot}%{_libdir}/%{name}-devel-%{version_internal}/sdk/lib/$i
291     done
292     popd
293    
294     # GRE stuff
295     %ifarch x86_64 ia64 ppc64 s390x
296     %define gre_conf_file %{version_internal}-64.system.conf
297     mv %{buildroot}%{_sysconfdir}/gre.d/*.system.conf %{buildroot}%{_sysconfdir}/gre.d/%{gre_conf_file}
298     %else
299     %define gre_conf_file %{version_internal}.system.conf
300     %endif
301    
302     # Don't install these in appdir
303     rm %{buildroot}%{mozappdir}/LICENSE
304     rm %{buildroot}%{mozappdir}/README.txt
305    
306     # when not building with system nspr:
307     #rm -f %{buildroot}%_libdir/xulrunner-2.0/nspr-config
308    
309     %if %_use_syshunspell
310     # Use the system hunspell dictionaries
311     rm -rf %{buildroot}%{mozappdir}/dictionaries
312     ln -s %{_datadir}/dict/mozilla %{buildroot}%{mozappdir}/dictionaries
313     %endif
314    
315     # ghost files
316     mkdir -p %{buildroot}%{mozappdir}/components
317     touch %{buildroot}%{mozappdir}/components/compreg.dat
318     touch %{buildroot}%{mozappdir}/components/xpti.dat
319    
320     # set up our default preferences
321     cat << EOF > %{buildroot}%{mozappdir}/defaults/pref/vendor.js
322     pref("general.useragent.vendor", "%{distribution}");
323     pref("general.useragent.vendorSub", "%{version}-%{release}");
324 blino 20083 pref("general.useragent.vendorComment", "%{product_release}");
325 dmorgan 18113 pref("general.smoothScroll", true);
326     pref("mousewheel.horizscroll.withnokey.action", 0);
327     pref("mousewheel.horizscroll.withnokey.numlines", 3);
328     pref("mousewheel.horizscroll.withnokey.sysnumlines", false);
329     pref("mousewheel.withnokey.action", 0);
330     pref("mousewheel.withnokey.numlines", 7);
331     pref("mousewheel.withnokey.sysnumlines", false);
332     pref("network.protocol-handler.app.mailto", "/usr/bin/xdg-email");
333     pref("network.protocol-handler.app.mms", "/usr/bin/xdg-open");
334     pref("network.http.pipelining", true);
335     pref("network.http.proxy.pipelining", true);
336     pref("network.http.pipelining.maxrequests", 8);
337     pref("browser.display.use_system_colors", true);
338     pref("browser.tabs.loadDivertedInBackground", true);
339     pref("browser.startup.homepage_override.mstone", "ignore");
340     pref("browser.backspace_action", 2);
341     pref("browser.tabs.loadFolderAndReplace", false);
342     pref("browser.EULA.override", true);
343     pref("browser.safebrowsing.enabled", true);
344     pref("browser.shell.checkDefaultBrowser", false);
345     pref("browser.startup.homepage", "file:///usr/share/doc/HTML/index.html");
346     pref("browser.ctrlTab.previews", true);
347     pref("browser.tabs.insertRelatedAfterCurrent", false);
348     pref("print.print_edge_top", 14); // 1/100 of an inch
349     pref("print.print_edge_left", 16); // 1/100 of an inch
350     pref("print.print_edge_right", 16); // 1/100 of an inch
351     pref("print.print_edge_bottom", 14); // 1/100 of an inch
352     pref("app.update.enabled", false);
353     pref("app.update.auto", false);
354     pref("app.update.autoInstallEnabled", false);
355     pref("intl.locale.matchOS", true);
356     pref("toolkit.storage.synchronous", 0);
357     pref("security.ssl.require_safe_negotiation", false);
358     EOF
359    
360     %find_lang %{name}
361    
362     mkdir -p %{buildroot}%{_sys_macros_dir}
363     cat <<FIN >%{buildroot}%{_sys_macros_dir}/%{name}.macros
364     # Macros from %{name} package
365     %%xulrunner_major %{major}
366     %%xulrunner_version %{version}
367     %%xulrunner_libname %{libname}
368     %%xulrunner_mozappdir %{mozappdir}
369     FIN
370    
371     %clean
372     rm -rf %{buildroot}
373    
374     %files
375     %defattr(-,root,root)
376     %doc LICENSE README.txt
377     %dir %{mozappdir}
378     %{_bindir}/xulrunner
379    
380     %files -n %{libname}
381     %defattr(-,root,root)
382     %dir %{mozappdir}
383     %{mozappdir}/chrome
384     %{mozappdir}/dictionaries
385     %dir %{mozappdir}/components
386     %ghost %{mozappdir}/components/compreg.dat
387     %ghost %{mozappdir}/components/xpti.dat
388     %{mozappdir}/components/*.so
389     %{mozappdir}/components/*.xpt
390     %{mozappdir}/components/*.manifest
391     %{mozappdir}/*.manifest
392     %attr(644, root, root) %{mozappdir}/components/*.js
393     %{mozappdir}/defaults
394     #%{mozappdir}/greprefs
395     %dir %{mozappdir}/icons
396     %attr(644, root, root) %{mozappdir}/icons/*
397     %{mozappdir}/modules
398     %{mozappdir}/plugins
399     %{mozappdir}/res
400     %{mozappdir}/*.so
401     %{mozappdir}/mozilla-xremote-client
402     %{mozappdir}/run-mozilla.sh
403     #%{mozappdir}/regxpcom
404     %{mozappdir}/greprefs.js
405 dmorgan 43415 #%{mozappdir}/*.chk
406 dmorgan 18113 %{mozappdir}/xulrunner
407     %{mozappdir}/xulrunner-bin
408     %{mozappdir}/xulrunner-stub
409     %{mozappdir}/platform.ini
410     %{mozappdir}/dependentlibs.list
411     #%{mozappdir}/javaxpcom.jar
412     %{mozappdir}/plugin-container
413     %dir %{_sysconfdir}/gre.d
414     %{_sysconfdir}/gre.d/*.conf
415    
416     %files -n %{develname}
417     %defattr(-,root,root)
418     %{_includedir}/%{name}-%{version_internal}
419     %{mozappdir}/xpcshell
420     %{mozappdir}/xpidl
421     %{mozappdir}/xpt_dump
422     %{mozappdir}/xpt_link
423     %{_libdir}/%{name}-devel-%{version_internal}
424     %{_libdir}/pkgconfig/*.pc
425     %{_datadir}/idl/%{name}-%{version_internal}
426     %{_sys_macros_dir}/%{name}.macros
427    
428    

  ViewVC Help
Powered by ViewVC 1.1.28