aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGlenn Morris2012-04-30 21:07:14 -0400
committerGlenn Morris2012-04-30 21:07:14 -0400
commita4a18b8bbef0fe4265d675f9c56ea17566566484 (patch)
tree7fc675b0a404391024a5e8e6d6cd87005330e523
parent3ba0a545ecf6e8385ffb65033015be0b16e0226f (diff)
downloademacs-a4a18b8bbef0fe4265d675f9c56ea17566566484.tar.gz
emacs-a4a18b8bbef0fe4265d675f9c56ea17566566484.zip
Use libtinfo in preference to libncurses (bug#9741)
* configure.in: Try libtinfo for tputs. (LIBS_TERMCAP) [gnu*]: Use libtinfo if it was found. * etc/NEWS: Mention this.
-rw-r--r--ChangeLog3
-rw-r--r--configure.in13
-rw-r--r--etc/NEWS3
3 files changed, 16 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index 137248c0d89..109132d0f98 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
12012-05-01 Glenn Morris <rgm@gnu.org> 12012-05-01 Glenn Morris <rgm@gnu.org>
2 2
3 * configure.in: Try libtinfo for tputs.
4 (LIBS_TERMCAP) [gnu*]: Use libtinfo if it was found. (Bug#9741)
5
3 * configure.in: Combine adjacent $opsys case blocks. 6 * configure.in: Combine adjacent $opsys case blocks.
4 7
5 * configure.in (LIBS_TERMCAP): Remove unreachable branch for sol2. 8 * configure.in (LIBS_TERMCAP): Remove unreachable branch for sol2.
diff --git a/configure.in b/configure.in
index 42a6b3364c9..4ad5efbb811 100644
--- a/configure.in
+++ b/configure.in
@@ -2868,7 +2868,7 @@ AC_DEFUN([tputs_link_source], [
2868]) 2868])
2869# Maybe curses should be tried earlier? 2869# Maybe curses should be tried earlier?
2870# See http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9736#35 2870# See http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9736#35
2871for tputs_library in '' ncurses terminfo termcap curses; do 2871for tputs_library in '' tinfo ncurses terminfo termcap curses; do
2872 OLIBS=$LIBS 2872 OLIBS=$LIBS
2873 if test -z "$tputs_library"; then 2873 if test -z "$tputs_library"; then
2874 LIBS_TERMCAP= 2874 LIBS_TERMCAP=
@@ -2888,7 +2888,8 @@ done
2888AC_MSG_RESULT([$msg]) 2888AC_MSG_RESULT([$msg])
2889if test "X$msg" = Xno; then 2889if test "X$msg" = Xno; then
2890 AC_MSG_ERROR([The required function `tputs' was not found in any library. 2890 AC_MSG_ERROR([The required function `tputs' was not found in any library.
2891These libraries were tried: libncurses, libterminfo, libtermcap, libcurses. 2891The following libraries were tried (in order):
2892 libtinfo, libncurses, libterminfo, libtermcap, libcurses
2892Please try installing whichever of these libraries is most appropriate 2893Please try installing whichever of these libraries is most appropriate
2893for your system, together with its header files. 2894for your system, together with its header files.
2894For example, a libncurses-dev(el) or similar package.]) 2895For example, a libncurses-dev(el) or similar package.])
@@ -2897,12 +2898,18 @@ fi
2897## Use termcap instead of terminfo? 2898## Use termcap instead of terminfo?
2898## Only true for: freebsd < 40000, ms-w32, msdos, netbsd < 599002500. 2899## Only true for: freebsd < 40000, ms-w32, msdos, netbsd < 599002500.
2899TERMINFO=yes 2900TERMINFO=yes
2901## FIXME? In the cases below where we unconditionally set
2902## LIBS_TERMCAP="-lncurses", this overrides LIBS_TERMCAP = -ltinfo,
2903## if that was found above to have tputs.
2904## Should we use the gnu* logic everywhere?
2900case "$opsys" in 2905case "$opsys" in
2901 ## darwin: Prevents crashes when running Emacs in Terminal.app under 10.2. 2906 ## darwin: Prevents crashes when running Emacs in Terminal.app under 10.2.
2902 ## The ncurses library has been moved out of the System framework in 2907 ## The ncurses library has been moved out of the System framework in
2903 ## Mac OS X 10.2. So if configure detects it, set the command-line 2908 ## Mac OS X 10.2. So if configure detects it, set the command-line
2904 ## option to use it. 2909 ## option to use it.
2905 darwin|gnu*) LIBS_TERMCAP="-lncurses" ;; 2910 darwin) LIBS_TERMCAP="-lncurses" ;;
2911
2912 gnu*) [ "x$LIBS_TERMCAP" = x ] && LIBS_TERMCAP="-lncurses" ;;
2906 2913
2907 freebsd) 2914 freebsd)
2908 AC_MSG_CHECKING([whether FreeBSD is new enough to use terminfo]) 2915 AC_MSG_CHECKING([whether FreeBSD is new enough to use terminfo])
diff --git a/etc/NEWS b/etc/NEWS
index ce3cfe7accf..ef809aad4e4 100644
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -29,6 +29,9 @@ possibly-questionable C code. On a recent GNU system there should be
29no warnings; on older and on non-GNU systems the generated warnings 29no warnings; on older and on non-GNU systems the generated warnings
30may be useful. 30may be useful.
31 31
32---
33** Emacs uses libtinfo in preference to libncurses, if available.
34
32 35
33* Startup Changes in Emacs 24.2 36* Startup Changes in Emacs 24.2
34 37