⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 bzip2.html

📁 lfs3.1 从源代码构建linux。html版本。
💻 HTML
字号:
<HTML><HEAD><TITLE>Installing Bzip2-1.0.1</TITLE><METANAME="GENERATOR"CONTENT="Modular DocBook HTML Stylesheet Version 1.63"><LINKREL="HOME"TITLE="Linux From Scratch"HREF="../index.html"><LINKREL="UP"TITLE="Preparing the LFS system"HREF="../chapter05/chapter05.html"><LINKREL="PREVIOUS"TITLE="Installing Binutils-2.11.2"HREF="../chapter05/binutils.html"><LINKREL="NEXT"TITLE="Installing Diffutils-2.7"HREF="../chapter05/diffutils.html"></HEAD><BODYCLASS="sect1"BGCOLOR="#FFFFFF"TEXT="#000000"LINK="#0000FF"VLINK="#840084"ALINK="#0000FF"><DIVCLASS="NAVHEADER"><TABLEWIDTH="100%"BORDER="0"CELLPADDING="0"CELLSPACING="0"><TR><THCOLSPAN="3"ALIGN="center">Linux From Scratch: Version 3.1</TH></TR><TR><TDWIDTH="10%"ALIGN="left"VALIGN="bottom"><AHREF="../chapter05/binutils.html">Prev</A></TD><TDWIDTH="80%"ALIGN="center"VALIGN="bottom">Chapter 5. Preparing the LFS system</TD><TDWIDTH="10%"ALIGN="right"VALIGN="bottom"><AHREF="../chapter05/diffutils.html">Next</A></TD></TR></TABLE><HRALIGN="LEFT"WIDTH="100%"></DIV><DIVCLASS="sect1"><H1CLASS="sect1"><ANAME="ch05-bzip2">5.6. Installing Bzip2-1.0.1</A></H1><TABLEBORDER="0"BGCOLOR="#E0E0E0"WIDTH="100%"><TR><TD><FONTCOLOR="#000000"><PRECLASS="screen">Estimated build time:           1 minuteEstimated required disk space:  3 MB</PRE></FONT></TD></TR></TABLE><DIVCLASS="sect2"><H2CLASS="sect2"><ANAME="AEN939">5.6.1. Installation of Bzip2</A></H2><P>Install Bzip2 by running the following commands:</P><P><TABLEBORDER="0"BGCOLOR="#E0E0E0"WIDTH="100%"><TR><TD><FONTCOLOR="#000000"><PRECLASS="screen"><TTCLASS="userinput"><B>make CC="gcc -static" &#38;&#38;make PREFIX=$LFS/usr install &#38;&#38;cd $LFS/usr/bin &#38;&#38;mv bzcat bunzip2 bzip2 bzip2recover $LFS/bin</B></TT></PRE></FONT></TD></TR></TABLE></P><P>Although it's not strictly a part of a basic LFS system it's worthmentioning that a patch for Tar can be downloaded which enables the tarprogram to compress and uncompress using bzip2/bunzip2 easily. With aplain tar, you have to use constructions like bzcat file.tar.bz|tarxv or tar --use-compress-prog=bunzip2 -xvf file.tar.bz2 to use bzip2 andbunzip2 with tar. This patch provides the -j option so you can unpack aBzip2 archive with tar xvfj file.tar.bz2. Applying this patch will bementioned later on when the Tar package is installed.</P></DIV><DIVCLASS="sect2"><H2CLASS="sect2"><ANAME="AEN946">5.6.2. Command explanations</A></H2><P><TTCLASS="userinput"><B>make CC="gcc -static": </B></TT>This is the methodwe use to tell gcc that we want bzip2 to be linked statically.</P></DIV><DIVCLASS="sect2"><H2CLASS="sect2"><ANAME="AEN950">5.6.3. Contents</A></H2><P>The Bzip2 packages contains the bunzip2, bzcat, bzip2 and bzip2recover programs.</P></DIV><DIVCLASS="sect2"><H2CLASS="sect2"><ANAME="AEN953">5.6.4. Description</A></H2><DIVCLASS="sect3"><H3CLASS="sect3"><ANAME="AEN955">5.6.4.1. bunzip2</A></H3><P>Bunzip2 decompresses files that are compressed with bzip2.</P></DIV><DIVCLASS="sect3"><H3CLASS="sect3"><ANAME="AEN958">5.6.4.2. bzcat</A></H3><P>bzcat (or bzip2 -dc) decompresses all specified files to the standard output.</P></DIV><DIVCLASS="sect3"><H3CLASS="sect3"><ANAME="AEN961">5.6.4.3. bzip2</A></H3><P>bzip2 compresses files using the Burrows-Wheeler block sorting text compression algorithm, and Huffman coding. Compression is generally considerably  better than that achieved by more conventional LZ77/LZ78-based compressors, and approaches the performance of the PPM family of statistical compressors.</P></DIV><DIVCLASS="sect3"><H3CLASS="sect3"><ANAME="AEN964">5.6.4.4. bzip2recover</A></H3><P>bzip2recover recovers data from damaged bzip2 files.</P></DIV></DIV><DIVCLASS="sect2"><H2CLASS="sect2"><ANAME="AEN967">5.6.5. Dependencies</A></H2><P>Bzip2-1.0.1 needs the following to be installed:</P><PCLASS="literallayout"><br>sh&nbsp;from&nbsp;the&nbsp;bash&nbsp;package<br><br>ar&nbsp;from&nbsp;the&nbsp;binutils&nbsp;package<br>as&nbsp;from&nbsp;the&nbsp;binutils&nbsp;package<br>ld&nbsp;from&nbsp;the&nbsp;binutils&nbsp;package<br><br>cp&nbsp;from&nbsp;the&nbsp;fileutils&nbsp;package<br>ln&nbsp;from&nbsp;the&nbsp;fileutils&nbsp;package<br>rm&nbsp;from&nbsp;the&nbsp;fileutils&nbsp;package<br><br>gcc&nbsp;from&nbsp;the&nbsp;gcc&nbsp;package<br><br>make&nbsp;from&nbsp;the&nbsp;make&nbsp;package<br></P></DIV></DIV><DIVCLASS="NAVFOOTER"><HRALIGN="LEFT"WIDTH="100%"><TABLEWIDTH="100%"BORDER="0"CELLPADDING="0"CELLSPACING="0"><TR><TDWIDTH="33%"ALIGN="left"VALIGN="top"><AHREF="../chapter05/binutils.html">Prev</A></TD><TDWIDTH="34%"ALIGN="center"VALIGN="top"><AHREF="../index.html">Home</A></TD><TDWIDTH="33%"ALIGN="right"VALIGN="top"><AHREF="../chapter05/diffutils.html">Next</A></TD></TR><TR><TDWIDTH="33%"ALIGN="left"VALIGN="top">Installing Binutils-2.11.2</TD><TDWIDTH="34%"ALIGN="center"VALIGN="top"><AHREF="../chapter05/chapter05.html">Up</A></TD><TDWIDTH="33%"ALIGN="right"VALIGN="top">Installing Diffutils-2.7</TD></TR></TABLE></DIV></BODY></HTML>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -