From: Yann E. MORIN Date: Thu, 4 Jul 2013 19:26:19 +0000 (+0200) Subject: configure: look for libtinfo before looking for libncurses X-Git-Tag: v3.13.0.0~3 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=9f2d4b1caac222df538fd794c3daca74ad4b5a59;p=kconfig-frontends configure: look for libtinfo before looking for libncurses In case of static linking, we need to check for -ltinfo before we check for -lncurses, so that -ltinfo comes *after* -lncurses in the link command. Signed-off-by: "Yann E. MORIN" --- diff --git a/configure.ac b/configure.ac index 2f1817e..1595276 100644 --- a/configure.ac +++ b/configure.ac @@ -290,6 +290,10 @@ AS_IF( AS_CASE( [$CURSES_LOC], [ncursesw/*],[ncurses_mconf_CPPFLAGS="$ncurses_mconf_CPPFLAGS -DNCURSES_WIDECHAR=1"]) + AC_SEARCH_LIBS( + [setupterm], + [tinfo], + [break]) AC_SEARCH_LIBS( [initscr], [ncursesw ncurses curses], @@ -300,10 +304,6 @@ AS_IF( [test "$need_curses" = "yes"], [AC_MSG_ERROR([could not find curses library (frontends: mconf/nconf)])], [has_curses=no])]) - AC_SEARCH_LIBS( - [setupterm], - [tinfo], - [break]) ncurses_LIBS="$LIBS" LIBS=$LIBS_old])