Fix ncurses underlinking by using the pkg-config output instead of assuming -lncurses/-lncursesw to be enough. In addition, fix wrong modplug include directive. See also: https://bugs.gentoo.org/show_bug.cgi?id=573522 --- a/configure +++ b/configure @@ -215,7 +215,7 @@ exit 1 fi CFLAGS_main="-DAUDIO_OUTPUT=\\\"$CFG_AO\\\" -DCONFFILE=\\\"$CONFFILE\\\"" -LDFLAGS="$LDFLAGS -L$PREFIX/lib -l$CFG_CURSES_LIB" +LDFLAGS="$LDFLAGS -L$PREFIX/lib `${PKG_CONFIG} --libs $CFG_CURSES_LIB`" SRCS="audio_file audio_output_$CFG_AO config gui_browser gui_draw \ gui_input gui_msgbar gui_playq gui_vfslist main playq playq_party \ playq_xmms vfs vfs_playlist vfs_regular" --- a/src/audio_format_modplug.c +++ b/src/audio_format_modplug.c @@ -31,7 +31,7 @@ #include "stdinc.h" #include -#include +#include #include "audio_file.h" #include "audio_format.h" --- a/src/main.c +++ b/src/main.c @@ -165,7 +165,7 @@ #endif /* CLOSE_STDERR */ if ((errmsg = vfs_lockup()) != NULL) { gui_draw_init_abort(); - g_printerr(errmsg); + g_printerr("%s", errmsg); return (1); }