linux 下安装 ncurses

$wget ftp://invisible-island.net/ncurses/ncurses-5.9.tar.gz

$tar -zxvf ncurses-5.9.tar.gz

$./configure

$make & make install

执行到中途,提示:

/bin/sh: -I../c++: 没有那个文件或目录
make[1]: *** [../objects/cursesf.o] 错误 127
make[1]: Leaving directory `/root/ncurses-5.9/c++'
make: *** [all] 错误 2

这个问题纠结了好长时间,在http://forums.gentoo.org/viewtopic-p-2641060.html找到相关的,但是发现是gentoo系统。不过也试了试安装g++,下载g++源码时发现完整的包有78M,就偷懒下了个gcc-g++-xxx.tar.gz。最后解压发现不完整,根本不能编译。

最后才在http://lists.gnu.org/archive/html/bug-ncurses/2007-03/msg00048.html找到答案。

If you don't have a c++ compilter, try adding --without-cxx to your
./configure line.

安装ncurse
$./configure --without-cxx  这句话重点
$make & make install

提示

/usr/local/lib/liblua.a(loadlib.o): In function `ll_loadfunc':
loadlib.c:(.text+0x7d4): undefined reference to `dlsym'
loadlib.c:(.text+0x7e2): undefined reference to `dlerror'
loadlib.c:(.text+0x8ad): undefined reference to `dlopen'
loadlib.c:(.text+0x8c3): undefined reference to `dlerror'
/usr/local/lib/liblua.a(loadlib.o): In function `gctm':
loadlib.c:(.text+0xdbc): undefined reference to `dlclose'
collect2: ld 返回 1
make[1]: *** [objs/nginx] 错误 1
make[1]: Leaving directory `/root/nginx-1.2.7'
make: *** [install] 错误 2
 

猜你喜欢

转载自blog.csdn.net/qq_38287952/article/details/83377621
今日推荐