#cd /usr/local/
首先安装tcl,
下载地址如下 https://jaist.dl.sourceforge.net/project/tcl/Tcl/8.4.11/tcl8.4.11-src.tar.gz
expect的下载地址: https://jaist.dl.sourceforge.net/project/expect/Expect/5.45/expect5.45.tar.gz
安装tcl:
#tar -zxvf tcl8.4.11-src.tar.gz
#cd ./tcl8.4.11/unix/ #./configure
#make && make install
安装expect:
#tar -zxvf expect5.45.tar.gz
#cd expect5.45
#./configure --prefix=/usr/local/expect5.45/ --with-tcl=/usr/local/tcl8.4.11/unix/ --with-tclinclude=/usr/local/tcl8.4.11/generic/ --enable-shared
checking for correct TEA configuration... ok (TEA 3.9) configure: configuring expect 5.45 checking for Tcl configuration... found //usr/local/tcl8.4.11/unix/tclConfig.sh checking for existence of //usr/local/tcl8.4.11/unix/tclConfig.sh... loading configure: --exec-prefix defaulting to TCL_EXEC_PREFIX /usr/local …… checking sys/param.h usability... yes checking sys/param.h presence... yes checking for sys/param.h... yes configure: creating ./config.status config.status: creating Makefile
#make && make install
#ln -s /usr/local/bin/expect /usr/bin/expect
# whereis tcl
tcl: /usr/lib/tcl8.4 /usr/local/lib/tcl8.4 /usr/share/tcl8.4
# whereis expect
expect: /usr/local/expect5.45 #
- 上一篇: 每天编程2小时——Python语言
- 下一篇: 用expect文件同步脚本实现升级自动化
评论