source: xsoft/graphweb/firefox.xml@ 581df7e

10.0 10.1 11.0 11.1 7.10 8.0 8.1 8.2 8.3 8.4 9.0 9.1 basic bdubbs/svn elogind lazarus nosym perl-modules qt5new trunk upgradedb xry111/intltool xry111/test-20220226
Last change on this file since 581df7e was 581df7e, checked in by Chris Staub <chris@…>, 6 years ago

YouTube now defaults to using HTML5 if available

git-svn-id: svn://svn.linuxfromscratch.org/BLFS/trunk/BOOK@17497 af4574ff-66df-0310-9fd7-8a98e5e911e0

  • Property mode set to 100644
File size: 15.5 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6
7 <!ENTITY firefox-download-http "&mozilla-http;/firefox/releases/&firefox-version;/source/firefox-&firefox-version;.source.tar.xz">
8 <!ENTITY firefox-download-ftp " ">
9 <!ENTITY firefox-md5sum "0bd5991a6c821dd1a34ead0f8bbb301a ">
10 <!ENTITY firefox-size "180 MB">
11 <!ENTITY firefox-buildsize "5.3 GB (85 MB installed)">
12 <!ENTITY firefox-time "11.3 SBU (with parallelism=4 on a recent intel i7, much longer on lesser CPUs)">
13]>
14
15<sect1 id="firefox" xreflabel="Firefox-&firefox-version;">
16 <?dbhtml filename="firefox.html" ?>
17
18 <sect1info>
19 <othername>$LastChangedBy$</othername>
20 <date>$Date$</date>
21 </sect1info>
22
23 <title>Firefox-&firefox-version;</title>
24
25 <indexterm zone="firefox">
26 <primary sortas="a-Firefox">Firefox</primary>
27 </indexterm>
28
29 <sect2 role="package">
30 <title>Introduction to Firefox</title>
31
32 <para>
33 <application>Firefox</application> is a stand-alone browser based on the
34 <application>Mozilla</application> codebase.
35 </para>
36
37 &lfs79_checked;&gcc6_checked;
38
39 <bridgehead renderas="sect3">Package Information</bridgehead>
40 <itemizedlist spacing="compact">
41 <listitem>
42 <para>
43 Download (HTTP): <ulink url="&firefox-download-http;"/>
44 </para>
45 </listitem>
46 <listitem>
47 <para>
48 Download (FTP): <ulink url="&firefox-download-ftp;"/>
49 </para>
50 </listitem>
51 <listitem>
52 <para>
53 Download MD5 sum: &firefox-md5sum;
54 </para>
55 </listitem>
56 <listitem>
57 <para>
58 Download size: &firefox-size;
59 </para>
60 </listitem>
61 <listitem>
62 <para>
63 Estimated disk space required: &firefox-buildsize;
64 </para>
65 </listitem>
66 <listitem>
67 <para>
68 Estimated build time: &firefox-time;
69 </para>
70 </listitem>
71 </itemizedlist>
72
73 <bridgehead renderas="sect3">Additional Downloads</bridgehead>
74 <itemizedlist spacing="compact">
75 <listitem>
76 <para>
77 Required patch if using gtk+-3.20 or later (do not use with earlier versions)
78 <ulink url="&patch-root;/firefox-&firefox-version;-gtk320-1.patch"/>
79 </para>
80 </listitem>
81 <listitem>
82 <para>
83 Optional patch to allow system versions of <xref linkend="graphite2"/>
84 and <xref linkend="harfbuzz"/> - this should be regarded as experimental
85 <ulink url="&patch-root;/firefox-&firefox-version;-system_graphite2_harfbuzz-1.patch"/>
86 </para>
87 </listitem>
88 </itemizedlist>
89
90 <note>
91 <para>
92 The tarball <emphasis>firefox-&firefox-version;.source.tar.xz</emphasis>
93 will untar to <emphasis>firefox-&firefox-version;</emphasis> directory.
94 </para>
95 </note>
96
97 <bridgehead renderas="sect3">Firefox Dependencies</bridgehead>
98
99 <bridgehead renderas="sect4">Required</bridgehead>
100 <para role="required">
101 <xref linkend="alsa-lib"/>,
102 <xref linkend="autoconf213"/>,
103 <xref linkend="gtk3"/>
104 (or <xref linkend="gtk2"/> if you change the mozconfig where indicated),
105 <xref linkend="nss"/>,
106 <xref linkend="unzip"/>,
107 <xref linkend="yasm"/>, and
108 <xref linkend="zip"/>
109 </para>
110
111 <bridgehead renderas="sect4">Recommended</bridgehead>
112 <para role="recommended">
113 <xref linkend="icu"/>,
114 <xref linkend="libevent"/>,
115 <xref linkend="libvpx"/>, and
116 <xref linkend="sqlite"/>
117 </para>
118
119 <note>
120 <para>
121 If you don't install recommended dependencies, then internal copies of
122 those packages will be used. They might be tested to work, but they can
123 be out of date or contain security holes.
124 </para>
125 </note>
126
127 <note>
128 <para>
129 With <application>Firefox-31.0</application> and later versions, you
130 must have installed <application>Openssl</application> before
131 <application>Python 2</application> or the build system will quickly
132 fail with output including "ImportError: cannot import name
133 HTTPSHandler". If you are in any doubt about this (e.g. upgrading from
134 an older version of Firefox), check if
135 <filename>/usr/lib/python&python2-majorver;/lib-dynload/_ssl.so</filename>
136 exists. If it does not, reinstall <xref linkend="python2"/> (after
137 installing <xref linkend="openssl"/>). The latest version of any
138 <emphasis>currently maintained</emphasis> version of Openssl should be
139 satisfactory if already installed.
140 </para>
141 </note>
142
143 <bridgehead renderas="sect4">Optional</bridgehead>
144 <para role="optional">
145 <xref linkend="curl"/>,
146 <xref linkend="dbus-glib"/>,
147 <xref linkend="doxygen"/>,
148 <xref linkend="GConf"/>,
149 <xref linkend="ffmpeg"/> (runtime) or
150 <xref linkend="gst10-plugins-base"/> (with
151 <xref linkend="gst10-plugins-good"/> and
152 <xref linkend="gst10-libav"/> at runtime),
153 <xref linkend="libwebp"/>,
154 <xref linkend="openjdk"/>,
155 <xref linkend="pulseaudio"/>,
156 <xref linkend="startup-notification"/>,
157 <xref linkend="valgrind"/>,
158 <xref linkend="wget"/>,
159 <xref linkend="wireless_tools"/>,
160 <ulink url="https://hunspell.github.io/">Hunspell</ulink>,
161 <ulink url="http://sourceforge.net/projects/liboauth/files/">liboauth</ulink>, and
162 <ulink url="https://github.com/libproxy/libproxy">libproxy</ulink>,
163 <ulink url="https://www.rust-lang.org/">Rust</ulink>,
164 and (with the patch)
165 <xref linkend="graphite2"/> and
166 <xref linkend="harfbuzz"/>
167 </para>
168
169 <para condition="html" role="usernotes">
170 User Notes: <ulink url="&blfs-wiki;/firefox"/>
171 </para>
172 </sect2>
173
174 <sect2 role="installation">
175 <title>Installation of Firefox</title>
176
177 <para>
178 The configuration of <application>Firefox</application> is accomplished
179 by creating a <filename>mozconfig</filename> file containing the desired
180 configuration options. A default <filename>mozconfig</filename> is
181 created below. To see the entire list of available configuration options
182 (and an abbreviated description of each one), issue <command>./configure
183 --help</command>. You may also wish to review the entire file and
184 uncomment any other desired options. Create the file by issuing the
185 following command:
186 </para>
187
188<screen><userinput>cat &gt; mozconfig &lt;&lt; "EOF"
189<literal># If you have a multicore machine, all cores will be used by default.
190# If desired, you can reduce the number of cores used, e.g. to 1, by
191# uncommenting the next line and setting a valid number of CPU cores.
192#mk_add_options MOZ_MAKE_FLAGS="-j1"
193
194# If you have installed DBus-Glib comment out this line:
195ac_add_options --disable-dbus
196
197# If you have installed dbus-glib, and you have installed (or will install)
198# wireless-tools, and you wish to use geolocation web services, comment out
199# this line
200ac_add_options --disable-necko-wifi
201
202# GStreamer is necessary for H.264 video playback in HTML5 Video Player if
203# FFmpeg is not found at runtime;
204# to be enabled, also remember to set "media.gstreamer.enabled" to "true"
205# in about:config. If you have GStreamer 1.x.y, comment out this line and
206# uncomment the following one:
207ac_add_options --disable-gstreamer
208#ac_add_options --enable-gstreamer=1.0
209
210# Uncomment this option if you wish to build with gtk+-2
211#ac_add_options --enable-default-toolkit=cairo-gtk2
212
213# Uncomment these lines if you have installed optional dependencies:
214#ac_add_options --enable-system-hunspell
215#ac_add_options --enable-startup-notification
216
217# Comment out following option if you have PulseAudio installed
218ac_add_options --disable-pulseaudio
219
220# If you have installed GConf, comment out this line
221ac_add_options --disable-gconf
222
223# Comment out following options if you have not installed
224# recommended dependencies:
225ac_add_options --enable-system-sqlite
226ac_add_options --with-system-libevent
227ac_add_options --with-system-libvpx
228ac_add_options --with-system-nspr
229ac_add_options --with-system-nss
230ac_add_options --with-system-icu
231
232# If you are going to apply the patch for system graphite
233# and system harfbuzz, uncomment these lines:
234#ac_add_options --with-system-graphite2
235#ac_add_options --with-system-harfbuzz
236
237# Stripping is now enabled by default.
238# Uncomment these lines if you need to run a debugger:
239#ac_add_options --disable-strip
240#ac_add_options --disable-install-strip
241
242# The BLFS editors recommend not changing anything below this line:
243ac_add_options --prefix=/usr
244ac_add_options --enable-application=browser
245
246ac_add_options --disable-crashreporter
247ac_add_options --disable-updater
248ac_add_options --disable-tests
249
250ac_add_options --enable-optimize
251
252ac_add_options --enable-gio
253ac_add_options --enable-official-branding
254ac_add_options --enable-safe-browsing
255ac_add_options --enable-url-classifier
256
257# From firefox-40, using system cairo causes firefox to crash
258# frequently when it is doing background rendering in a tab.
259#ac_add_options --enable-system-cairo
260ac_add_options --enable-system-ffi
261ac_add_options --enable-system-pixman
262
263ac_add_options --with-pthreads
264
265ac_add_options --with-system-bz2
266ac_add_options --with-system-jpeg
267ac_add_options --with-system-png
268ac_add_options --with-system-zlib
269
270mk_add_options MOZ_OBJDIR=@TOPSRCDIR@/firefox-build-dir</literal>
271EOF</userinput></screen>
272
273 <para>
274 Compile <application>Firefox</application> by issuing the following
275 commands:
276 </para>
277
278 <para>
279 If you are using gtk+-3.20 or later, apply a patch to restore the
280 slider on scrollbars:
281 </para>
282
283<screen><userinput>patch -Np1 -i ../firefox-&firefox-version;-gtk320-1.patch</userinput></screen>
284
285 <para>
286 If you have installed system versions of graphite2 and harfbuzz and wish
287 firefox to use those instead of its shipped versions, apply the patch and
288 uncomment the appropriate entries in the <filename>mozconfig</filename>
289 file:
290 </para>
291
292<screen><userinput>patch -Np1 -i ../firefox-&firefox-version;-system_graphite2_harfbuzz-1.patch</userinput></screen>
293
294 <note><para>
295 If you are compiling <application>Firefox</application> in chroot, make
296 sure you have <envar>$SHELL</envar> environment variable set or prepend
297 <envar>SHELL=/bin/sh</envar>.
298 </para></note>
299
300<screen><userinput>sed -e '/#include/i\
301 print OUT "#define _GLIBCXX_INCLUDE_NEXT_C_HEADERS\\n"\;' \
302 -i nsprpub/config/make-system-wrappers.pl
303
304sed -e '/#include/a\
305 print OUT "#undef _GLIBCXX_INCLUDE_NEXT_C_HEADERS\\n"\;' \
306 -i nsprpub/config/make-system-wrappers.pl
307
308CFLAGS+=" -fno-delete-null-pointer-checks -fno-lifetime-dse -fno-schedule-insns2"
309CXXFLAGS+=" -fno-delete-null-pointer-checks -fno-lifetime-dse -fno-schedule-insns2"</userinput></screen>
310
311 <para>
312 This package does not come with a test suite.
313 </para>
314
315 <para>
316 Now, as the <systemitem class="username">root</systemitem> user:
317 </para>
318
319<screen role="root"><userinput>make -f client.mk install INSTALL_SDK= &amp;&amp;
320chown -R 0:0 /usr/lib/firefox-&firefox-version; &amp;&amp;
321
322mkdir -pv /usr/lib/mozilla/plugins &amp;&amp;
323ln -sfv ../../mozilla/plugins /usr/lib/firefox-&firefox-version;/browser</userinput></screen>
324
325 </sect2>
326
327 <sect2 role="commands">
328 <title>Command Explanations</title>
329
330 <para>
331 <command>sed ...</command>: These commands correct the source to be
332 compatible with gcc6 by preventing c++ scope errors.
333 </para>
334
335 <para>
336 <command>CFLAGS= ... CXXFLAGS= ...</command>: These settings work around
337 code which gcc6 would otherwise regard as out-of-specification and allow
338 it to produce a working program.
339 </para>
340
341 <para>
342 <command>make -f client.mk ...</command>: Mozilla products are packaged to
343 allow the use of a configuration file which can be used to pass the
344 configuration settings to the <command>configure</command> command.
345 <command>make</command> uses the <filename>client.mk</filename> file to
346 get initial configuration and setup parameters.
347 </para>
348
349 <para>
350 <command>mkdir -p /usr/lib/mozilla/plugins</command>: This checks
351 that <filename class="directory">/usr/lib/mozilla/plugins</filename>
352 exists.
353 </para>
354
355 <para>
356 <command>ln -sv ... /usr/lib/firefox-&firefox-version;/browser</command>:
357 This command creates a symbolic link to <filename
358 class="directory">/usr/lib/mozilla/plugins</filename>. It's not really
359 needed, as <application>Firefox</application> checks <filename
360 class="directory">/usr/lib/mozilla/plugins</filename> by default, but the
361 symbolic link is made to keep all the plugins installed in one folder.
362 </para>
363
364 </sect2>
365
366 <sect2 role="configuration">
367 <title>Configuring Firefox</title>
368
369 <para>
370 If you did not add the <option>--disable-webm</option> option to your
371 <filename>mozconfig</filename>, your <application>Firefox</application>
372 can play most YouTube videos without the need for the Flash plugin.
373 Go to <ulink url="http://www.youtube.com/html5"/> to see which HTML5
374 video features your browser supports on YouTube.
375 </para>
376
377 <para>
378 If you use a desktop environment like <application>Gnome</application> or
379 <application>KDE</application> you may like to create a
380 <filename>firefox.desktop</filename> file so that
381 <application>Firefox</application> appears in the panel's menus. If you
382 didn't enable startup-notification in your mozconfig change the
383 StartupNotify line to false. As the
384 <systemitem class="username">root</systemitem> user:
385 </para>
386
387<screen role="root"><userinput>mkdir -pv /usr/share/applications &amp;&amp;
388mkdir -pv /usr/share/pixmaps &amp;&amp;
389
390cat &gt; /usr/share/applications/firefox.desktop &lt;&lt; "EOF" &amp;&amp;
391<literal>[Desktop Entry]
392Encoding=UTF-8
393Name=Firefox Web Browser
394Comment=Browse the World Wide Web
395GenericName=Web Browser
396Exec=firefox %u
397Terminal=false
398Type=Application
399Icon=firefox
400Categories=GNOME;GTK;Network;WebBrowser;
401MimeType=text/html;text/xml;application/xhtml+xml;application/vnd.mozilla.xul+xml;text/mml;x-scheme-handler/http;x-scheme-handler/https;
402StartupNotify=true</literal>
403EOF
404
405ln -sfv /usr/lib/firefox-&firefox-version;/browser/icons/mozicon128.png \
406 /usr/share/pixmaps/firefox.png</userinput></screen>
407
408 </sect2>
409
410 <sect2 role="content">
411 <title>Contents</title>
412
413 <segmentedlist>
414 <segtitle>Installed Programs</segtitle>
415 <segtitle>Installed Libraries</segtitle>
416 <segtitle>Installed Directory</segtitle>
417
418 <seglistitem>
419 <seg>
420 firefox
421 </seg>
422 <seg>
423 Numerous libraries, browser components, plugins, extensions, and
424 helper modules installed in /usr/lib/firefox-&firefox-version;
425 </seg>
426 <seg>
427 /usr/lib/firefox-&firefox-version;
428 </seg>
429 </seglistitem>
430 </segmentedlist>
431
432 <variablelist>
433 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
434 <?dbfo list-presentation="list"?>
435 <?dbhtml list-presentation="table"?>
436
437 <varlistentry id="firefox-prog">
438 <term><command>firefox</command></term>
439 <listitem>
440 <para>
441 is a <application>GTK+ 2</application> internet browser that uses the
442 Mozilla Gecko rendering engine.
443 </para>
444 <indexterm zone="firefox firefox-prog">
445 <primary sortas="b-firefox">firefox</primary>
446 </indexterm>
447 </listitem>
448 </varlistentry>
449
450 </variablelist>
451
452 </sect2>
453
454</sect1>
Note: See TracBrowser for help on using the repository browser.