From 230335c43abb50996fa8755bce454c96b10c397a Mon Sep 17 00:00:00 2001 From: Pedro Alves Date: Sun, 10 Aug 2008 19:17:42 +0000 Subject: Build fixes for DJGPP. * signals.c (rl_set_sighandler): Guard access to SIGWINCH. * wcwidth.c [__GO32__]: Include wctype.h before wchar.h. --- readline/ChangeLog.gdb | 7 +++++++ readline/signals.c | 4 ++++ readline/support/wcwidth.c | 5 +++++ 3 files changed, 16 insertions(+) (limited to 'readline') diff --git a/readline/ChangeLog.gdb b/readline/ChangeLog.gdb index 1a1dfc9..be626e5 100644 --- a/readline/ChangeLog.gdb +++ b/readline/ChangeLog.gdb @@ -1,3 +1,10 @@ +2008-08-10 Pedro Alves + + Build fixes for DJGPP. + + * signals.c (rl_set_sighandler): Guard access to SIGWINCH. + * wcwidth.c [__GO32__]: Include wctype.h before wchar.h. + 2008-03-24 Jan Kratochvil PR gdb/544 diff --git a/readline/signals.c b/readline/signals.c index f344ed8..2dca03f 100644 --- a/readline/signals.c +++ b/readline/signals.c @@ -251,7 +251,11 @@ rl_set_sighandler (sig, handler, ohandler) struct sigaction act; act.sa_handler = handler; +#if defined (SIGWINCH) act.sa_flags = (sig == SIGWINCH) ? SA_RESTART : 0; +#else + act.sa_flags = 0; +#endif sigemptyset (&act.sa_mask); sigemptyset (&ohandler->sa_mask); sigaction (sig, &act, &old_handler); diff --git a/readline/support/wcwidth.c b/readline/support/wcwidth.c index ace9a3a..36433d7 100644 --- a/readline/support/wcwidth.c +++ b/readline/support/wcwidth.c @@ -6,6 +6,11 @@ * Markus Kuhn -- 2001-09-08 -- public domain */ +#ifdef __GO32__ +/* DJGPP needs to include this before including wchar.h. */ +# include +#endif + #include struct interval { -- cgit v1.1