http://expect.sourceforge.net/
I've just tried this on a 16.04, but it should work on older versions of Ubuntu as well.
http://www.activestate.com/activetcl/downloads
Download and extract the files, then cd
into the extracted directory and run ./install.sh
(with root permissions).
Follow the installation instructions and put everything under the default directory (/opt
).
https://sourceforge.net/projects/expect/files/Expect/
Extract the contents into /opt
.
From the installation directory (example /opt/expect5.45/
), run the following commands:
$ sudo ./configure \
--with-tcl=/opt/ActiveTcl-8.6/lib/tcl8.6 \
--with-tclinclude=/opt/ActiveTcl-8.6/include/tcl8.6 \
--with-tk=/opt/ActiveTcl-8.6/lib/tcl8.6 \
--with-tkinclude=/opt/ActiveTcl-8.6/include/tcl8.6
$ sudo make && sudo make install
To have the final executable globally available, create a symlink for it:
$ sudo ln -s /opt/expect5.45/expect /usr/bin/expect
On ubuntu 16 I tried to install, but the error it gave was:
I edited this to run and was able to proceed with the install.