[0590c1b6] | 1 | <?xml version="1.0" encoding="ISO-8859-1"?>
|
---|
[ff769b8c] | 2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
|
---|
| 3 | "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
|
---|
[0590c1b6] | 4 | <!ENTITY % general-entities SYSTEM "../../general.ent">
|
---|
| 5 | %general-entities;
|
---|
| 6 |
|
---|
| 7 | <!ENTITY ed-download-http "http://ftp.gnu.org/pub/gnu/ed/ed-&ed-version;.tar.gz">
|
---|
| 8 | <!ENTITY ed-download-ftp "ftp://ftp.gnu.org/pub/gnu/ed/ed-&ed-version;.tar.gz">
|
---|
[d4afab2] | 9 | <!ENTITY ed-md5sum "ddd57463774cae9b50e70cd51221281b">
|
---|
[0590c1b6] | 10 | <!ENTITY ed-size "182 KB">
|
---|
[cf068ee1] | 11 | <!ENTITY ed-buildsize "2.9 MB">
|
---|
| 12 | <!ENTITY ed-time "0.02 SBU">
|
---|
[0590c1b6] | 13 | ]>
|
---|
| 14 |
|
---|
| 15 | <sect1 id="ed" xreflabel="Ed-&ed-version;">
|
---|
[a0f03b0] | 16 | <sect1info>
|
---|
[5cd0959d] | 17 | <othername>$LastChangedBy$</othername>
|
---|
| 18 | <date>$Date$</date>
|
---|
[a0f03b0] | 19 | </sect1info>
|
---|
[0590c1b6] | 20 | <?dbhtml filename="ed.html"?>
|
---|
| 21 | <title>Ed-&ed-version;</title>
|
---|
[36d9b2b] | 22 | <indexterm zone="ed"><primary
|
---|
| 23 | sortas="a-Ed">Ed</primary></indexterm>
|
---|
| 24 |
|
---|
[0590c1b6] | 25 | <sect2>
|
---|
| 26 | <title>Introduction to <application>Ed</application></title>
|
---|
| 27 |
|
---|
| 28 | <para><application>Ed</application> is a line-oriented text editor. It
|
---|
| 29 | is used to create, display, modify and otherwise manipulate text files,
|
---|
| 30 | both interactively and via shell scripts. Ed isn't something which many
|
---|
| 31 | people use. It's described here because it can be used by the patch
|
---|
| 32 | program if you encounter an ed-based patch file. This happens rarely
|
---|
| 33 | because diff-based patches are preferred these days.</para>
|
---|
| 34 |
|
---|
| 35 | <sect3><title>Package information</title>
|
---|
| 36 | <itemizedlist spacing="compact">
|
---|
[d4afab2] | 37 | <listitem><para>Download (HTTP):
|
---|
| 38 | <ulink url="&ed-download-http;"/></para></listitem>
|
---|
| 39 | <listitem><para>Download (FTP):
|
---|
| 40 | <ulink url="&ed-download-ftp;"/></para></listitem>
|
---|
| 41 | <listitem><para>Download MD5 sum: &ed-md5sum;</para></listitem>
|
---|
[0590c1b6] | 42 | <listitem><para>Download size: &ed-size;</para></listitem>
|
---|
[d4afab2] | 43 | <listitem><para>Estimated disk space required:
|
---|
| 44 | &ed-buildsize;</para></listitem>
|
---|
| 45 | <listitem><para>Estimated build time:
|
---|
| 46 | &ed-time;</para></listitem></itemizedlist>
|
---|
[0590c1b6] | 47 | </sect3>
|
---|
| 48 |
|
---|
| 49 | <sect3><title>Additional downloads</title>
|
---|
| 50 | <itemizedlist spacing="compact">
|
---|
| 51 | <listitem><para>Required Patch: <ulink
|
---|
[cadb42f] | 52 | url="&patch-root;/ed-&ed-version;-mkstemp-1.patch"/></para></listitem>
|
---|
[0590c1b6] | 53 | </itemizedlist></sect3>
|
---|
| 54 |
|
---|
| 55 | </sect2>
|
---|
| 56 |
|
---|
| 57 | <sect2>
|
---|
| 58 | <title>Installation of <application>Ed</application></title>
|
---|
| 59 |
|
---|
| 60 | <para><application>Ed</application> normally uses the
|
---|
| 61 | <emphasis>mktemp</emphasis> function to create temporary files in
|
---|
| 62 | <filename class="directory">/tmp</filename>, but this function contains
|
---|
| 63 | a vulnerability (see the section on Temporary Files at
|
---|
| 64 | <ulink url="http://en.tldp.org/HOWTO/Secure-Programs-HOWTO/avoid-race.html"/>).
|
---|
| 65 | Apply the following patch to make <application>Ed</application> use
|
---|
| 66 | <emphasis>mkstemp</emphasis> instead, a secure way to create temporary
|
---|
| 67 | files:</para>
|
---|
| 68 |
|
---|
[cadb42f] | 69 | <screen><userinput><command>patch -Np1 -i ../ed-&ed-version;-mkstemp-1.patch</command></userinput></screen>
|
---|
[0590c1b6] | 70 |
|
---|
[63cc8c1] | 71 | <para>Install <application>Ed</application> by running the following
|
---|
| 72 | commands:</para>
|
---|
[0590c1b6] | 73 |
|
---|
[63cc8c1] | 74 | <screen><userinput><command>./configure --prefix=/usr --exec-prefix="" &&
|
---|
[36d9b2b] | 75 | make</command></userinput></screen>
|
---|
| 76 |
|
---|
| 77 | <para>Now, as the root user:</para>
|
---|
| 78 |
|
---|
| 79 | <screen><userinput role='root'><command>make install</command></userinput></screen>
|
---|
[0590c1b6] | 80 |
|
---|
| 81 | </sect2>
|
---|
| 82 |
|
---|
| 83 | <sect2>
|
---|
| 84 | <title>Command explanations</title>
|
---|
| 85 |
|
---|
| 86 | <para><parameter>--exec-prefix=""</parameter>: This forces the programs
|
---|
| 87 | to be installed into the <filename class="directory">/bin</filename>
|
---|
| 88 | directory. Having the programs available there is useful in the event of
|
---|
| 89 | the <filename class="directory">/usr</filename> partition being
|
---|
| 90 | unavailable.</para>
|
---|
| 91 |
|
---|
| 92 | </sect2>
|
---|
| 93 |
|
---|
| 94 | <sect2>
|
---|
| 95 | <title>Contents</title>
|
---|
| 96 |
|
---|
[36d9b2b] | 97 | <segmentedlist>
|
---|
| 98 | <segtitle>Installed Programs</segtitle>
|
---|
[25d03a51] | 99 | <segtitle>Installed Libraries</segtitle>
|
---|
| 100 | <segtitle>Installed Directories</segtitle>
|
---|
[36d9b2b] | 101 | <seglistitem>
|
---|
| 102 | <seg>ed and red</seg>
|
---|
[25d03a51] | 103 | <seg>None</seg>
|
---|
| 104 | <seg>None</seg>
|
---|
[36d9b2b] | 105 | </seglistitem>
|
---|
| 106 | </segmentedlist>
|
---|
| 107 |
|
---|
| 108 | <variablelist>
|
---|
| 109 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 110 | <?dbfo list-presentation="list"?>
|
---|
| 111 |
|
---|
| 112 | <varlistentry id="ed-prog">
|
---|
| 113 | <term><filename>ed</filename></term>
|
---|
| 114 | <listitem><para>is a line-oriented text editor.</para>
|
---|
| 115 | <indexterm zone="ed ed-prog">
|
---|
| 116 | <primary sortas="b-ed">ed</primary></indexterm>
|
---|
| 117 | </listitem>
|
---|
| 118 | </varlistentry>
|
---|
| 119 |
|
---|
| 120 | <varlistentry id="red">
|
---|
| 121 | <term><filename>red</filename></term>
|
---|
| 122 | <listitem><para>is a restricted ed—it can only edit files in the
|
---|
[cf068ee1] | 123 | current directory and cannot execute shell commands.</para>
|
---|
[36d9b2b] | 124 | <indexterm zone="ed red">
|
---|
| 125 | <primary sortas="b-red">red</primary></indexterm>
|
---|
| 126 | </listitem>
|
---|
| 127 | </varlistentry>
|
---|
| 128 |
|
---|
| 129 | </variablelist>
|
---|
[0590c1b6] | 130 |
|
---|
| 131 | </sect2>
|
---|
| 132 |
|
---|
| 133 | </sect1>
|
---|