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 brotli-download-http "https://github.com/google/brotli/archive/v&brotli-version;/brotli-&brotli-version;.tar.gz">
|
---|
8 | <!ENTITY brotli-download-ftp " ">
|
---|
9 | <!ENTITY brotli-md5sum "3a6a3dba82a3604792d3cb0bd41bca60">
|
---|
10 | <!ENTITY brotli-size "500 KB">
|
---|
11 | <!ENTITY brotli-buildsize "33 MB (with python3 bindings)">
|
---|
12 | <!-- The python tests for this package are broken. The tarball is missing a lot of test files -->
|
---|
13 | <!ENTITY brotli-time "0.3 SBU (with python3 bindings; parallelism=4)">
|
---|
14 | ]>
|
---|
15 |
|
---|
16 | <sect1 id="brotli" xreflabel="Brotli-&brotli-version;">
|
---|
17 | <?dbhtml filename="brotli.html"?>
|
---|
18 |
|
---|
19 |
|
---|
20 | <title>brotli-&brotli-version;</title>
|
---|
21 |
|
---|
22 | <indexterm zone="brotli">
|
---|
23 | <primary sortas="a-brotli">Brotli</primary>
|
---|
24 | </indexterm>
|
---|
25 |
|
---|
26 | <sect2 role="package">
|
---|
27 | <title>Introduction to Brotli</title>
|
---|
28 |
|
---|
29 | <para>
|
---|
30 | <application>Brotli</application> provides a general-purpose lossless
|
---|
31 | compression algorithm that compresses data using a combination of a
|
---|
32 | modern variant of the LZ77 algorithm, Huffman coding and 2nd order
|
---|
33 | context modeling. Its libraries are particularly used for WOFF2 fonts
|
---|
34 | on webpages.
|
---|
35 | </para>
|
---|
36 |
|
---|
37 | &lfs120_checked;
|
---|
38 |
|
---|
39 | <bridgehead renderas="sect3">Package Information</bridgehead>
|
---|
40 | <itemizedlist spacing="compact">
|
---|
41 | <listitem>
|
---|
42 | <para>
|
---|
43 | Download (HTTP): <ulink url="&brotli-download-http;"/>
|
---|
44 | </para>
|
---|
45 | </listitem>
|
---|
46 | <listitem>
|
---|
47 | <para>
|
---|
48 | Download (FTP): <ulink url="&brotli-download-ftp;"/>
|
---|
49 | </para>
|
---|
50 | </listitem>
|
---|
51 | <listitem>
|
---|
52 | <para>
|
---|
53 | Download MD5 sum: &brotli-md5sum;
|
---|
54 | </para>
|
---|
55 | </listitem>
|
---|
56 | <listitem>
|
---|
57 | <para>
|
---|
58 | Download size: &brotli-size;
|
---|
59 | </para>
|
---|
60 | </listitem>
|
---|
61 | <listitem>
|
---|
62 | <para>
|
---|
63 | Estimated disk space required: &brotli-buildsize;
|
---|
64 | </para>
|
---|
65 | </listitem>
|
---|
66 | <listitem>
|
---|
67 | <para>
|
---|
68 | Estimated build time: &brotli-time;
|
---|
69 | </para>
|
---|
70 | </listitem>
|
---|
71 | </itemizedlist>
|
---|
72 |
|
---|
73 | <bridgehead renderas="sect3">Brotli Dependencies</bridgehead>
|
---|
74 |
|
---|
75 | <bridgehead renderas="sect4">Required</bridgehead>
|
---|
76 | <para role="required">
|
---|
77 | <xref linkend="cmake"/>
|
---|
78 | </para>
|
---|
79 |
|
---|
80 | <bridgehead renderas="sect4">Optional</bridgehead>
|
---|
81 | <para role="optional">
|
---|
82 | <xref linkend="pluggy"/> and
|
---|
83 | <xref linkend="pytest"/> (for testing Python3 bindings)
|
---|
84 | </para>
|
---|
85 |
|
---|
86 | </sect2>
|
---|
87 |
|
---|
88 | <sect2 role="installation">
|
---|
89 | <title>Installation of Brotli</title>
|
---|
90 |
|
---|
91 | <para>
|
---|
92 | Install <application>brotli</application> by running the following
|
---|
93 | commands:
|
---|
94 | </para>
|
---|
95 |
|
---|
96 | <screen><userinput>mkdir build &&
|
---|
97 | cd build &&
|
---|
98 |
|
---|
99 | cmake -DCMAKE_INSTALL_PREFIX=/usr \
|
---|
100 | -DCMAKE_BUILD_TYPE=Release \
|
---|
101 | .. &&
|
---|
102 | make</userinput></screen>
|
---|
103 |
|
---|
104 | <para>
|
---|
105 | To test the results, issue: <command>make test</command>.
|
---|
106 | </para>
|
---|
107 |
|
---|
108 | <!-- These are broken
|
---|
109 | <para>
|
---|
110 | The python tests are missing most of the necessary testdata files and
|
---|
111 | therefore 240 of 311 tests fail.
|
---|
112 | If you nevertheless wish to test the bindings, go back to the top-level directory and
|
---|
113 | issue: <command>python3 setup.py test</command>.
|
---|
114 | </para>
|
---|
115 | -->
|
---|
116 | <para>
|
---|
117 | Now, as the <systemitem class="username">root</systemitem> user:
|
---|
118 | </para>
|
---|
119 |
|
---|
120 | <screen role="root"><userinput>make install</userinput></screen>
|
---|
121 |
|
---|
122 | <para>
|
---|
123 | If desired, build the <application>Python3</application>
|
---|
124 | bindings:
|
---|
125 | </para>
|
---|
126 |
|
---|
127 | <screen><userinput>cd .. &&
|
---|
128 | sed "/c\/.*\.[ch]'/d;\
|
---|
129 | /include_dirs=\[/\
|
---|
130 | i libraries=['brotlicommon','brotlidec','brotlienc']," \
|
---|
131 | -i setup.py &&
|
---|
132 | &build-wheel-cmd; $PWD</userinput></screen>
|
---|
133 |
|
---|
134 | <para>
|
---|
135 | Install the <application>Python3</application>
|
---|
136 | bindings as the &root; user:
|
---|
137 | </para>
|
---|
138 |
|
---|
139 | <screen role="root"><userinput>&install-wheel; Brotli</userinput></screen>
|
---|
140 |
|
---|
141 | <!-- "131 passed in 2.76s" for me with 1.1.0 -->
|
---|
142 | <para>
|
---|
143 | To test the <application>Python3</application> binding, issue:
|
---|
144 | <command>pytest</command>.
|
---|
145 | </para>
|
---|
146 | </sect2>
|
---|
147 |
|
---|
148 | <sect2 role="commands">
|
---|
149 | <title>Command Explanations</title>
|
---|
150 |
|
---|
151 | <!-- https://github.com/google/brotli/issues/933 -->
|
---|
152 | <para>
|
---|
153 | <command>sed ... -i setup.py</command>: Stop
|
---|
154 | <filename>setup.py</filename> from rebuilding the entire package all
|
---|
155 | over again, use the already installed libraries for the
|
---|
156 | <application>Python3</application> binding instead.
|
---|
157 | </para>
|
---|
158 |
|
---|
159 | <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
|
---|
160 | href="../../xincludes/static-libraries.xml"/>
|
---|
161 |
|
---|
162 | </sect2>
|
---|
163 |
|
---|
164 | <sect2 role="content">
|
---|
165 | <title>Contents</title>
|
---|
166 |
|
---|
167 | <segmentedlist>
|
---|
168 | <segtitle>Installed Programs</segtitle>
|
---|
169 | <segtitle>Installed Libraries</segtitle>
|
---|
170 | <segtitle>Installed Directories</segtitle>
|
---|
171 |
|
---|
172 | <seglistitem>
|
---|
173 | <seg>
|
---|
174 | brotli
|
---|
175 | </seg>
|
---|
176 | <seg>
|
---|
177 | libbrotlicommon.so,
|
---|
178 | libbrotlidec.so, and
|
---|
179 | libbrotlienc.so
|
---|
180 | </seg>
|
---|
181 | <seg>
|
---|
182 | /usr/include/brotli and
|
---|
183 | /usr/lib/python&python3-majorver;/site-packages/Brotli-&brotli-version;.dist-info
|
---|
184 | (if you built and installed the Python3 bindings)
|
---|
185 | </seg>
|
---|
186 | </seglistitem>
|
---|
187 | </segmentedlist>
|
---|
188 |
|
---|
189 | <variablelist>
|
---|
190 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
191 | <?dbfo list-presentation="list"?>
|
---|
192 | <?dbhtml list-presentation="table"?>
|
---|
193 |
|
---|
194 | <varlistentry id="brotli-prog">
|
---|
195 | <term><command>brotli</command></term>
|
---|
196 | <listitem>
|
---|
197 | <para>
|
---|
198 | can compress or decompress files, or test the integrity of
|
---|
199 | compressed files
|
---|
200 | </para>
|
---|
201 | <indexterm zone="brotli brotli-prog">
|
---|
202 | <primary sortas="b-brotli">brotli</primary>
|
---|
203 | </indexterm>
|
---|
204 | </listitem>
|
---|
205 | </varlistentry>
|
---|
206 |
|
---|
207 | <varlistentry id="libbrotlicommon">
|
---|
208 | <term><filename class="libraryfile">libbrotlicommon{-static.a,.so}</filename></term>
|
---|
209 | <listitem>
|
---|
210 | <para>
|
---|
211 | is the Brotli common dictionary library
|
---|
212 | </para>
|
---|
213 | <indexterm zone="brotli libbrotlicommon">
|
---|
214 | <primary sortas="c-libbrotlicommon">libbrotlicommon{,-static.a,.so}</primary>
|
---|
215 | </indexterm>
|
---|
216 | </listitem>
|
---|
217 | </varlistentry>
|
---|
218 |
|
---|
219 | <varlistentry id="libbrotlidec">
|
---|
220 | <term><filename class="libraryfile">libbrotlidec{-static.a,.so}</filename></term>
|
---|
221 | <listitem>
|
---|
222 | <para>
|
---|
223 | is the Brotli decoder library
|
---|
224 | </para>
|
---|
225 | <indexterm zone="brotli libbrotlidec">
|
---|
226 | <primary sortas="c-libbrotlidec">libbrotlidec{,-static.a,.so}</primary>
|
---|
227 | </indexterm>
|
---|
228 | </listitem>
|
---|
229 | </varlistentry>
|
---|
230 |
|
---|
231 | <varlistentry id="libbrotlienc">
|
---|
232 | <term><filename class="libraryfile">libbrotlienc{-static.a,.so}</filename></term>
|
---|
233 | <listitem>
|
---|
234 | <para>
|
---|
235 | is the Brotli common encoder library
|
---|
236 | </para>
|
---|
237 | <indexterm zone="brotli libbrotlienc">
|
---|
238 | <primary sortas="c-libbrotlienc">libbrotlienc{,-static.a,.so}</primary>
|
---|
239 | </indexterm>
|
---|
240 | </listitem>
|
---|
241 | </varlistentry>
|
---|
242 | </variablelist>
|
---|
243 |
|
---|
244 | </sect2>
|
---|
245 |
|
---|
246 | </sect1>
|
---|