expect.xml 5.2 KB

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