Accepting request 93114 from editors

- Add patch to use libtinfo if available

OBS-URL: https://build.opensuse.org/request/show/93114
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/emacs?expand=0&rev=71
This commit is contained in:
Stephan Kulow 2011-11-23 18:34:24 +00:00 committed by Git OBS Bridge
commit fa814082fa
3 changed files with 52 additions and 0 deletions

45
emacs-23.3-tinfo.dif Normal file
View File

@ -0,0 +1,45 @@
--- configure.in
+++ configure.in 2011-11-22 14:37:39.195146873 +0000
@@ -2376,11 +2376,13 @@ AC_CHECK_FUNCS(getpt)
# That is because we have not set up to link ncurses in lib-src.
# It's better to believe a function is not available
# than to expect to find it in ncurses.
-AC_CHECK_LIB(ncurses, tparm)
+for lib in tinfo ncurses ; do
+ AC_CHECK_LIB($lib, tparm)
+done
case "$opsys" in
netbsd)
- AC_SEARCH_LIBS(tputs, [ncurses terminfo termcap])
+ AC_SEARCH_LIBS(tputs, [tinfo ncurses ncursesw terminfo termcap])
if test $ac_cv_search_tputs = -lterminfo; then
AC_DEFINE(TERMINFO, 1, [Define to 1 if you use terminfo instead of termcap.])
fi
--- src/config.in
+++ src/config.in 2011-11-22 14:34:49.199647061 +0000
@@ -388,6 +388,9 @@ along with GNU Emacs. If not, see <http
/* Define to 1 if you have the `ncurses' library (-lncurses). */
#undef HAVE_LIBNCURSES
+/* Define to 1 if you have the `tinfo' library (-ltinfo). */
+#undef HAVE_LIBTINFO
+
/* Define to 1 if using libotf. */
#undef HAVE_LIBOTF
--- src/s/gnu-linux.h
+++ src/s/gnu-linux.h 2011-11-22 14:36:11.327146051 +0000
@@ -230,8 +230,12 @@ along with GNU Emacs. If not, see <http
#ifdef HAVE_LIBNCURSES
#define TERMINFO
+#ifdef HAVE_LIBTINFO
+#define LIBS_TERMCAP -ltinfo
+#else
#define LIBS_TERMCAP -lncurses
#endif
+#endif
#define UNEXEC unexelf.o

View File

@ -1,3 +1,8 @@
-------------------------------------------------------------------
Tue Nov 22 14:40:45 UTC 2011 - werner@suse.de
- Add patch to use libtinfo if available
-------------------------------------------------------------------
Sun Oct 2 14:36:52 CEST 2011 - dmueller@suse.de

View File

@ -54,6 +54,7 @@ Patch9: emacs-22.0.99-sendmail-path.patch
Patch11: emacs-22.0.99-xim.patch
Patch12: emacs-22.0.99-x11r7.patch
Patch13: emacs-23.3-s390x.dif
Patch14: emacs-23.3-tinfo.dif
Patch15: emacs-22.2-iconic.patch
Patch16: emacs-23.1-flyspell.patch
Patch18: emacs-sparc.diff
@ -160,6 +161,7 @@ modes.
%patch11 -p0 -b .xim
%patch12 -p0 -b .x11r7
%patch13 -p0 -b .s390x
%patch14 -p0 -b .tinfo
%patch15 -p0 -b .iconic
%patch16 -p0 -b .flyspell
%patch