source: BOOK/final-system/common/gzip.xml@ 3373dd11

clfs-1.2 clfs-2.1 clfs-3.0.0-systemd clfs-3.0.0-sysvinit systemd sysvinit
Last change on this file since 3373dd11 was 3373dd11, checked in by Jim Gifford <clfs@…>, 19 years ago

r668@server (orig r666): manuel | 2005-11-08 15:25:13 -0800
Removing SBUs and DUs. Chapter final-system, round 6.

  • Property mode set to 100644
File size: 8.3 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
3 "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 <!ENTITY % patches-entities SYSTEM "../../patches.ent">
6 %general-entities;
7 %patches-entities;
8]>
9
10<sect1 id="ch-system-gzip" role="wrap">
11 <?dbhtml filename="gzip.html"?>
12
13 <title>Gzip-&gzip-version;</title>
14
15 <indexterm zone="ch-system-gzip">
16 <primary sortas="a-Gzip">Gzip</primary>
17 </indexterm>
18
19 <sect2 role="package">
20 <title/>
21
22 <para>The Gzip package contains programs for compressing and decompressing
23 files.</para>
24
25 <segmentedlist>
26 <segtitle>&dependencies;</segtitle>
27
28 <seglistitem>
29 <seg>Bash, Binutils, Coreutils, Diffutils,
30 GCC, Glibc, Grep, Make, and Sed</seg>
31 </seglistitem>
32 </segmentedlist>
33
34 </sect2>
35
36 <sect2 role="installation">
37 <title>Installation of Gzip</title>
38
39 <para os="a">The following patch fixes two security vulnerabilities in Gzip.
40 First, a path traversal bug when using the <option>-N</option> option
41 (CAN-2005-1228) Second, a race condition in the file permission restore
42 code (CAN-2005-0998)</para>
43
44<screen os="b"><userinput>patch -Np1 -i ../&gzip-security_fix-patch;</userinput></screen>
45
46 <para os="c">Prepare Gzip for compilation:</para>
47
48<screen><userinput>./configure --prefix=/usr</userinput></screen>
49
50 <para os="d">The <command>gzexe</command> script has the location of the
51 <command>gzip</command> binary hard-wired into it. Because the
52 location of the binary is changed later, the following command ensures
53 that the new location gets placed into the script:</para>
54
55<screen os="e"><userinput>sed -i 's@"BINDIR"@/bin@g' gzexe.in</userinput></screen>
56
57 <para os="f">Compile the package:</para>
58
59<screen os="g"><userinput>make</userinput></screen>
60
61 <para os="h">Install the package:</para>
62
63<screen os="i"><userinput>make install</userinput></screen>
64
65 <para os="j">Move the <command>gzip</command> program to the <filename
66 class="directory">/bin</filename> directory and create some commonly
67 used symlinks to it:</para>
68
69<screen os="k"><userinput>mv /usr/bin/gzip /bin
70rm /usr/bin/{gunzip,zcat}
71ln -s gzip /bin/gunzip
72ln -s gzip /bin/zcat
73ln -s gzip /bin/compress
74ln -s gunzip /bin/uncompress</userinput></screen>
75
76 </sect2>
77
78 <sect2 id="contents-gzip" role="content">
79 <title>Contents of Gzip</title>
80
81 <segmentedlist>
82 <segtitle>Installed programs</segtitle>
83
84 <seglistitem>
85 <seg>compress (link to gzip), gunzip (link to gzip), gzexe, gzip,
86 uncompress (link to gunzip), zcat (link to gzip), zcmp, zdiff,
87 zegrep, zfgrep, zforce, zgrep, zless, zmore, and znew</seg>
88 </seglistitem>
89 </segmentedlist>
90
91 <variablelist>
92 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
93 <?dbfo list-presentation="list"?>
94 <?dbhtml list-presentation="table"?>
95
96 <varlistentry id="compress">
97 <term><command>compress</command></term>
98 <listitem>
99 <para>Compresses and decompresses files</para>
100 <indexterm zone="ch-system-gzip compress">
101 <primary sortas="b-compress">compress</primary>
102 </indexterm>
103 </listitem>
104 </varlistentry>
105
106 <varlistentry id="gunzip">
107 <term><command>gunzip</command></term>
108 <listitem>
109 <para>Decompresses gzipped files</para>
110 <indexterm zone="ch-system-gzip gunzip">
111 <primary sortas="b-gunzip">gunzip</primary>
112 </indexterm>
113 </listitem>
114 </varlistentry>
115
116 <varlistentry id="gzexe">
117 <term><command>gzexe</command></term>
118 <listitem>
119 <para>Creates self-decompressing executable files</para>
120 <indexterm zone="ch-system-gzip gzexe">
121 <primary sortas="b-gzexe">gzexe</primary>
122 </indexterm>
123 </listitem>
124 </varlistentry>
125
126 <varlistentry id="gzip">
127 <term><command>gzip</command></term>
128 <listitem>
129 <para>Compresses the given files using Lempel-Ziv (LZ77) coding</para>
130 <indexterm zone="ch-system-gzip gzip">
131 <primary sortas="b-gzip">gzip</primary>
132 </indexterm>
133 </listitem>
134 </varlistentry>
135
136 <varlistentry id="uncompress">
137 <term><command>uncompress</command></term>
138 <listitem>
139 <para>Decompresses compressed files</para>
140 <indexterm zone="ch-system-gzip uncompress">
141 <primary sortas="b-uncompress">uncompress</primary>
142 </indexterm>
143 </listitem>
144 </varlistentry>
145
146 <varlistentry id="zcat">
147 <term><command>zcat</command></term>
148 <listitem>
149 <para>Decompresses the given gzipped files to standard output</para>
150 <indexterm zone="ch-system-gzip zcat">
151 <primary sortas="b-zcat">zcat</primary>
152 </indexterm>
153 </listitem>
154 </varlistentry>
155
156 <varlistentry id="zcmp">
157 <term><command>zcmp</command></term>
158 <listitem>
159 <para>Runs <command>cmp</command> on gzipped files</para>
160 <indexterm zone="ch-system-gzip zcmp">
161 <primary sortas="b-zcmp">zcmp</primary>
162 </indexterm>
163 </listitem>
164 </varlistentry>
165
166 <varlistentry id="zdiff">
167 <term><command>zdiff</command></term>
168 <listitem>
169 <para>Runs <command>diff</command> on gzipped files</para>
170 <indexterm zone="ch-system-gzip zdiff">
171 <primary sortas="b-zdiff">zdiff</primary>
172 </indexterm>
173 </listitem>
174 </varlistentry>
175
176 <varlistentry id="zegrep">
177 <term><command>zegrep</command></term>
178 <listitem>
179 <para>Runs <command>egrep</command> on gzipped files</para>
180 <indexterm zone="ch-system-gzip zegrep">
181 <primary sortas="b-zegrep">zegrep</primary>
182 </indexterm>
183 </listitem>
184 </varlistentry>
185
186 <varlistentry id="zfgrep">
187 <term><command>zfgrep</command></term>
188 <listitem>
189 <para>Runs <command>fgrep</command> on gzipped files</para>
190 <indexterm zone="ch-system-gzip zfgrep">
191 <primary sortas="b-zfgrep">zfgrep</primary>
192 </indexterm>
193 </listitem>
194 </varlistentry>
195
196 <varlistentry id="zforce">
197 <term><command>zforce</command></term>
198 <listitem>
199 <para>Forces a <filename class="extension">.gz</filename> extension on
200 all given files that are gzipped files, so that <command>gzip</command>
201 will not compress them again; this can be useful when file names were
202 truncated during a file transfer</para>
203 <indexterm zone="ch-system-gzip zforce">
204 <primary sortas="b-zforce">zforce</primary>
205 </indexterm>
206 </listitem>
207 </varlistentry>
208
209 <varlistentry id="zgrep">
210 <term><command>zgrep</command></term>
211 <listitem>
212 <para>Runs <command>grep</command> on gzipped files</para>
213 <indexterm zone="ch-system-gzip zgrep">
214 <primary sortas="b-zgrep">zgrep</primary>
215 </indexterm>
216 </listitem>
217 </varlistentry>
218
219 <varlistentry id="zless">
220 <term><command>zless</command></term>
221 <listitem>
222 <para>Runs <command>less</command> on gzipped files</para>
223 <indexterm zone="ch-system-gzip zless">
224 <primary sortas="b-zless">zless</primary>
225 </indexterm>
226 </listitem>
227 </varlistentry>
228
229 <varlistentry id="zmore">
230 <term><command>zmore</command></term>
231 <listitem>
232 <para>Runs <command>more</command> on gzipped files</para>
233 <indexterm zone="ch-system-gzip zmore">
234 <primary sortas="b-zmore">zmore</primary>
235 </indexterm>
236 </listitem>
237 </varlistentry>
238
239 <varlistentry id="znew">
240 <term><command>znew</command></term>
241 <listitem>
242 <para>Re-compresses files from <command>compress</command> format to
243 <command>gzip</command> format&mdash;<filename
244 class="extension">.Z</filename> to <filename
245 class="extension">.gz</filename></para>
246 <indexterm zone="ch-system-gzip znew">
247 <primary sortas="b-znew">znew</primary>
248 </indexterm>
249 </listitem>
250 </varlistentry>
251
252 </variablelist>
253
254 </sect2>
255
256</sect1>
Note: See TracBrowser for help on using the repository browser.