编译GDB时出现错误:error: no enhanced curses library found;禁用途易



我试图在mingw中构建GDB 7.51进行跨平台调试,我发现GDB有TUI作为前端。总之,我用——enable-tui配置GDB,然后让stop总是显示错误信息:

configure: error: no enhanced curses library found;禁用TUI

我通过谷歌检查了这个问题,然后我从GNU下载了ncurses源代码

5.9 ncurses

构建并安装到我的c:/mingw/msys/1.0/local/

使用以下脚本语句运行GDB配置

export PATH=$PREFIX/gccbinutils/bin/:/usr/local/bin:/usr/bin:/bin:/mingw/bin
export C_INCLUDE_PATH=/usr/local/include:/usr/local/include/ncursest:/usr/include:/c/mingw/include
export CPLUS_INCLUDE_PATH=/usr/local/include:/usr/local/include/ncursest:/usr/include:/c/mingw/include
export LIBRARY_PATH=/usr/local/lib:/usr/lib:/c/mingw/lib
export LD_LIBRARY_PATH=/usr/local/lib:/usr/lib:/c/mingw/lib
export LDFLAGS="-L/usr/local/lib -L/usr/lib -L/c/mingw/lib"
export LIBS="-lncursest"
$BUILD_MIPSGCCDIR/gdb/configure --prefix=$PREFIX/$pkg --target=$TARGET 
                --enable-tui 
                            --enable-curses 
                --enable-sim > $BUILDPATH/$TARGET$pkg.conf1.$argn.log  2>&1

,但它没有工作。使用以下消息

checking for zlib.h... yes
checking for library containing dlgetmodinfo... no
checking for iconv... yes
checking for iconv declaration... install-shextern size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
checking for library containing waddstr... no
configure: error: no enhanced curses library found; disable TUI
make[1]: *** [configure-gdb] Error 1
make[1]: Leaving directory `/d/tools/buildmipsgcc/build_gdb'
make: *** [all] Error 2 

我已经搜索了waddstr,并且确定它存在于我的c:/mingw/msys/1.0/local/lib/libncursest.a.

好吧,让我们试着通过提供手写的libncurses.la来愚弄Autotools:

# libncurses.la - a libtool library file
# Generated by ltmain.sh (GNU libtool) 2.2.7a
#
# Please DO NOT delete this file!
# It is necessary for linking the library.
# The name that we can dlopen(3).
dlname=''
# Names of this library.
library_names=''
# The name of the static archive.
old_library='libncursest.a'
# Linker flags that can not go in dependency_libs.
inherited_linker_flags=''
# Libraries that this one depends upon.
dependency_libs=''
# Names of additional weak libraries provided by this library
weak_library_names=''
# Version information for libncurses.
current=5
age=0
revision=9
# Is this an already installed library?
installed=yes
# Should we warn about portability when linking against -modules?
shouldnotlink=no
# Files to dlopen/dlpreopen
dlopen=''
dlpreopen=''
# Directory that this library needs to be installed in:
libdir='c:/mingw/msys/1.0/local/lib'

检查我提供的路径和名称,如果它们不同-更改它们。如果它仍然不能工作,报告,我将尝试进一步扩展它,直到我们最终修复它。

相关内容

最新更新