From 9da43a4bfc4f2923d22b52d2c525b898714e6000 Mon Sep 17 00:00:00 2001 From: wilson Date: Sun, 31 Aug 1997 01:48:33 +0000 Subject: Fix Freedbsd build problem with patch from more recent texinfo sources. * info/terminal.c (terminal_prep_terminal): Only use OCRNL and ONLCR if they are defined. Reported by many people. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@15003 138bc75d-0d04-0410-961f-82ee72b054a4 --- texinfo/ChangeLog | 5 +++++ texinfo/info/terminal.c | 9 ++++++++- 2 files changed, 13 insertions(+), 1 deletion(-) (limited to 'texinfo') diff --git a/texinfo/ChangeLog b/texinfo/ChangeLog index 0e6fe7617d7..aea2b3864d8 100644 --- a/texinfo/ChangeLog +++ b/texinfo/ChangeLog @@ -16,6 +16,11 @@ Mon May 26 12:44:43 1997 Ian Lance Taylor * texinfo.tex: Update to newest FSF version (2.201). +Fri Mar 14 15:05:17 1997 Karl Berry + + * info/terminal.c (terminal_prep_terminal): Only use OCRNL and + ONLCR if they are defined. Reported by many people. + Wed Feb 12 11:15:16 1997 Michael Meissner * util/texindex.c (main): Make main an int function, not void. diff --git a/texinfo/info/terminal.c b/texinfo/info/terminal.c index 9c1017696c6..7275d00cb5b 100644 --- a/texinfo/info/terminal.c +++ b/texinfo/info/terminal.c @@ -637,7 +637,14 @@ terminal_prep_terminal () #if defined (HAVE_TERMIOS_H) || defined (HAVE_TERMIO_H) ttybuff.c_iflag &= (~ISTRIP & ~INLCR & ~IGNCR & ~ICRNL & ~IXON); - ttybuff.c_oflag &= (~ONLCR & ~OCRNL); +/* These output flags are not part of POSIX, so only use them if they + are defined. */ +#ifdef ONLCR + ttybuff.c_oflag &= ~ONLCR ; +#endif +#ifdef OCRNL + ttybuff.c_oflag &= ~OCRNL; +#endif ttybuff.c_lflag &= (~ICANON & ~ECHO); ttybuff.c_cc[VMIN] = 1; -- cgit v1.2.1