diff options
author | Colin Watson <cjwatson@debian.org> | 2022-10-07 22:11:05 +0100 |
---|---|---|
committer | Colin Watson <cjwatson@debian.org> | 2022-10-07 22:11:05 +0100 |
commit | 9c94afd5a40f3d70cba01a5ba07e84fe7ed7a210 (patch) | |
tree | 0c4032c90da5a2bea2fe62a30a6a2f2e9bfa4863 | |
parent | 78ada4d2cf0a46c2ec2ae15dc21f36f981f54d79 (diff) |
Fix build on systems without <termios.h>
* bootstrap.conf (gnulib_modules): Add termios.
* src/man.c (get_term): Replace with a no-op stub if the system has no
`<termios.h>` (Gnulib tests for it and can replace some functions, but
its replacement isn't sufficient here).
-rw-r--r-- | bootstrap.conf | 1 | ||||
-rw-r--r-- | src/man.c | 6 |
2 files changed, 7 insertions, 0 deletions
diff --git a/bootstrap.conf b/bootstrap.conf index dc8e4792..203d6951 100644 --- a/bootstrap.conf +++ b/bootstrap.conf @@ -75,6 +75,7 @@ gnulib_modules=" strerror strsep tempname + termios timespec unlinkat utimens @@ -640,6 +640,7 @@ static void gripe_no_name (const char *sect) exit (FAIL); } +#ifdef HAVE_TERMIOS_H static struct termios tms; static int tms_set = 0; static pid_t tms_pid = 0; @@ -669,6 +670,11 @@ static void get_term (void) } } } +#else /* !HAVE_TERMIOS_H */ +static void get_term (void) +{ +} +#endif /* HAVE_TERMIOS_H */ #if defined(TROFF_IS_GROFF) || defined(HEIRLOOM_NROFF) static int get_roff_line_length (void) |