source: chapter06/gzip.xml@ 2b7de70

6.1 6.1.1
Last change on this file since 2b7de70 was 2b7de70, checked in by Manuel Canales Esparcia <manuel@…>, 19 years ago

Small typos. Ported from trunk r648 and r6056.

git-svn-id: http://svn.linuxfromscratch.org/LFS/branches/6.1/BOOK@6061 4aa44e1e-78dd-0310-a6d2-fbcd4c07a689

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