📄 patch.html
字号:
<HTML><HEAD><TITLE>Installing Patch-2.5.4</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 Mawk-1.3.3"HREF="../chapter05/mawk.html"><LINKREL="NEXT"TITLE="Installing Sed-3.02"HREF="../chapter05/sed.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/mawk.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/sed.html">Next</A></TD></TR></TABLE><HRALIGN="LEFT"WIDTH="100%"></DIV><DIVCLASS="sect1"><H1CLASS="sect1"><ANAME="ch05-patch">5.15. Installing Patch-2.5.4</A></H1><TABLEBORDER="0"BGCOLOR="#E0E0E0"WIDTH="100%"><TR><TD><FONTCOLOR="#000000"><PRECLASS="screen">Estimated build time: 1 minuteEstimated required disk space: 2 MB</PRE></FONT></TD></TR></TABLE><DIVCLASS="sect2"><H2CLASS="sect2"><ANAME="AEN1322">5.15.1. Installation of Patch</A></H2><P>Install Patch by running the following commands:</P><P><TABLEBORDER="0"BGCOLOR="#E0E0E0"WIDTH="100%"><TR><TD><FONTCOLOR="#000000"><PRECLASS="screen"><TTCLASS="userinput"><B>./configure --prefix=$LFS/usr &&make LDFLAGS=-static &&make install</B></TT></PRE></FONT></TD></TR></TABLE></P></DIV><DIVCLASS="sect2"><H2CLASS="sect2"><ANAME="AEN1328">5.15.2. Contents</A></H2><P>The Patch package contains the patch program.</P></DIV><DIVCLASS="sect2"><H2CLASS="sect2"><ANAME="AEN1331">5.15.3. Description</A></H2><P>The patch program modifies a file according to a patch file. A patchfile usually is a list created by the diff program that containsinstructions on how an original file needs to be modified. Patch is useda lot for source code patches since it saves time and space. Imaginea package that is 1MB in size. The next version of that packageonly has changes in two files of the first version. It can be shipped as anentirely new package of 1MB or just as a patch file of 1KB which willupdate the first version to make it identical to the second version. Soif the first version was downloaded already, a patch file avoidsa second large download.</P></DIV><DIVCLASS="sect2"><H2CLASS="sect2"><ANAME="AEN1334">5.15.4. Dependencies</A></H2><P>Patch-2.5.4 needs the following to be installed:</P><PCLASS="literallayout"><br>sh from the bash package<br><br>as from the binutils package<br>ld from the binutils package<br><br>cmp from the diffutils package<br><br>chmod from the fileutils package<br>cp from the fileutils package<br>mv from the fileutils package<br>rm from the fileutils package<br><br>cc from the gcc package<br><br>egrep from the grep package<br>grep from the grep package<br><br>make from the make package<br><br>sed from the sed package<br><br>basename from the sh-utils package<br>expr from the sh-utils package<br>uname from the sh-utils package<br><br>cat from the textutils package<br>tr from the textutils 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/mawk.html">Prev</A></TD><TDWIDTH="34%"ALIGN="center"VALIGN="top"><AHREF="../index.html">Home</A></TD><TDWIDTH="33%"ALIGN="right"VALIGN="top"><AHREF="../chapter05/sed.html">Next</A></TD></TR><TR><TDWIDTH="33%"ALIGN="left"VALIGN="top">Installing Mawk-1.3.3</TD><TDWIDTH="34%"ALIGN="center"VALIGN="top"><AHREF="../chapter05/chapter05.html">Up</A></TD><TDWIDTH="33%"ALIGN="right"VALIGN="top">Installing Sed-3.02</TD></TR></TABLE></DIV></BODY></HTML>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -