[49e162b] | 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 chromium-download-http "https://commondatastorage.googleapis.com/chromium-browser-official/chromium-&chromium-version;.tar.xz">
|
---|
| 8 | <!ENTITY chromium-download-ftp " ">
|
---|
[e4b0ac2] | 9 | <!ENTITY chromium-md5sum "98cf7b6eca255e2422f96094eccc1887">
|
---|
[a172df1] | 10 | <!ENTITY chromium-size "493 MB">
|
---|
[e4b0ac2] | 11 | <!ENTITY chromium-buildsize "5.7 GB">
|
---|
[a172df1] | 12 | <!ENTITY chromium-time "110 SBU (with parallelism=4)">
|
---|
[47eea61] | 13 | <!-- Ninja defaults to parallel build unless supplying -j1, SBU measured on
|
---|
[a172df1] | 14 | dual core, hyperthreaded CPU (4 threads).
|
---|
| 15 |
|
---|
| 16 | I measured with -j4. - Bruce
|
---|
| 17 |
|
---|
| 18 | -->
|
---|
[49e162b] | 19 | ]>
|
---|
| 20 |
|
---|
| 21 | <sect1 id="chromium" xreflabel="Chromium-&chromium-version;">
|
---|
| 22 | <?dbhtml filename="chromium.html"?>
|
---|
| 23 |
|
---|
| 24 | <sect1info>
|
---|
| 25 | <othername>$LastChangedBy$</othername>
|
---|
| 26 | <date>$Date$</date>
|
---|
| 27 | </sect1info>
|
---|
| 28 |
|
---|
| 29 | <title>Chromium-&chromium-version;</title>
|
---|
| 30 |
|
---|
| 31 | <indexterm zone="chromium">
|
---|
| 32 | <primary sortas="a-Chromium">Chromium</primary>
|
---|
| 33 | </indexterm>
|
---|
| 34 |
|
---|
| 35 | <sect2 role="package">
|
---|
| 36 | <title>Introduction to Chromium</title>
|
---|
| 37 |
|
---|
| 38 | <para><application>Chromium</application> is an open-source browser project
|
---|
| 39 | that aims to build a safer, faster, and more stable way for all users to
|
---|
| 40 | experience the web.</para>
|
---|
| 41 |
|
---|
[902fb47] | 42 | &lfs81_checked;
|
---|
[49e162b] | 43 |
|
---|
| 44 | <bridgehead renderas="sect3">Package Information</bridgehead>
|
---|
| 45 | <itemizedlist spacing="compact">
|
---|
| 46 | <listitem>
|
---|
| 47 | <para>Download (HTTP): <ulink url="&chromium-download-http;"/></para>
|
---|
| 48 | </listitem>
|
---|
[266784c0] | 49 | <listitem>
|
---|
[49e162b] | 50 | <para>Download (FTP): <ulink url="&chromium-download-ftp;"/></para>
|
---|
[266784c0] | 51 | </listitem>
|
---|
[49e162b] | 52 | <listitem>
|
---|
| 53 | <para>Download MD5 sum: &chromium-md5sum;</para>
|
---|
| 54 | </listitem>
|
---|
| 55 | <listitem>
|
---|
| 56 | <para>Download size: &chromium-size;</para>
|
---|
| 57 | </listitem>
|
---|
| 58 | <listitem>
|
---|
| 59 | <para>Estimated disk space required: &chromium-buildsize;</para>
|
---|
| 60 | </listitem>
|
---|
| 61 | <listitem>
|
---|
| 62 | <para>Estimated build time: &chromium-time;</para>
|
---|
| 63 | </listitem>
|
---|
| 64 | </itemizedlist>
|
---|
| 65 |
|
---|
| 66 | <bridgehead renderas="sect3">Additional Downloads</bridgehead>
|
---|
[0d4cd97] | 67 |
|
---|
[a172df1] | 68 | <bridgehead renderas="sect4">Required patches:</bridgehead>
|
---|
[f81e94b] | 69 | <itemizedlist spacing="compact">
|
---|
| 70 | <listitem>
|
---|
| 71 | <para>
|
---|
[a172df1] | 72 | <ulink url="&patch-root;/chromium-&chromium-version;-crc32-1.patch"/>
|
---|
[f81e94b] | 73 | </para>
|
---|
| 74 | </listitem>
|
---|
[0d4cd97] | 75 | <listitem>
|
---|
| 76 | <para>
|
---|
[3b5742b] | 77 | <ulink url="&patch-root;/chromium-&chromium-version;-glibc-2.26-1.patch"/>
|
---|
[0d4cd97] | 78 | </para>
|
---|
| 79 | </listitem>
|
---|
[a172df1] | 80 | <listitem>
|
---|
| 81 | <para>
|
---|
| 82 | <ulink url="&patch-root;/chromium-&chromium-version;-gn_bootstrap-1.patch"/>
|
---|
| 83 | </para>
|
---|
| 84 | </listitem>
|
---|
[0d4cd97] | 85 | </itemizedlist>
|
---|
| 86 |
|
---|
[1c578c14] | 87 | <bridgehead renderas="sect4">Optional Chrome binaries to extract the
|
---|
| 88 | <application>WideVine</application> plug-in (Netflix) support:</bridgehead>
|
---|
| 89 | <itemizedlist spacing="compact">
|
---|
[49e162b] | 90 | <listitem>
|
---|
[3b2c28b] | 91 | <para>Download (HTTP):
|
---|
[1c578c14] | 92 | <ulink url="http://dl.google.com/linux/chrome/deb/pool/main/g/google-chrome-stable/google-chrome-stable_&chromium-version;-1_amd64.deb"/>
|
---|
[17c01c61] | 93 | </para>
|
---|
| 94 | </listitem>
|
---|
| 95 | <listitem>
|
---|
[28591b1] | 96 | <para>Download MD5 sum: a6847c8b88f725df2514365ae3c248cc</para>
|
---|
[1c578c14] | 97 | </listitem>
|
---|
| 98 | <listitem>
|
---|
[13f9e208] | 99 | <para>Download size: 63 MB</para>
|
---|
[1c578c14] | 100 | </listitem>
|
---|
| 101 | </itemizedlist>
|
---|
| 102 | <itemizedlist spacing="compact">
|
---|
| 103 | <listitem>
|
---|
[3b2c28b] | 104 | <para>Download (HTTP):
|
---|
[17c01c61] | 105 | <ulink url="http://mirror.retrosnub.co.uk/apt/google/pool/main/g/google-chrome-stable/google-chrome-stable_48.0.2564.116-1_i386.deb"/>
|
---|
| 106 | </para>
|
---|
[47eea61] | 107 | </listitem>
|
---|
| 108 | <listitem>
|
---|
[1c578c14] | 109 | <para>Download MD5 sum: 895e877b9bfe5da05a061369c2078626</para>
|
---|
| 110 | </listitem>
|
---|
| 111 | <listitem>
|
---|
| 112 | <para>Download size: 45 MB</para>
|
---|
[49e162b] | 113 | </listitem>
|
---|
| 114 | </itemizedlist>
|
---|
| 115 |
|
---|
| 116 | <bridgehead renderas="sect3">Chromium Dependencies</bridgehead>
|
---|
| 117 |
|
---|
| 118 | <bridgehead renderas="sect4">Required</bridgehead>
|
---|
| 119 | <para role="required">
|
---|
| 120 | <xref linkend="alsa-lib"/>,
|
---|
| 121 | <xref linkend="cups"/>,
|
---|
| 122 | <xref linkend="desktop-file-utils"/>,
|
---|
| 123 | <xref linkend="dbus"/>,
|
---|
[f57918e] | 124 | <xref linkend="perl-file-basedir"/>,
|
---|
[0a003b3] | 125 | <xref linkend="gtk3"/>,
|
---|
[49e162b] | 126 | <xref linkend="hicolor-icon-theme"/>,
|
---|
[7add59a9] | 127 | <xref linkend="mitkrb"/>,
|
---|
[49e162b] | 128 | <xref linkend="mesa"/>,
|
---|
[2315c0bc] | 129 | <xref linkend="nodejs"/>,
|
---|
[49e162b] | 130 | <xref linkend="nss"/>,
|
---|
[7add59a9] | 131 | <xref linkend="python2"/>,
|
---|
| 132 | <xref linkend="usbutils"/>, and
|
---|
[49e162b] | 133 | <xref linkend="x-window-system"/>
|
---|
| 134 | </para>
|
---|
| 135 |
|
---|
| 136 | <bridgehead renderas="sect4">Recommended</bridgehead>
|
---|
| 137 | <para role="recommended">
|
---|
[a172df1] | 138 | <xref linkend="cacerts"/> (runtime),
|
---|
[17c01c61] | 139 | <xref linkend="ffmpeg"/>,
|
---|
[49e162b] | 140 | <xref linkend="flac"/>,
|
---|
[47eea61] | 141 | <xref linkend="git"/>,
|
---|
[2315c0bc] | 142 | <!-- <xref linkend="icu"/>, -->
|
---|
[0a003b3] | 143 | <!-- <xref linkend="libevent"/>, -->
|
---|
[a172df1] | 144 | <xref linkend="liberation-fonts"/>
|
---|
[49e162b] | 145 | <xref linkend="libexif"/>,
|
---|
[17c01c61] | 146 | <xref linkend="libjpeg"/>,
|
---|
| 147 | <xref linkend="libpng"/>,
|
---|
[49e162b] | 148 | <xref linkend="libsecret"/>,
|
---|
[2315c0bc] | 149 | <!-- <xref linkend="libvpx"/>, -->
|
---|
[47eea61] | 150 | <xref linkend="libwebp"/>,
|
---|
[49e162b] | 151 | <xref linkend="pciutils"/>,
|
---|
| 152 | <xref linkend="pulseaudio"/>,
|
---|
| 153 | <xref linkend="xdg-utils"/>, and
|
---|
| 154 | <xref linkend="yasm"/>
|
---|
| 155 | </para>
|
---|
| 156 |
|
---|
| 157 | <bridgehead renderas="sect4">Optional</bridgehead>
|
---|
| 158 | <para role="optional">
|
---|
[47eea61] | 159 | <xref linkend="GConf"/>,
|
---|
[e4b0ac2] | 160 | <xref linkend="icu"/> (currently broken),
|
---|
[47eea61] | 161 | <xref linkend="gnome-keyring"/>,
|
---|
[e4b0ac2] | 162 | <xref linkend="libevent"/>,
|
---|
[2315c0bc] | 163 | <xref linkend="libvpx"/> (currently broken),
|
---|
[e4b0ac2] | 164 | <xref linkend="libxml2"/>,
|
---|
[a172df1] | 165 | <xref linkend="upower"/> (runtime),
|
---|
[7add59a9] | 166 | <ulink url="https://devel.freebsoft.org/speechd">speech-dispatcher</ulink>
|
---|
[49e162b] | 167 | (for the screen reader), and
|
---|
| 168 | <ulink url="https://google.github.io/snappy">snappy</ulink>
|
---|
| 169 | </para>
|
---|
| 170 |
|
---|
| 171 | <para condition="html" role="usernotes">User Notes:
|
---|
| 172 | <ulink url="&blfs-wiki;/chromium"/></para>
|
---|
| 173 |
|
---|
| 174 | </sect2>
|
---|
| 175 |
|
---|
| 176 | <sect2 role="installation">
|
---|
| 177 | <title>Installation of Chromium</title>
|
---|
| 178 |
|
---|
[a172df1] | 179 | <para>Apply a patches to fix an issue when building against GlibC-2.26 and other build issues:</para>
|
---|
[3b5742b] | 180 |
|
---|
[a172df1] | 181 | <screen><userinput>patch -Np1 -i ../chromium-&chromium-version;-crc32-1.patch &&
|
---|
| 182 | patch -Np1 -i ../chromium-&chromium-version;-glibc-2.26-1.patch &&
|
---|
| 183 | patch -Np1 -i ../chromium-&chromium-version;-gn_bootstrap-1.patch</userinput></screen>
|
---|
[3b5742b] | 184 |
|
---|
[aa9c0853] | 185 | <para>Enable the use of the
|
---|
[47eea61] | 186 | <ulink url="http://www.widevine.com/">WideVine</ulink> plugin, needed for
|
---|
[aa9c0853] | 187 | Netflix support (see the WideVine section below). Define an
|
---|
[47eea61] | 188 | available product name ("Pinkie Pie" in this case) with the following
|
---|
| 189 | command:</para>
|
---|
[49e162b] | 190 |
|
---|
[a172df1] | 191 | <screen><userinput>line='#define WIDEVINE_CDM_VERSION_STRING "Pinkie Pie"'
|
---|
| 192 | sed "/WIDEVINE_CDM_AVAILABLE/a$line" \
|
---|
[49e162b] | 193 | -i third_party/widevine/cdm/stub/widevine_cdm_version.h</userinput></screen>
|
---|
| 194 |
|
---|
[a172df1] | 195 | <para>Fix a problem identified upstream:</para>
|
---|
[4fb7d2ef] | 196 |
|
---|
[a172df1] | 197 | <screen><userinput>sed -e '/frame_buttons.h/a#include "nav_button_layout_manager.h"' \
|
---|
| 198 | -e "/class NavButtonLayoutManager/d" \
|
---|
| 199 | -i chrome/browser/ui/libgtkui/gtk_ui.h</userinput></screen>
|
---|
[4fb7d2ef] | 200 |
|
---|
[a172df1] | 201 | <para>Optionally silence 2862 invalid warnings:</para>
|
---|
[13f9e208] | 202 |
|
---|
[a172df1] | 203 | <screen><userinput>sed '/static_assert/s:^://:' \
|
---|
| 204 | -i third_party/WebKit/Source/platform/wtf/text/TextCodec.h</userinput></screen>
|
---|
[13f9e208] | 205 |
|
---|
[47eea61] | 206 | <para>Remove third-party build files that interfere with system versions:</para>
|
---|
[49e162b] | 207 |
|
---|
| 208 | <note>
|
---|
| 209 | <para>
|
---|
[7add59a9] | 210 | Chromium uses many external projects, the selections below are not set
|
---|
[47eea61] | 211 | in stone, however they have been tested thoroughly. With Chromium
|
---|
[e4b0ac2] | 212 | &chromium-version;, system versions of libvpx, libxml2,
|
---|
[0a003b3] | 213 | and zlib are known to break the build at this time.
|
---|
[a172df1] | 214 | <!-- icu: Now at 59 internally - seems to work now -->
|
---|
[e4b0ac2] | 215 | <!-- icu: Now at 60 - is broken -->
|
---|
| 216 | <!-- libevent: needs internal headers - seems to work now -->
|
---|
[a9b50a4] | 217 | <!-- libvpx: breaks build in gfx -->
|
---|
[a172df1] | 218 | <!-- libxml2: breaks build with ui - seems to work now -->
|
---|
[17c01c61] | 219 | <!-- zlib requires libminizip -->
|
---|
[47eea61] | 220 | </para>
|
---|
| 221 | </note>
|
---|
| 222 |
|
---|
| 223 | <!-- Again, thanks to Arch, this is much better than listing all the needed
|
---|
| 224 | shipped libs required to use the remove_bundled_files.py script -->
|
---|
[0a003b3] | 225 | <screen><userinput>for LIB in ffmpeg flac harfbuzz-ng<!-- icu libevent--> libjpeg \
|
---|
[a172df1] | 226 | libjpeg_turbo libpng libwebp <!-- libxml libvpx-->libxslt yasm; do
|
---|
[2315c0bc] | 227 | find -type f -path "*third_party/$LIB/*" \
|
---|
| 228 | \! -path "*third_party/$LIB/chromium/*" \
|
---|
| 229 | \! -path "*third_party/$LIB/google/*" \
|
---|
[0a003b3] | 230 | \! -path "*base/third_party/icu/*" \
|
---|
[47eea61] | 231 | \! -regex '.*\.\(gn\|gni\|isolate\|py\)' \
|
---|
| 232 | -delete
|
---|
| 233 | done &&
|
---|
| 234 |
|
---|
[a172df1] | 235 | python build/linux/unbundle/replace_gn_files.py \
|
---|
[e4b0ac2] | 236 | --system-libraries ffmpeg flac harfbuzz-ng libjpeg libxml libevent \
|
---|
| 237 | libpng libwebp libxslt opus yasm freetype <!-- libxml libvpx--> &&
|
---|
[17c01c61] | 238 | python third_party/libaddressinput/chromium/tools/update-strings.py</userinput></screen>
|
---|
[49e162b] | 239 |
|
---|
[47eea61] | 240 | <para><application>Chromium</application> uses an internal tool, <ulink
|
---|
| 241 | url="https://chromium.googlesource.com/chromium/src/tools/gn">gn</ulink>,
|
---|
| 242 | to generate the <application>Ninja</application> build files. Complete
|
---|
| 243 | configuration of the build using the following commands:</para>
|
---|
| 244 |
|
---|
| 245 | <note>
|
---|
| 246 | <para>
|
---|
[49e162b] | 247 | <!-- Taken from Arch Linux - an immensely helpful link - Thanks -->
|
---|
[47eea61] | 248 | The Google API Key and OAuth tokens below are specific to LFS. If using
|
---|
| 249 | these instructions for another distro, or if you intend to distribute
|
---|
| 250 | binary copies of the software using these instructions, please obtain
|
---|
| 251 | your own keys following the instructions located at
|
---|
[49e162b] | 252 | <ulink url="http://www.chromium.org/developers/how-tos/api-keys"/>.
|
---|
| 253 | <!-- BLFS Devs, register an account at Google with your
|
---|
| 254 | @linuxfromscratch.org email address, and I'll make you an administrator
|
---|
[e5c8de01] | 255 | for the 'Google APIs for LFS' project (where the API and OAuth keys
|
---|
| 256 | were created for use in the book).-->
|
---|
[49e162b] | 257 | </para>
|
---|
| 258 | </note>
|
---|
| 259 |
|
---|
[aa9c0853] | 260 | <screen><userinput>GN_CONFIG=('google_api_key="AIzaSyDxKL42zsPjbke5O8_rPVpVrLrJ8aeE9rQ"'
|
---|
| 261 | 'google_default_client_id="595013732528-llk8trb03f0ldpqq6nprjp1s79596646.apps.googleusercontent.com"'
|
---|
| 262 | 'google_default_client_secret="5ntt6GbbkjnTVXx-MSxbmx5e"'
|
---|
[47eea61] | 263 | 'clang_use_chrome_plugins=false'
|
---|
| 264 | 'enable_hangout_services_extension=true'
|
---|
| 265 | 'enable_nacl=false'
|
---|
| 266 | 'enable_nacl_nonsfi=false'
|
---|
[a9b50a4] | 267 | 'enable_swiftshader=false'
|
---|
[47eea61] | 268 | 'enable_widevine=true'
|
---|
| 269 | 'fatal_linker_warnings=false'
|
---|
| 270 | 'ffmpeg_branding="Chrome"'
|
---|
| 271 | 'fieldtrial_testing_like_official_build=true'
|
---|
| 272 | 'is_debug=false'
|
---|
| 273 | 'is_clang=false'
|
---|
| 274 | 'link_pulseaudio=true'
|
---|
| 275 | 'linux_use_bundled_binutils=false'
|
---|
| 276 | 'proprietary_codecs=true'
|
---|
| 277 | 'remove_webcore_debug_symbols=true'
|
---|
| 278 | 'symbol_level=0'
|
---|
| 279 | 'treat_warnings_as_errors=false'
|
---|
| 280 | 'use_allocator="none"'
|
---|
| 281 | 'use_cups=true'
|
---|
| 282 | 'use_gconf=false'
|
---|
| 283 | 'use_gnome_keyring=false'
|
---|
| 284 | 'use_gold=false'
|
---|
[0a003b3] | 285 | 'use_gtk3=true'
|
---|
[47eea61] | 286 | 'use_kerberos=true'
|
---|
| 287 | 'use_pulseaudio=true'
|
---|
| 288 | 'use_sysroot=false')</userinput></screen>
|
---|
| 289 |
|
---|
| 290 | <para>Build <application>gn</application> and use it to prepare the
|
---|
| 291 | <application>Ninja</application> build files:</para>
|
---|
| 292 |
|
---|
[a9b50a4] | 293 | <screen><userinput>python tools/gn/bootstrap/bootstrap.py --gn-gen-args "${GN_CONFIG[*]}" &&
|
---|
[47eea61] | 294 | out/Release/gn gen out/Release --args="${GN_CONFIG[*]}"</userinput></screen>
|
---|
[49e162b] | 295 |
|
---|
[f81e94b] | 296 | <warning>
|
---|
| 297 | <para>Ninja, by default, sets the number of jobs to the number of
|
---|
[3b2c28b] | 298 | available threads. If your machine is memory constrained, with regard to
|
---|
[f81e94b] | 299 | number of threads, you should reduce the number of jobs by passing the
|
---|
| 300 | <parameter>-j#</parameter> switch to the <command>ninja</command> command
|
---|
| 301 | below. Plan for roughly 1.25GB per thread while linking
|
---|
[3b2c28b] | 302 | <application>WebKit</application> to avoid out of memory errors.</para>
|
---|
[f81e94b] | 303 | </warning>
|
---|
| 304 |
|
---|
[49e162b] | 305 | <para>Build <application>Chromium</application> using the following
|
---|
[2315c0bc] | 306 | commands:</para>
|
---|
[49e162b] | 307 |
|
---|
[2315c0bc] | 308 | <screen><userinput>mkdir -p third_party/node/linux/node-linux-x64/bin &&
|
---|
| 309 | ln -s /usr/bin/node third_party/node/linux/node-linux-x64/bin/ &&
|
---|
| 310 | ninja -C out/Release chrome chrome_sandbox chromedriver widevinecdmadapter</userinput></screen>
|
---|
[49e162b] | 311 |
|
---|
| 312 | <para>This package was already tested as part of the build.</para>
|
---|
| 313 |
|
---|
| 314 | <para>Now, as the <systemitem class="username">root</systemitem> user,
|
---|
[eb588e8] | 315 | install the package:</para>
|
---|
[49e162b] | 316 |
|
---|
| 317 | <screen role="root"><userinput>install -vDm755 out/Release/chrome \
|
---|
[266784c0] | 318 | /usr/lib/chromium/chromium &&
|
---|
[e4b0ac2] | 319 |
|
---|
[49e162b] | 320 | install -vDm4755 out/Release/chrome_sandbox \
|
---|
[266784c0] | 321 | /usr/lib/chromium/chrome-sandbox &&
|
---|
[e4b0ac2] | 322 |
|
---|
[49e162b] | 323 | install -vDm755 out/Release/chromedriver \
|
---|
[266784c0] | 324 | /usr/lib/chromium/chromedriver &&
|
---|
[49e162b] | 325 |
|
---|
[e4b0ac2] | 326 | ln -svf /usr/lib/chromium/chromium /usr/bin &&
|
---|
| 327 | ln -svf /usr/lib/chromium/chromedriver /usr/bin &&
|
---|
| 328 |
|
---|
[47eea61] | 329 | install -vDm644 out/Release/gen/content/content_resources.pak \
|
---|
[266784c0] | 330 | /usr/lib/chromium/ &&
|
---|
[e4b0ac2] | 331 | <!-- This is needed if using internal icu -->
|
---|
| 332 | install -vDm644 out/Release/icudtl.dat \
|
---|
| 333 | /usr/lib/chromium/icudtl.dat &&
|
---|
| 334 |
|
---|
| 335 | install -vDm644 out/Release/{*.pak,*.bin} \
|
---|
[1fb6a438] | 336 | /usr/lib/chromium/ &&
|
---|
[49e162b] | 337 |
|
---|
[266784c0] | 338 | cp -av out/Release/locales /usr/lib/chromium/ &&
|
---|
| 339 | chown -Rv root:root /usr/lib/chromium/locales &&
|
---|
[49e162b] | 340 |
|
---|
| 341 | install -vDm644 out/Release/chrome.1 \
|
---|
| 342 | /usr/share/man/man1/chromium.1</userinput></screen>
|
---|
| 343 |
|
---|
| 344 | <para>While still the <systemitem class="username">root</systemitem> user,
|
---|
| 345 | install icons and the .desktop file:</para>
|
---|
| 346 |
|
---|
[dac5077] | 347 | <screen role="root"><userinput>for size in 16 32; do
|
---|
[49e162b] | 348 | install -vDm644 \
|
---|
| 349 | "chrome/app/theme/default_100_percent/chromium/product_logo_$size.png" \
|
---|
| 350 | "/usr/share/icons/hicolor/${size}x${size}/apps/chromium.png"
|
---|
| 351 | done &&
|
---|
| 352 |
|
---|
| 353 | for size in 22 24 48 64 128 256; do
|
---|
| 354 | install -vDm644 "chrome/app/theme/chromium/product_logo_$size.png" \
|
---|
| 355 | "/usr/share/icons/hicolor/${size}x${size}/apps/chromium.png"
|
---|
| 356 | done &&
|
---|
| 357 |
|
---|
| 358 | cat > /usr/share/applications/chromium.desktop << "EOF"
|
---|
| 359 | [Desktop Entry]
|
---|
| 360 | Encoding=UTF-8
|
---|
| 361 | Name=Chromium Web Browser
|
---|
| 362 | Comment=Access the Internet
|
---|
| 363 | GenericName=Web Browser
|
---|
| 364 | Exec=chromium %u
|
---|
| 365 | Terminal=false
|
---|
| 366 | Type=Application
|
---|
| 367 | Icon=chromium
|
---|
| 368 | Categories=GTK;Network;WebBrowser;
|
---|
| 369 | MimeType=application/xhtml+xml;text/xml;application/xhtml+xml;text/mml;x-scheme-handler/http;x-scheme-handler/https;
|
---|
| 370 | EOF</userinput></screen>
|
---|
| 371 |
|
---|
[0a003b3] | 372 | <note>
|
---|
| 373 | <para>If upgrading from a previous build of chromium using gtk+-2.x, you
|
---|
| 374 | may need to remove the <filename
|
---|
| 375 | class="directory">~/.config/chromium</filename> directory.</para>
|
---|
| 376 | </note>
|
---|
| 377 |
|
---|
[47eea61] | 378 | <bridgehead renderas="sect3">Extracting the WideVine plugin from Chrome</bridgehead>
|
---|
[49e162b] | 379 |
|
---|
| 380 | <para>Extract the downloaded deb file with the following commands:</para>
|
---|
| 381 |
|
---|
[266784c0] | 382 | <screen><userinput>mkdir temp &&
|
---|
| 383 | cd temp &&
|
---|
[1c578c14] | 384 | case $(uname -m) in
|
---|
| 385 | x86_64) ar -x ../../google-chrome-stable_&chromium-version;-1_amd64.deb
|
---|
| 386 | ;;
|
---|
[f81e94b] | 387 | i?86) ar -x ../../google-chrome-stable_48.0.2564.116-1_i386.deb
|
---|
[1c578c14] | 388 | ;;
|
---|
| 389 | esac</userinput></screen>
|
---|
[49e162b] | 390 |
|
---|
[aa9c0853] | 391 | <para>As the <systemitem class="username">root</systemitem> user, enable
|
---|
| 392 | the WideVine plugin with the following commands:</para>
|
---|
| 393 |
|
---|
| 394 | <!-- Note that libwidevinecdmadapter.so is not in the tarball. It is
|
---|
| 395 | created only if enable_widevine=true i sset in GN_CONFIG -->
|
---|
[47eea61] | 396 |
|
---|
[aa9c0853] | 397 | <screen role="root"><userinput>tar -xf data.tar.xz &&
|
---|
| 398 | install -vm755 ../out/Release/libwidevinecdmadapter.so /usr/lib/chromium/ &&
|
---|
| 399 | install -vm755 opt/google/chrome/libwidevinecdm.so /usr/lib/chromium/</userinput></screen>
|
---|
[49e162b] | 400 |
|
---|
| 401 | </sect2>
|
---|
| 402 |
|
---|
| 403 | <sect2 role="commands">
|
---|
| 404 | <title>Command Explanations</title>
|
---|
| 405 |
|
---|
[47eea61] | 406 | <para><command>GN_CONFIG=(...)</command>: this array contains
|
---|
[49e162b] | 407 | all of the defines used in the build.</para>
|
---|
| 408 |
|
---|
[47eea61] | 409 | <para><command>python tools/gn/bootstrap/bootstrap.py --gn-gen-args "${GN_CONFIG[*]}"</command>:
|
---|
| 410 | this command replaces defines in the gn files with the values contained in
|
---|
| 411 | <envar>${GN_CONFIG[@]}</envar>.</para>
|
---|
[49e162b] | 412 |
|
---|
[47eea61] | 413 | <para><command>out/Release/gn gen out/Release --args="${GN_CONFIG[*]}"</command>:
|
---|
| 414 | this command runs a Google provided configuration script
|
---|
| 415 | <application>gn</application> on the source tree to produce
|
---|
[49e162b] | 416 | a <application>Ninja</application> configuration suitable for the build
|
---|
| 417 | machine.</para>
|
---|
| 418 |
|
---|
[2315c0bc] | 419 | <para><command>mkdir...ln -s /usr/bin/node
|
---|
| 420 | third_party/node/linux/node-linux-x64/bin/</command>: these commands
|
---|
| 421 | replaced the local <application>Node.js</application> (no longer available)
|
---|
| 422 | with the system installed <application>Node.js</application>.</para>
|
---|
| 423 |
|
---|
[47eea61] | 424 | <para><command>ar -x ../../google-chrome-stable*.deb</command>:
|
---|
[49e162b] | 425 | the <command>ar</command> utility is used to extract Debian archives.</para>
|
---|
| 426 |
|
---|
| 427 | </sect2>
|
---|
| 428 |
|
---|
| 429 | <sect2 role="content">
|
---|
| 430 | <title>Contents</title>
|
---|
| 431 |
|
---|
| 432 | <segmentedlist>
|
---|
| 433 | <segtitle>Installed Programs</segtitle>
|
---|
| 434 | <segtitle>Installed Libraries</segtitle>
|
---|
| 435 | <segtitle>Installed Directories</segtitle>
|
---|
| 436 |
|
---|
| 437 | <seglistitem>
|
---|
[1c578c14] | 438 | <seg>/usr/lib/chromium/chromium,
|
---|
[49e162b] | 439 | /usr/lib/chromium/chromedriver, and
|
---|
| 440 | /usr/lib/chromium/chrome-sandbox</seg>
|
---|
| 441 | <seg>none</seg>
|
---|
[1c578c14] | 442 | <seg>/usr/lib/chromium</seg>
|
---|
[49e162b] | 443 | </seglistitem>
|
---|
| 444 | </segmentedlist>
|
---|
| 445 |
|
---|
| 446 | <variablelist>
|
---|
| 447 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 448 | <?dbfo list-presentation="list"?>
|
---|
| 449 | <?dbhtml list-presentation="table"?>
|
---|
| 450 |
|
---|
| 451 | <varlistentry id="chromium-lib">
|
---|
| 452 | <term><command>/usr/lib/chromium/chromium</command></term>
|
---|
| 453 | <listitem>
|
---|
| 454 | <para> is the main chromium executable.</para>
|
---|
| 455 | <indexterm zone="chromium chromium-lib">
|
---|
| 456 | <primary sortas="b-chromiumlib">chromium</primary>
|
---|
| 457 | </indexterm>
|
---|
| 458 | </listitem>
|
---|
| 459 | </varlistentry>
|
---|
| 460 |
|
---|
| 461 | <varlistentry id="chromedriver">
|
---|
[0d4cd97] | 462 | <term><command>/usr/lib/chromium/chromedriver</command></term>
|
---|
[49e162b] | 463 | <listitem>
|
---|
| 464 | <para> is a
|
---|
| 465 | <ulink url="http://www.seleniumhq.org/projects/webdriver/">
|
---|
| 466 | WebDriver</ulink> for Chromium.</para>
|
---|
| 467 | <indexterm zone="chromium chromedriver">
|
---|
| 468 | <primary sortas="b-chromedriver">chromedriver</primary>
|
---|
| 469 | </indexterm>
|
---|
| 470 | </listitem>
|
---|
| 471 | </varlistentry>
|
---|
| 472 |
|
---|
| 473 | <varlistentry id="chrome-sandbox">
|
---|
| 474 | <term><command>/usr/lib/chromium/chrome-sandbox</command></term>
|
---|
| 475 | <listitem>
|
---|
| 476 | <para> creates a sandboxed environment for running untrusted
|
---|
| 477 | code (plugins).</para>
|
---|
| 478 | <indexterm zone="chromium chrome-sandbox">
|
---|
| 479 | <primary sortas="b-chrome-sandbox">chrome-sandbox</primary>
|
---|
| 480 | </indexterm>
|
---|
| 481 | </listitem>
|
---|
| 482 | </varlistentry>
|
---|
| 483 |
|
---|
| 484 | </variablelist>
|
---|
| 485 |
|
---|
| 486 | </sect2>
|
---|
| 487 |
|
---|
| 488 | </sect1>
|
---|