libncurses.so.5:添加符号时出错:安装omnitty时从命令行中缺少DSO

问题描述:

我在安装有Ubuntu的AWS ec2实例上安装omnittylibncurses.so.5:添加符号时出错:安装omnitty时从命令行中缺少DSO

# uname -a 

    Linux ip-172-31-37-63 4.4.0-1038-aws #47-Ubuntu SMP Thu Sep 28 20:05:35 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux 

四处错误:

# make 
gcc -g -O2 -I/usr/local/include -Wall -DOMNITTY_VERSION=\"0.3.0\" -o omnitty minibuf.o machine.o main.o machmgr.o help.o menu.o curutil.o -L/usr/local/lib -lrote 
/usr/bin/ld: help.o: undefined reference to symbol '[email protected]@NCURSES_5.0.19991023' 
//lib/x86_64-linux-gnu/libncurses.so.5: error adding symbols: DSO missing from command line 
collect2: error: ld returned 1 exit status 
Makefile:18: recipe for target 'omnitty' failed 
make: *** [omnitty] Error 1 
+0

这将是有些用途? ......#readelf -s /lib/x86_64-linux-gnu/libncurses.so.5 | grep delwin @@ NCURSES_5.0.19991023 161:0000000000009e60 182 FUNC GLOBAL DEFAULT 13 delwin @@ NCURSES_5.0.19991023 –

+0

因为我的回答是正确的,所以我的问题也应该是正确的,如果你觉得它是正确的,请从-1回复它。否则让我知道为什么它被downvoted –

找到解决方案:

增加-lncurses和-ltinfo Makefile中

Makefile文件看起来是这样的:

omnitty: $(objects) 
     $(CC) $(CFLAGS) -o omnitty $(objects) $(LDFLAGS) $(LIBS) -lncurses -ltinfo 
+0

因为我的答案是正确的,那么我的问题也应该是正确的,如果你觉得它是正确的,请将它从-1返回,否则让我知道为什么它已被downvoted –