expect.xml 5.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159
  1. <?xml version="1.0" encoding="ISO-8859-1"?>
  2. <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
  3. "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
  4. <!ENTITY % general-entities SYSTEM "../general.ent">
  5. %general-entities;
  6. ]>
  7. <sect1 id="ch-tools-expect" role="wrap">
  8. <?dbhtml filename="expect.html"?>
  9. <sect1info condition="script">
  10. <productname>expect</productname>
  11. <productnumber>&expect-version;</productnumber>
  12. <address>&expect-url;</address>
  13. </sect1info>
  14. <title>Expect-&expect-version;</title>
  15. <indexterm zone="ch-tools-expect">
  16. <primary sortas="a-Expect">Expect</primary>
  17. </indexterm>
  18. <sect2 role="package">
  19. <title/>
  20. <para>The Expect package contains a program for carrying out scripted
  21. dialogues with other interactive programs.</para>
  22. <segmentedlist>
  23. <segtitle>&buildtime;</segtitle>
  24. <segtitle>&diskspace;</segtitle>
  25. <seglistitem>
  26. <seg>&expect-ch5-sbu;</seg>
  27. <seg>&expect-ch5-du;</seg>
  28. </seglistitem>
  29. </segmentedlist>
  30. </sect2>
  31. <sect2 role="installation">
  32. <title>Installation of Expect</title>
  33. <para>First, force Expect's configure script to use <filename>/bin/stty</filename>
  34. instead of a <filename>/usr/local/bin/stty</filename> it may find on the host system.
  35. This will ensure that our test suite tools remain sane for the final builds of our
  36. toolchain:</para>
  37. <screen><userinput remap="pre">cp -v configure{,.orig}
  38. sed 's:/usr/local/bin:/bin:' configure.orig &gt; configure</userinput></screen>
  39. <para>Now prepare Expect for compilation:</para>
  40. <screen><userinput remap="configure">./configure --prefix=/tools --with-tcl=/tools/lib \
  41. --with-tclinclude=/tools/include</userinput></screen>
  42. <variablelist>
  43. <title>The meaning of the configure options:</title>
  44. <varlistentry>
  45. <term><parameter>--with-tcl=/tools/lib</parameter></term>
  46. <listitem>
  47. <para>This ensures that the configure script finds the Tcl
  48. installation in the temporary tools location instead of possibly
  49. locating an existing one on the host system.</para>
  50. </listitem>
  51. </varlistentry>
  52. <varlistentry>
  53. <term><parameter>--with-tclinclude=/tools/include</parameter></term>
  54. <listitem>
  55. <para>This explicitly tells Expect where to find Tcl's internal
  56. headers. Using this option avoids conditions where
  57. <command>configure</command> fails because it cannot automatically
  58. discover the location of Tcl's headers.</para>
  59. </listitem>
  60. </varlistentry>
  61. </variablelist>
  62. <para>Build the package:</para>
  63. <screen><userinput remap="make">make</userinput></screen>
  64. <para>Compilation is now complete. As discussed earlier, running the test
  65. suite is not mandatory for the temporary tools here in this chapter. To run
  66. the Expect test suite anyway, issue the following command:</para>
  67. <screen><userinput remap="test">make test</userinput></screen>
  68. <para>Note that the Expect test suite is known to experience failures under
  69. certain host conditions that are not within our control. Therefore,
  70. test suite failures here are not surprising and are not considered
  71. critical.</para>
  72. <para>Install the package:</para>
  73. <screen><userinput remap="install">make SCRIPTS="" install</userinput></screen>
  74. <variablelist>
  75. <title>The meaning of the make parameter:</title>
  76. <varlistentry>
  77. <term><parameter>SCRIPTS=""</parameter></term>
  78. <listitem>
  79. <para>This prevents installation of the supplementary Expect
  80. scripts, which are not needed.</para>
  81. </listitem>
  82. </varlistentry>
  83. </variablelist>
  84. </sect2>
  85. <sect2 id="contents-expect" role="content">
  86. <title>Contents of Expect</title>
  87. <segmentedlist>
  88. <segtitle>Installed program</segtitle>
  89. <segtitle>Installed library</segtitle>
  90. <seglistitem>
  91. <seg>expect</seg>
  92. <seg>libexpect-&expect-lib-version;.a</seg>
  93. </seglistitem>
  94. </segmentedlist>
  95. <variablelist>
  96. <bridgehead renderas="sect3">Short Descriptions</bridgehead>
  97. <?dbfo list-presentation="list"?>
  98. <?dbhtml list-presentation="table"?>
  99. <varlistentry id="expect">
  100. <term><command>expect</command></term>
  101. <listitem>
  102. <para>Communicates with other interactive programs according
  103. to a script</para>
  104. <indexterm zone="ch-tools-expect expect">
  105. <primary sortas="b-expect">expect</primary>
  106. </indexterm>
  107. </listitem>
  108. </varlistentry>
  109. <varlistentry id="libexpect">
  110. <term><filename class="libraryfile">libexpect-&expect-lib-version;.a</filename></term>
  111. <listitem>
  112. <para>Contains functions that allow Expect to be used as a Tcl
  113. extension or to be used directly from C or C++ (without Tcl)</para>
  114. <indexterm zone="ch-tools-expect libexpect">
  115. <primary sortas="c-libexpect-&expect-lib-version;">libexpect-&expect-lib-version;</primary>
  116. </indexterm>
  117. </listitem>
  118. </varlistentry>
  119. </variablelist>
  120. </sect2>
  121. </sect1>