[673b0d8] | 1 | <?xml version="1.0" encoding="ISO-8859-1"?>
|
---|
[1770019] | 2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN" "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
|
---|
[673b0d8] | 3 | <!ENTITY % general-entities SYSTEM "../general.ent">
|
---|
| 4 | %general-entities;
|
---|
| 5 | ]>
|
---|
[81fd230] | 6 | <sect1 id="ch-tools-expect" role="wrap">
|
---|
[673b0d8] | 7 | <title>Expect-&expect-version;</title>
|
---|
| 8 | <?dbhtml filename="expect.html"?>
|
---|
| 9 |
|
---|
| 10 | <indexterm zone="ch-tools-expect"><primary sortas="a-Expect">Expect</primary></indexterm>
|
---|
[bc82645e] | 11 |
|
---|
[9652249] | 12 | <sect2 role="package"><title/>
|
---|
[81fd230] | 13 | <para>The Expect package contains a program for carrying out scripted dialogues
|
---|
| 14 | with other interactive programs.</para>
|
---|
[5888299] | 15 |
|
---|
[9652249] | 16 | <segmentedlist>
|
---|
| 17 | <segtitle>&buildtime;</segtitle>
|
---|
| 18 | <segtitle>&diskspace;</segtitle>
|
---|
[fc1024a] | 19 | <seglistitem><seg>0.1 SBU</seg><seg>4.0 MB</seg></seglistitem>
|
---|
[9652249] | 20 | </segmentedlist>
|
---|
| 21 |
|
---|
[81fd230] | 22 | <segmentedlist>
|
---|
[45992ae] | 23 | <segtitle>&dependencies;</segtitle>
|
---|
[81fd230] | 24 | <seglistitem><seg>Bash, Binutils, Coreutils, Diffutils,
|
---|
| 25 | GCC, Glibc, Grep, Make, Sed, and Tcl</seg></seglistitem>
|
---|
| 26 | </segmentedlist>
|
---|
[9652249] | 27 | </sect2>
|
---|
[73aedd1d] | 28 |
|
---|
[9652249] | 29 | <sect2 role="installation">
|
---|
[73aedd1d] | 30 | <title>Installation of Expect</title>
|
---|
| 31 |
|
---|
[81fd230] | 32 | <para>First, fix a bug that can result in false failures during the GCC test
|
---|
| 33 | suite run:</para>
|
---|
[3d36131c] | 34 |
|
---|
[673b0d8] | 35 | <screen><userinput>patch -Np1 -i ../expect-&expect-version;-spawn-1.patch</userinput></screen>
|
---|
[73aedd1d] | 36 |
|
---|
[d27a27b] | 37 | <para>Now prepare Expect for compilation:</para>
|
---|
[73aedd1d] | 38 |
|
---|
[19711e7] | 39 | <screen><userinput>./configure --prefix=/tools --with-tcl=/tools/lib \
|
---|
| 40 | --with-tclinclude=$TCLPATH --with-x=no</userinput></screen>
|
---|
[73aedd1d] | 41 |
|
---|
[81fd230] | 42 | <para>The meaning of the configure options:</para>
|
---|
| 43 |
|
---|
| 44 | <variablelist>
|
---|
| 45 | <varlistentry>
|
---|
| 46 | <term><parameter>--with-tcl=/tools/lib</parameter></term>
|
---|
| 47 | <listitem><para>This ensures that the configure script finds the Tcl installation in
|
---|
| 48 | the temporary tools location instead of possibly locating an existing
|
---|
| 49 | one on the host system.</para></listitem>
|
---|
| 50 | </varlistentry>
|
---|
| 51 |
|
---|
[19711e7] | 52 | <varlistentry>
|
---|
| 53 | <term><parameter>--with-tclinclude=$TCLPATH</parameter></term>
|
---|
| 54 | <listitem><para>This explicitly tells Expect where to find Tcl's source
|
---|
| 55 | directory and internal headers. Using this option avoids conditions
|
---|
[782446b] | 56 | where <command>configure</command> fails because it cannot automatically
|
---|
| 57 | discover the location of the Tcl source directory.</para></listitem>
|
---|
[19711e7] | 58 | </varlistentry>
|
---|
| 59 |
|
---|
[81fd230] | 60 | <varlistentry>
|
---|
| 61 | <term><parameter>--with-x=no</parameter></term>
|
---|
| 62 | <listitem><para>This tells the configure script not to search for Tk
|
---|
| 63 | (the Tcl GUI component) or the X Window System libraries, both of
|
---|
[782446b] | 64 | which may reside on the host system but will not exist in the temporary
|
---|
| 65 | environment.</para></listitem>
|
---|
[81fd230] | 66 | </varlistentry>
|
---|
| 67 | </variablelist>
|
---|
| 68 |
|
---|
[73aedd1d] | 69 | <para>Build the package:</para>
|
---|
| 70 |
|
---|
| 71 | <screen><userinput>make</userinput></screen>
|
---|
| 72 |
|
---|
[81fd230] | 73 | <para>To test the results, issue: <userinput>make test</userinput>.
|
---|
| 74 | Note that the Expect test suite is known to experience failures under
|
---|
| 75 | certain host conditions that are not within our control. Therefore,
|
---|
| 76 | test suite failures here are not surprising and are not considered
|
---|
| 77 | critical.</para>
|
---|
[73aedd1d] | 78 |
|
---|
[81fd230] | 79 | <para>Install the package:</para>
|
---|
[73aedd1d] | 80 |
|
---|
| 81 | <screen><userinput>make SCRIPTS="" install</userinput></screen>
|
---|
| 82 |
|
---|
[81fd230] | 83 | <para>The meaning of the make parameter:</para>
|
---|
| 84 |
|
---|
| 85 | <variablelist>
|
---|
| 86 | <varlistentry>
|
---|
| 87 | <term><parameter>SCRIPTS=""</parameter></term>
|
---|
| 88 | <listitem><para>This prevents installation of the supplementary expect
|
---|
| 89 | scripts, which are not needed.</para></listitem>
|
---|
| 90 | </varlistentry>
|
---|
| 91 | </variablelist>
|
---|
| 92 |
|
---|
[e9ec91d] | 93 | <para>Now remove the <envar>TCLPATH</envar> variable:</para>
|
---|
[19711e7] | 94 |
|
---|
| 95 | <screen><userinput>unset TCLPATH</userinput></screen>
|
---|
| 96 |
|
---|
[81fd230] | 97 | <para>The source directories of both Tcl and Expect can now be removed.</para>
|
---|
[73aedd1d] | 98 |
|
---|
[0b5096ca] | 99 | <beginpage/>
|
---|
| 100 |
|
---|
[73aedd1d] | 101 | </sect2>
|
---|
[bc82645e] | 102 |
|
---|
[9652249] | 103 | <sect2 id="contents-expect" role="content"><title>Contents of Expect</title>
|
---|
[bc82645e] | 104 |
|
---|
[81fd230] | 105 | <segmentedlist>
|
---|
| 106 | <segtitle>Installed program</segtitle>
|
---|
| 107 | <segtitle>Installed library</segtitle>
|
---|
| 108 | <seglistitem><seg>expect</seg><seg>libexpect-5.42.a</seg></seglistitem>
|
---|
| 109 | </segmentedlist>
|
---|
| 110 |
|
---|
| 111 | <variablelist><bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 112 | <?dbfo list-presentation="list"?>
|
---|
[8f97096] | 113 | <?dbhtml list-presentation="table"?>
|
---|
[81fd230] | 114 |
|
---|
| 115 | <varlistentry id="expect">
|
---|
| 116 | <term><command>expect</command></term>
|
---|
| 117 | <listitem>
|
---|
| 118 | <para>Communicates with other interactive
|
---|
| 119 | programs according to a script</para>
|
---|
| 120 | <indexterm zone="ch-tools-expect expect"><primary sortas="b-expect">expect</primary></indexterm>
|
---|
| 121 | </listitem>
|
---|
| 122 | </varlistentry>
|
---|
| 123 |
|
---|
| 124 | <varlistentry id="libexpect">
|
---|
| 125 | <term><filename class="libraryfile">libexpect-5.42.a</filename></term>
|
---|
| 126 | <listitem>
|
---|
| 127 | <para>Contains functions that allow Expect to be used as a Tcl extension or to
|
---|
| 128 | be used directly from C or C++ (without Tcl)</para>
|
---|
| 129 | <indexterm zone="ch-tools-expect libexpect"><primary
|
---|
| 130 | sortas="c-libexpect-5.42">libexpect-5.42</primary></indexterm>
|
---|
| 131 | </listitem>
|
---|
| 132 | </varlistentry>
|
---|
| 133 | </variablelist>
|
---|
[673b0d8] | 134 |
|
---|
| 135 | </sect2>
|
---|
| 136 |
|
---|
| 137 | </sect1>
|
---|
[81fd230] | 138 |
|
---|