gcc -g -o test test.o libnewt.a -lncurses -lslang -lm -static /usr/lib/gcc-lib/i386-pc-linux-uclibc/3.3.4/../../../libslang.a(sldisply.o)(.text+0x20ba): In function `SLtt_tgetstr': : undefined reference to `tgetstr' /usr/lib/gcc-lib/i386-pc-linux-uclibc/3.3.4/../../../libslang.a(sldisply.o)(.text+0x22bb): In function `SLtt_initialize': : undefined reference to `tgetent' /usr/lib/gcc-lib/i386-pc-linux-uclibc/3.3.4/../../../libslang.a(sldisply.o)(.text+0x2106): In function `SLtt_tgetnum': : undefined reference to `tgetnum' /usr/lib/gcc-lib/i386-pc-linux-uclibc/3.3.4/../../../libslang.a(sldisply.o)(.text+0x211d): In function `SLtt_tgetflag': : undefined reference to `tgetflag' collect2: ld returned 1 exit status make: *** [test] Error 1 rm textbox.o checkbox.o checkboxtree.o windows.o grid.o scrollbar.o entry.o form.o scale.o label.o button.o listbox.o buttonbar.o !!! ERROR: dev-libs/newt-0.50.35-r3 failed. !!! Function src_compile, Line 30, Exitcode 2 !!! make failure !!! If you need support, post the topmost build error, NOT this status message.
adding this: sed -i -e 's:LIBS = -lslang -lm:LIBS = -lslang -lncurses:g' ${S}/Makefile to the ebuild just after the econf line fixes it.
I put a better fix into CVS after looking at the build system for newt.