From 9f2d4b1caac222df538fd794c3daca74ad4b5a59 Mon Sep 17 00:00:00 2001 From: "Yann E. MORIN" Date: Thu, 4 Jul 2013 21:26:19 +0200 Subject: [PATCH] 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" --- configure.ac | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) 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]) -- 2.39.5