On 10/08/2011 07:56 PM, Thomas Dickey wrote: > On Sat, 8 Oct 2011, Sven Joachim wrote: > >> On 2011-10-08 16:14 +0200, Sven Joachim wrote: >> >>> Package: libncurses5-dev >>> Version: 5.9-2 >>> Severity: serious >>> X-Debbugs-CC: Matthias Klose <d...@debian.org> >>> >>> Static linking with -lncurses fails if you need symbols from libtinfo: >>> >>> ,---- >>> | $ cat foo.c >>> | #include <term.h> >>> | #include <stdlib.h> >>> | >>> | int main(void) >>> | { >>> | return tgetent(NULL, ""); >>> | } >>> | $ LANG=C gcc foo.c -lncurses -static >>> | /tmp/ccRe0RW2.o: In function `main': >>> | foo.c:(.text+0x19): undefined reference to `tgetent' >>> | collect2: ld returned 1 exit status >>> `---- >>> >>> This makes zsh and possibly a few other packages FTBFS. >> >> So maybe we need to "append" each libtinfo.a to libncurses{,w}.a, like >> this: >> >> ar xo libtinfo.a && ar sr libncurses.a *.o && rm -f *.o >> >> Any less ugly ideas? > > If zsh used pkg-config, it could use today's update (ncurses patch) > > pkg-config --static --libs ncurses > > That's one path forward... > > But most of your FTBFS's will be only looking for "-lncurses", not > supposing that tgetent would be in another library.
I like the idea of fixing pkg-config, and making the "few" packages to use it. Do you have an idea how many packages are affected? -- To UNSUBSCRIBE, email to debian-bugs-rc-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org