Complete.Org: Mailing Lists: Archives: freeciv-dev: December 2004:
[Freeciv-Dev] (PR#11443) tinfo support patch from ALT Linux
Home

[Freeciv-Dev] (PR#11443) tinfo support patch from ALT Linux

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: evyscr@xxxxxxxxx
Subject: [Freeciv-Dev] (PR#11443) tinfo support patch from ALT Linux
From: "Jason Short" <jdorje@xxxxxxxxxxxxxxxxxxxxx>
Date: Sun, 12 Dec 2004 18:53:25 -0800
Reply-to: bugs@xxxxxxxxxxx

<URL: http://bugs.freeciv.org/Ticket/Display.html?id=11443 >

Here's a patch that reverses the order of checks (to keep the current
order of precedence).  I think this is ok.

We can add a check for tinfo to 2.0 but it should have the lowest
precedence (rather than the highest which this gives it).

-jason

Index: m4/readline.m4
===================================================================
RCS file: /home/freeciv/CVS/freeciv/m4/readline.m4,v
retrieving revision 1.3
diff -u -r1.3 readline.m4
--- m4/readline.m4      31 Jan 2004 17:49:52 -0000      1.3
+++ m4/readline.m4      13 Dec 2004 02:49:44 -0000
@@ -87,12 +87,17 @@
                dnl We give them a hand by trying to guess what might be needed.
                dnl
                dnl Some older Unices may need both -lcurses and -ltermlib,
-               dnl but we don't support that just yet....
-
-               AC_CHECK_LIB(termlib, tgetent, HAVE_TERMCAP="-ltermlib")
-               AC_CHECK_LIB(termcap, tgetent, HAVE_TERMCAP="-ltermcap")
-               AC_CHECK_LIB(curses, tgetent, HAVE_TERMCAP="-lcurses")
-               AC_CHECK_LIB(ncurses, tgetent, HAVE_TERMCAP="-lncurses")
+               dnl but we don't support that just yet.  This check will take
+               dnl the first lib that it finds and just link to that.
+               AC_CHECK_LIB(tinfo, tgetent, HAVE_TERMCAP="-ltinfo",
+                 AC_CHECK_LIB(ncurses, tgetent, HAVE_TERMCAP="-lncurses",
+                   AC_CHECK_LIB(curses, tgetent, HAVE_TERMCAP="-lcurses",
+                     AC_CHECK_LIB(termcap, tgetent, HAVE_TERMCAP="-ltermcap",
+                       AC_CHECK_LIB(termlib, tgetent, HAVE_TERMCAP="-ltermlib")
+                     )
+                   )
+                 )
+               )
 
                if test x"$HAVE_TERMCAP" != "x"; then
                    dnl We can't check for completion_matches() again,

[Prev in Thread] Current Thread [Next in Thread]