When statically linking ncurses, one would expect that "pkg-config --static --libs ncurses" would provide the appropriate lines for all of the necessary libraries. However, that returns "-lncurses", suggesting that libncurses.a is the only library that needs to be linked. However, libtinfo.a is also required. This can be most easily observed from the dynamic library's NEEDED entries:<br />
<br />
$ objdump -x /usr/lib64/libncurses.so | grep NEEDED<br />
NEEDED libc.so.6<br />
NEEDED libdl.so.2<br />
NEEDED libtinfo.so.5
↧