diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/Makefile.in | 84 | ||||
-rw-r--r-- | src/man.c | 65 | ||||
-rw-r--r-- | src/mandb.c | 9 | ||||
-rw-r--r-- | src/manp.c | 25 | ||||
-rw-r--r-- | src/tests/Makefile.am | 6 | ||||
-rw-r--r-- | src/tests/Makefile.in | 97 | ||||
-rwxr-xr-x | src/tests/man-recode-in-place | 15 | ||||
-rwxr-xr-x | src/tests/man-recode-suffix | 10 | ||||
-rwxr-xr-x | src/tests/manconv-coding-tags | 18 | ||||
-rwxr-xr-x | src/tests/manconv-guess-from-encoding | 4 | ||||
-rwxr-xr-x | src/tests/manconv-incomplete-char-at-eof | 4 | ||||
-rwxr-xr-x | src/tests/manconv-odd-combinations | 44 | ||||
-rwxr-xr-x | src/tests/manpath-slash | 28 | ||||
-rw-r--r-- | src/tests/testlib.sh | 6 | ||||
-rw-r--r-- | src/ult_src.c | 2 |
15 files changed, 347 insertions, 70 deletions
diff --git a/src/Makefile.in b/src/Makefile.in index b462221b..cdc8e92a 100644 --- a/src/Makefile.in +++ b/src/Makefile.in @@ -125,9 +125,9 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/man-arg-automatic-create.m4 \ $(top_srcdir)/gl/m4/absolute-header.m4 \ $(top_srcdir)/gl/m4/alloca.m4 $(top_srcdir)/gl/m4/argp.m4 \ $(top_srcdir)/gl/m4/asm-underscore.m4 \ - $(top_srcdir)/gl/m4/btowc.m4 \ + $(top_srcdir)/gl/m4/assert_h.m4 $(top_srcdir)/gl/m4/btowc.m4 \ $(top_srcdir)/gl/m4/builtin-expect.m4 \ - $(top_srcdir)/gl/m4/calloc.m4 \ + $(top_srcdir)/gl/m4/c-bool.m4 $(top_srcdir)/gl/m4/calloc.m4 \ $(top_srcdir)/gl/m4/canonicalize.m4 \ $(top_srcdir)/gl/m4/chdir-long.m4 $(top_srcdir)/gl/m4/chown.m4 \ $(top_srcdir)/gl/m4/clock_time.m4 $(top_srcdir)/gl/m4/close.m4 \ @@ -139,6 +139,7 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/man-arg-automatic-create.m4 \ $(top_srcdir)/gl/m4/dup.m4 $(top_srcdir)/gl/m4/dup2.m4 \ $(top_srcdir)/gl/m4/eealloc.m4 $(top_srcdir)/gl/m4/environ.m4 \ $(top_srcdir)/gl/m4/errno_h.m4 $(top_srcdir)/gl/m4/error.m4 \ + $(top_srcdir)/gl/m4/error_h.m4 \ $(top_srcdir)/gl/m4/exponentd.m4 \ $(top_srcdir)/gl/m4/extensions.m4 \ $(top_srcdir)/gl/m4/extern-inline.m4 \ @@ -202,7 +203,7 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/man-arg-automatic-create.m4 \ $(top_srcdir)/gl/m4/mmap-anon.m4 $(top_srcdir)/gl/m4/mode_t.m4 \ $(top_srcdir)/gl/m4/msvc-inval.m4 \ $(top_srcdir)/gl/m4/msvc-nothrow.m4 \ - $(top_srcdir)/gl/m4/multiarch.m4 \ + $(top_srcdir)/gl/m4/multiarch.m4 $(top_srcdir)/gl/m4/musl.m4 \ $(top_srcdir)/gl/m4/nanosleep.m4 \ $(top_srcdir)/gl/m4/nl_langinfo.m4 $(top_srcdir)/gl/m4/nls.m4 \ $(top_srcdir)/gl/m4/nocrash.m4 \ @@ -236,10 +237,10 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/man-arg-automatic-create.m4 \ $(top_srcdir)/gl/m4/ssize_t.m4 \ $(top_srcdir)/gl/m4/stat-time.m4 $(top_srcdir)/gl/m4/stat.m4 \ $(top_srcdir)/gl/m4/stdalign.m4 $(top_srcdir)/gl/m4/stdarg.m4 \ - $(top_srcdir)/gl/m4/stdbool.m4 $(top_srcdir)/gl/m4/stddef_h.m4 \ - $(top_srcdir)/gl/m4/stdint.m4 $(top_srcdir)/gl/m4/stdint_h.m4 \ - $(top_srcdir)/gl/m4/stdio_h.m4 $(top_srcdir)/gl/m4/stdlib_h.m4 \ - $(top_srcdir)/gl/m4/stpcpy.m4 $(top_srcdir)/gl/m4/strcase.m4 \ + $(top_srcdir)/gl/m4/stddef_h.m4 $(top_srcdir)/gl/m4/stdint.m4 \ + $(top_srcdir)/gl/m4/stdint_h.m4 $(top_srcdir)/gl/m4/stdio_h.m4 \ + $(top_srcdir)/gl/m4/stdlib_h.m4 $(top_srcdir)/gl/m4/stpcpy.m4 \ + $(top_srcdir)/gl/m4/strcase.m4 \ $(top_srcdir)/gl/m4/strcasestr.m4 \ $(top_srcdir)/gl/m4/strchrnul.m4 $(top_srcdir)/gl/m4/strdup.m4 \ $(top_srcdir)/gl/m4/strerror.m4 \ @@ -278,7 +279,6 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/man-arg-automatic-create.m4 \ $(top_srcdir)/gl/m4/xalloc.m4 $(top_srcdir)/gl/m4/xgetcwd.m4 \ $(top_srcdir)/gl/m4/xsize.m4 $(top_srcdir)/gl/m4/xstrndup.m4 \ $(top_srcdir)/gl/m4/xvasprintf.m4 \ - $(top_srcdir)/gl/m4/year2038.m4 \ $(top_srcdir)/gl/m4/zzgnulib.m4 $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) @@ -494,6 +494,7 @@ APPLE_UNIVERSAL_BUILD = @APPLE_UNIVERSAL_BUILD@ AR = @AR@ ARFLAGS = @ARFLAGS@ ASM_SYMBOL_PREFIX = @ASM_SYMBOL_PREFIX@ +ASSERT_H = @ASSERT_H@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ @@ -507,6 +508,7 @@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CFLAG_VISIBILITY = @CFLAG_VISIBILITY@ +CLOCK_TIME_LIB = @CLOCK_TIME_LIB@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ CSCOPE = @CSCOPE@ @@ -516,6 +518,7 @@ DBLIBS = @DBLIBS@ DBTYPE = @DBTYPE@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ +DIR_HAS_FD_MEMBER = @DIR_HAS_FD_MEMBER@ DLLTOOL = @DLLTOOL@ DSYMUTIL = @DSYMUTIL@ DUMPBIN = @DUMPBIN@ @@ -536,8 +539,10 @@ FGREP = @FGREP@ FILECMD = @FILECMD@ FLOAT_H = @FLOAT_H@ FNMATCH_H = @FNMATCH_H@ +GETLOGIN_LIB = @GETLOGIN_LIB@ GETOPT_CDEFS_H = @GETOPT_CDEFS_H@ GETOPT_H = @GETOPT_H@ +GETRANDOM_LIB = @GETRANDOM_LIB@ GETTEXT_MACRO_VERSION = @GETTEXT_MACRO_VERSION@ GLOB_H = @GLOB_H@ GL_CFLAG_ALLOW_WARNINGS = @GL_CFLAG_ALLOW_WARNINGS@ @@ -634,6 +639,7 @@ GL_GNULIB_GETPAGESIZE = @GL_GNULIB_GETPAGESIZE@ GL_GNULIB_GETPASS = @GL_GNULIB_GETPASS@ GL_GNULIB_GETPASS_GNU = @GL_GNULIB_GETPASS_GNU@ GL_GNULIB_GETPEERNAME = @GL_GNULIB_GETPEERNAME@ +GL_GNULIB_GETPROGNAME = @GL_GNULIB_GETPROGNAME@ GL_GNULIB_GETRANDOM = @GL_GNULIB_GETRANDOM@ GL_GNULIB_GETSOCKNAME = @GL_GNULIB_GETSOCKNAME@ GL_GNULIB_GETSOCKOPT = @GL_GNULIB_GETSOCKOPT@ @@ -684,6 +690,7 @@ GL_GNULIB_MBSSEP = @GL_GNULIB_MBSSEP@ GL_GNULIB_MBSSPN = @GL_GNULIB_MBSSPN@ GL_GNULIB_MBSSTR = @GL_GNULIB_MBSSTR@ GL_GNULIB_MBSTOK_R = @GL_GNULIB_MBSTOK_R@ +GL_GNULIB_MBSTOWCS = @GL_GNULIB_MBSTOWCS@ GL_GNULIB_MBTOWC = @GL_GNULIB_MBTOWC@ GL_GNULIB_MDA_ACCESS = @GL_GNULIB_MDA_ACCESS@ GL_GNULIB_MDA_CHDIR = @GL_GNULIB_MDA_CHDIR@ @@ -731,6 +738,7 @@ GL_GNULIB_MEMCHR = @GL_GNULIB_MEMCHR@ GL_GNULIB_MEMMEM = @GL_GNULIB_MEMMEM@ GL_GNULIB_MEMPCPY = @GL_GNULIB_MEMPCPY@ GL_GNULIB_MEMRCHR = @GL_GNULIB_MEMRCHR@ +GL_GNULIB_MEMSET_EXPLICIT = @GL_GNULIB_MEMSET_EXPLICIT@ GL_GNULIB_MKDIR = @GL_GNULIB_MKDIR@ GL_GNULIB_MKDIRAT = @GL_GNULIB_MKDIRAT@ GL_GNULIB_MKDTEMP = @GL_GNULIB_MKDTEMP@ @@ -847,6 +855,7 @@ GL_GNULIB_SYMLINK = @GL_GNULIB_SYMLINK@ GL_GNULIB_SYMLINKAT = @GL_GNULIB_SYMLINKAT@ GL_GNULIB_SYSTEM_POSIX = @GL_GNULIB_SYSTEM_POSIX@ GL_GNULIB_TCGETSID = @GL_GNULIB_TCGETSID@ +GL_GNULIB_TIME = @GL_GNULIB_TIME@ GL_GNULIB_TIMEGM = @GL_GNULIB_TIMEGM@ GL_GNULIB_TIMESPEC_GET = @GL_GNULIB_TIMESPEC_GET@ GL_GNULIB_TIMESPEC_GETRES = @GL_GNULIB_TIMESPEC_GETRES@ @@ -922,6 +931,7 @@ GMSGFMT_015 = @GMSGFMT_015@ GNULIBHEADERS_OVERRIDE_WINT_T = @GNULIBHEADERS_OVERRIDE_WINT_T@ GNULIB_GETTIMEOFDAY = @GNULIB_GETTIMEOFDAY@ GREP = @GREP@ +HARD_LOCALE_LIB = @HARD_LOCALE_LIB@ HAVE_ACCEPT4 = @HAVE_ACCEPT4@ HAVE_ALIGNED_ALLOC = @HAVE_ALIGNED_ALLOC@ HAVE_ALLOCA_H = @HAVE_ALLOCA_H@ @@ -955,6 +965,7 @@ HAVE_DECL_GETLOGIN = @HAVE_DECL_GETLOGIN@ HAVE_DECL_GETLOGIN_R = @HAVE_DECL_GETLOGIN_R@ HAVE_DECL_GETPAGESIZE = @HAVE_DECL_GETPAGESIZE@ HAVE_DECL_GETUSERSHELL = @HAVE_DECL_GETUSERSHELL@ +HAVE_DECL_GETW = @HAVE_DECL_GETW@ HAVE_DECL_IMAXABS = @HAVE_DECL_IMAXABS@ HAVE_DECL_IMAXDIV = @HAVE_DECL_IMAXDIV@ HAVE_DECL_INITSTATE = @HAVE_DECL_INITSTATE@ @@ -962,6 +973,8 @@ HAVE_DECL_LOCALTIME_R = @HAVE_DECL_LOCALTIME_R@ HAVE_DECL_MEMMEM = @HAVE_DECL_MEMMEM@ HAVE_DECL_MEMRCHR = @HAVE_DECL_MEMRCHR@ HAVE_DECL_OBSTACK_PRINTF = @HAVE_DECL_OBSTACK_PRINTF@ +HAVE_DECL_PROGRAM_INVOCATION_NAME = @HAVE_DECL_PROGRAM_INVOCATION_NAME@ +HAVE_DECL_PUTW = @HAVE_DECL_PUTW@ HAVE_DECL_SETENV = @HAVE_DECL_SETENV@ HAVE_DECL_SETHOSTNAME = @HAVE_DECL_SETHOSTNAME@ HAVE_DECL_SETSTATE = @HAVE_DECL_SETSTATE@ @@ -987,6 +1000,9 @@ HAVE_DIRENT_H = @HAVE_DIRENT_H@ HAVE_DPRINTF = @HAVE_DPRINTF@ HAVE_DUP3 = @HAVE_DUP3@ HAVE_DUPLOCALE = @HAVE_DUPLOCALE@ +HAVE_ERROR = @HAVE_ERROR@ +HAVE_ERROR_AT_LINE = @HAVE_ERROR_AT_LINE@ +HAVE_ERROR_H = @HAVE_ERROR_H@ HAVE_EUIDACCESS = @HAVE_EUIDACCESS@ HAVE_EXECVPE = @HAVE_EXECVPE@ HAVE_EXPLICIT_BZERO = @HAVE_EXPLICIT_BZERO@ @@ -1019,6 +1035,7 @@ HAVE_GETLOGIN = @HAVE_GETLOGIN@ HAVE_GETOPT_H = @HAVE_GETOPT_H@ HAVE_GETPAGESIZE = @HAVE_GETPAGESIZE@ HAVE_GETPASS = @HAVE_GETPASS@ +HAVE_GETPROGNAME = @HAVE_GETPROGNAME@ HAVE_GETRANDOM = @HAVE_GETRANDOM@ HAVE_GETSUBOPT = @HAVE_GETSUBOPT@ HAVE_GETTIMEOFDAY = @HAVE_GETTIMEOFDAY@ @@ -1028,6 +1045,9 @@ HAVE_GLOB_H = @HAVE_GLOB_H@ HAVE_GLOB_PATTERN_P = @HAVE_GLOB_PATTERN_P@ HAVE_GRANTPT = @HAVE_GRANTPT@ HAVE_GROUP_MEMBER = @HAVE_GROUP_MEMBER@ +HAVE_ICONV = @HAVE_ICONV@ +HAVE_IMAXABS = @HAVE_IMAXABS@ +HAVE_IMAXDIV = @HAVE_IMAXDIV@ HAVE_IMAXDIV_T = @HAVE_IMAXDIV_T@ HAVE_INITSTATE = @HAVE_INITSTATE@ HAVE_INTTYPES_H = @HAVE_INTTYPES_H@ @@ -1054,6 +1074,7 @@ HAVE_MBSNRTOWCS = @HAVE_MBSNRTOWCS@ HAVE_MBSRTOWCS = @HAVE_MBSRTOWCS@ HAVE_MBTOWC = @HAVE_MBTOWC@ HAVE_MEMPCPY = @HAVE_MEMPCPY@ +HAVE_MEMSET_EXPLICIT = @HAVE_MEMSET_EXPLICIT@ HAVE_MKDIRAT = @HAVE_MKDIRAT@ HAVE_MKDTEMP = @HAVE_MKDTEMP@ HAVE_MKFIFO = @HAVE_MKFIFO@ @@ -1211,7 +1232,6 @@ HAVE_WMEMPCPY = @HAVE_WMEMPCPY@ HAVE_WMEMSET = @HAVE_WMEMSET@ HAVE_WS2TCPIP_H = @HAVE_WS2TCPIP_H@ HAVE_XLOCALE_H = @HAVE_XLOCALE_H@ -HAVE__BOOL = @HAVE__BOOL@ HAVE__EXIT = @HAVE__EXIT@ IGNORE_UNUSED_LIBRARIES_CFLAGS = @IGNORE_UNUSED_LIBRARIES_CFLAGS@ INCLUDE_NEXT = @INCLUDE_NEXT@ @@ -1225,6 +1245,10 @@ INT32_MAX_LT_INTMAX_MAX = @INT32_MAX_LT_INTMAX_MAX@ INT64_MAX_EQ_LONG_MAX = @INT64_MAX_EQ_LONG_MAX@ INTLLIBS = @INTLLIBS@ INTL_MACOSX_LIBS = @INTL_MACOSX_LIBS@ +LC_COLLATE_IMPLEMENTED = @LC_COLLATE_IMPLEMENTED@ +LC_MONETARY_IMPLEMENTED = @LC_MONETARY_IMPLEMENTED@ +LC_NUMERIC_IMPLEMENTED = @LC_NUMERIC_IMPLEMENTED@ +LC_TIME_IMPLEMENTED = @LC_TIME_IMPLEMENTED@ LD = @LD@ LDFLAGS = @LDFLAGS@ LEX = @LEX@ @@ -1275,13 +1299,18 @@ MAKEINFO = @MAKEINFO@ MANDIR_LAYOUT = @MANDIR_LAYOUT@ MANIFEST_TOOL = @MANIFEST_TOOL@ MAN_SUBDIRS = @MAN_SUBDIRS@ +MBRTOWC_LIB = @MBRTOWC_LIB@ MKDIR_P = @MKDIR_P@ MSGFMT = @MSGFMT@ MSGFMT_015 = @MSGFMT_015@ MSGMERGE = @MSGMERGE@ +NANOSLEEP_LIB = @NANOSLEEP_LIB@ +NEXT_ASSERT_H = @NEXT_ASSERT_H@ +NEXT_AS_FIRST_DIRECTIVE_ASSERT_H = @NEXT_AS_FIRST_DIRECTIVE_ASSERT_H@ NEXT_AS_FIRST_DIRECTIVE_CTYPE_H = @NEXT_AS_FIRST_DIRECTIVE_CTYPE_H@ NEXT_AS_FIRST_DIRECTIVE_DIRENT_H = @NEXT_AS_FIRST_DIRECTIVE_DIRENT_H@ NEXT_AS_FIRST_DIRECTIVE_ERRNO_H = @NEXT_AS_FIRST_DIRECTIVE_ERRNO_H@ +NEXT_AS_FIRST_DIRECTIVE_ERROR_H = @NEXT_AS_FIRST_DIRECTIVE_ERROR_H@ NEXT_AS_FIRST_DIRECTIVE_FCNTL_H = @NEXT_AS_FIRST_DIRECTIVE_FCNTL_H@ NEXT_AS_FIRST_DIRECTIVE_FLOAT_H = @NEXT_AS_FIRST_DIRECTIVE_FLOAT_H@ NEXT_AS_FIRST_DIRECTIVE_FNMATCH_H = @NEXT_AS_FIRST_DIRECTIVE_FNMATCH_H@ @@ -1318,6 +1347,7 @@ NEXT_AS_FIRST_DIRECTIVE_WCTYPE_H = @NEXT_AS_FIRST_DIRECTIVE_WCTYPE_H@ NEXT_CTYPE_H = @NEXT_CTYPE_H@ NEXT_DIRENT_H = @NEXT_DIRENT_H@ NEXT_ERRNO_H = @NEXT_ERRNO_H@ +NEXT_ERROR_H = @NEXT_ERROR_H@ NEXT_FCNTL_H = @NEXT_FCNTL_H@ NEXT_FLOAT_H = @NEXT_FLOAT_H@ NEXT_FNMATCH_H = @NEXT_FNMATCH_H@ @@ -1374,6 +1404,7 @@ PRAGMA_COLUMNS = @PRAGMA_COLUMNS@ PRAGMA_SYSTEM_HEADER = @PRAGMA_SYSTEM_HEADER@ PRIPTR_PREFIX = @PRIPTR_PREFIX@ PTHREAD_H_DEFINES_STRUCT_TIMESPEC = @PTHREAD_H_DEFINES_STRUCT_TIMESPEC@ +PTHREAD_SIGMASK_LIB = @PTHREAD_SIGMASK_LIB@ PTRDIFF_T_SUFFIX = @PTRDIFF_T_SUFFIX@ RANLIB = @RANLIB@ REPLACE_ACCESS = @REPLACE_ACCESS@ @@ -1393,7 +1424,10 @@ REPLACE_DIRFD = @REPLACE_DIRFD@ REPLACE_DPRINTF = @REPLACE_DPRINTF@ REPLACE_DUP = @REPLACE_DUP@ REPLACE_DUP2 = @REPLACE_DUP2@ +REPLACE_DUP3 = @REPLACE_DUP3@ REPLACE_DUPLOCALE = @REPLACE_DUPLOCALE@ +REPLACE_ERROR = @REPLACE_ERROR@ +REPLACE_ERROR_AT_LINE = @REPLACE_ERROR_AT_LINE@ REPLACE_EXECL = @REPLACE_EXECL@ REPLACE_EXECLE = @REPLACE_EXECLE@ REPLACE_EXECLP = @REPLACE_EXECLP@ @@ -1406,6 +1440,7 @@ REPLACE_FCHMODAT = @REPLACE_FCHMODAT@ REPLACE_FCHOWNAT = @REPLACE_FCHOWNAT@ REPLACE_FCLOSE = @REPLACE_FCLOSE@ REPLACE_FCNTL = @REPLACE_FCNTL@ +REPLACE_FDATASYNC = @REPLACE_FDATASYNC@ REPLACE_FDOPEN = @REPLACE_FDOPEN@ REPLACE_FDOPENDIR = @REPLACE_FDOPENDIR@ REPLACE_FFLUSH = @REPLACE_FFLUSH@ @@ -1430,17 +1465,23 @@ REPLACE_GETCWD = @REPLACE_GETCWD@ REPLACE_GETDELIM = @REPLACE_GETDELIM@ REPLACE_GETDOMAINNAME = @REPLACE_GETDOMAINNAME@ REPLACE_GETDTABLESIZE = @REPLACE_GETDTABLESIZE@ +REPLACE_GETENTROPY = @REPLACE_GETENTROPY@ REPLACE_GETGROUPS = @REPLACE_GETGROUPS@ REPLACE_GETLINE = @REPLACE_GETLINE@ +REPLACE_GETLOADAVG = @REPLACE_GETLOADAVG@ REPLACE_GETLOGIN_R = @REPLACE_GETLOGIN_R@ REPLACE_GETPAGESIZE = @REPLACE_GETPAGESIZE@ REPLACE_GETPASS = @REPLACE_GETPASS@ REPLACE_GETPASS_FOR_GETPASS_GNU = @REPLACE_GETPASS_FOR_GETPASS_GNU@ +REPLACE_GETPROGNAME = @REPLACE_GETPROGNAME@ REPLACE_GETRANDOM = @REPLACE_GETRANDOM@ +REPLACE_GETSUBOPT = @REPLACE_GETSUBOPT@ REPLACE_GETTIMEOFDAY = @REPLACE_GETTIMEOFDAY@ REPLACE_GLOB = @REPLACE_GLOB@ REPLACE_GLOB_PATTERN_P = @REPLACE_GLOB_PATTERN_P@ REPLACE_GMTIME = @REPLACE_GMTIME@ +REPLACE_IMAXABS = @REPLACE_IMAXABS@ +REPLACE_IMAXDIV = @REPLACE_IMAXDIV@ REPLACE_INITSTATE = @REPLACE_INITSTATE@ REPLACE_IOCTL = @REPLACE_IOCTL@ REPLACE_ISATTY = @REPLACE_ISATTY@ @@ -1465,14 +1506,19 @@ REPLACE_MBSINIT = @REPLACE_MBSINIT@ REPLACE_MBSNRTOWCS = @REPLACE_MBSNRTOWCS@ REPLACE_MBSRTOWCS = @REPLACE_MBSRTOWCS@ REPLACE_MBSTATE_T = @REPLACE_MBSTATE_T@ +REPLACE_MBSTOWCS = @REPLACE_MBSTOWCS@ REPLACE_MBTOWC = @REPLACE_MBTOWC@ +REPLACE_MB_CUR_MAX = @REPLACE_MB_CUR_MAX@ REPLACE_MEMCHR = @REPLACE_MEMCHR@ REPLACE_MEMMEM = @REPLACE_MEMMEM@ +REPLACE_MEMPCPY = @REPLACE_MEMPCPY@ REPLACE_MKDIR = @REPLACE_MKDIR@ REPLACE_MKFIFO = @REPLACE_MKFIFO@ REPLACE_MKFIFOAT = @REPLACE_MKFIFOAT@ REPLACE_MKNOD = @REPLACE_MKNOD@ REPLACE_MKNODAT = @REPLACE_MKNODAT@ +REPLACE_MKOSTEMP = @REPLACE_MKOSTEMP@ +REPLACE_MKOSTEMPS = @REPLACE_MKOSTEMPS@ REPLACE_MKSTEMP = @REPLACE_MKSTEMP@ REPLACE_MKTIME = @REPLACE_MKTIME@ REPLACE_NANOSLEEP = @REPLACE_NANOSLEEP@ @@ -1484,8 +1530,10 @@ REPLACE_OPEN = @REPLACE_OPEN@ REPLACE_OPENAT = @REPLACE_OPENAT@ REPLACE_OPENDIR = @REPLACE_OPENDIR@ REPLACE_PERROR = @REPLACE_PERROR@ +REPLACE_PIPE2 = @REPLACE_PIPE2@ REPLACE_POPEN = @REPLACE_POPEN@ REPLACE_POSIX_MEMALIGN = @REPLACE_POSIX_MEMALIGN@ +REPLACE_POSIX_OPENPT = @REPLACE_POSIX_OPENPT@ REPLACE_PREAD = @REPLACE_PREAD@ REPLACE_PRINTF = @REPLACE_PRINTF@ REPLACE_PSELECT = @REPLACE_PSELECT@ @@ -1499,6 +1547,7 @@ REPLACE_RAISE = @REPLACE_RAISE@ REPLACE_RANDOM = @REPLACE_RANDOM@ REPLACE_RANDOM_R = @REPLACE_RANDOM_R@ REPLACE_READ = @REPLACE_READ@ +REPLACE_READDIR = @REPLACE_READDIR@ REPLACE_READLINK = @REPLACE_READLINK@ REPLACE_READLINKAT = @REPLACE_READLINKAT@ REPLACE_REALLOCARRAY = @REPLACE_REALLOCARRAY@ @@ -1508,9 +1557,11 @@ REPLACE_REALPATH = @REPLACE_REALPATH@ REPLACE_REMOVE = @REPLACE_REMOVE@ REPLACE_RENAME = @REPLACE_RENAME@ REPLACE_RENAMEAT = @REPLACE_RENAMEAT@ +REPLACE_REWINDDIR = @REPLACE_REWINDDIR@ REPLACE_RMDIR = @REPLACE_RMDIR@ REPLACE_SELECT = @REPLACE_SELECT@ REPLACE_SETENV = @REPLACE_SETENV@ +REPLACE_SETHOSTNAME = @REPLACE_SETHOSTNAME@ REPLACE_SETLOCALE = @REPLACE_SETLOCALE@ REPLACE_SETSTATE = @REPLACE_SETSTATE@ REPLACE_SLEEP = @REPLACE_SLEEP@ @@ -1519,6 +1570,7 @@ REPLACE_SPRINTF = @REPLACE_SPRINTF@ REPLACE_STAT = @REPLACE_STAT@ REPLACE_STDIO_READ_FUNCS = @REPLACE_STDIO_READ_FUNCS@ REPLACE_STDIO_WRITE_FUNCS = @REPLACE_STDIO_WRITE_FUNCS@ +REPLACE_STPCPY = @REPLACE_STPCPY@ REPLACE_STPNCPY = @REPLACE_STPNCPY@ REPLACE_STRCASESTR = @REPLACE_STRCASESTR@ REPLACE_STRCHRNUL = @REPLACE_STRCHRNUL@ @@ -1545,7 +1597,9 @@ REPLACE_STRUCT_LCONV = @REPLACE_STRUCT_LCONV@ REPLACE_STRUCT_TIMEVAL = @REPLACE_STRUCT_TIMEVAL@ REPLACE_SYMLINK = @REPLACE_SYMLINK@ REPLACE_SYMLINKAT = @REPLACE_SYMLINKAT@ +REPLACE_TIME = @REPLACE_TIME@ REPLACE_TIMEGM = @REPLACE_TIMEGM@ +REPLACE_TIMESPEC_GET = @REPLACE_TIMESPEC_GET@ REPLACE_TMPFILE = @REPLACE_TMPFILE@ REPLACE_TOWLOWER = @REPLACE_TOWLOWER@ REPLACE_TRUNCATE = @REPLACE_TRUNCATE@ @@ -1564,23 +1618,31 @@ REPLACE_VPRINTF = @REPLACE_VPRINTF@ REPLACE_VSNPRINTF = @REPLACE_VSNPRINTF@ REPLACE_VSPRINTF = @REPLACE_VSPRINTF@ REPLACE_WCRTOMB = @REPLACE_WCRTOMB@ +REPLACE_WCSCMP = @REPLACE_WCSCMP@ REPLACE_WCSFTIME = @REPLACE_WCSFTIME@ +REPLACE_WCSNCMP = @REPLACE_WCSNCMP@ REPLACE_WCSNRTOMBS = @REPLACE_WCSNRTOMBS@ REPLACE_WCSRTOMBS = @REPLACE_WCSRTOMBS@ +REPLACE_WCSSTR = @REPLACE_WCSSTR@ REPLACE_WCSTOK = @REPLACE_WCSTOK@ REPLACE_WCSWIDTH = @REPLACE_WCSWIDTH@ REPLACE_WCTOB = @REPLACE_WCTOB@ REPLACE_WCTOMB = @REPLACE_WCTOMB@ REPLACE_WCWIDTH = @REPLACE_WCWIDTH@ +REPLACE_WMEMCMP = @REPLACE_WMEMCMP@ +REPLACE_WMEMPCPY = @REPLACE_WMEMPCPY@ REPLACE_WRITE = @REPLACE_WRITE@ +REPLACE__EXIT = @REPLACE__EXIT@ +SCHED_YIELD_LIB = @SCHED_YIELD_LIB@ SED = @SED@ +SELECT_LIB = @SELECT_LIB@ +SETLOCALE_NULL_LIB = @SETLOCALE_NULL_LIB@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ SIG_ATOMIC_T_SUFFIX = @SIG_ATOMIC_T_SUFFIX@ SIZE_T_SUFFIX = @SIZE_T_SUFFIX@ -STDALIGN_H = @STDALIGN_H@ STDARG_H = @STDARG_H@ -STDBOOL_H = @STDBOOL_H@ +STDCKDINT_H = @STDCKDINT_H@ STDDEF_H = @STDDEF_H@ STDINT_H = @STDINT_H@ STRIP = @STRIP@ @@ -63,9 +63,11 @@ #include "error.h" #include "gl_array_list.h" #include "gl_hash_map.h" +#include "gl_hash_set.h" #include "gl_list.h" #include "gl_xlist.h" #include "gl_xmap.h" +#include "gl_xset.h" #include "minmax.h" #include "progname.h" #include "regex.h" @@ -683,8 +685,7 @@ static int get_roff_line_length (void) { int line_length = cat_width ? cat_width : get_line_length (); - /* groff >= 1.18 defaults to 78. */ - if ((!troff || ditroff) && line_length != 80) { + if (!troff || ditroff) { int length = line_length * 39 / 40; if (length > line_length - 2) return line_length - 2; @@ -740,7 +741,7 @@ static pipecmd *add_roff_line_length (pipecmd *cmd, bool *save_cat_p) pipecmd_argf (cmd, "-rLL=%dn", length); pipecmd_argf (cmd, "-rLT=%dn", length); #elif defined(HEIRLOOM_NROFF) - name = xasprintf ("echo .ll %dn && echo .lt %dn", + name = xasprintf ("echo .ll %dn && echo .lt %dn && echo .lf 1", length, length); lldata = xasprintf ("%d", length); llcmd = pipecmd_new_function (name, heirloom_line_length, free, @@ -796,6 +797,10 @@ static void do_extern (int argc, char *argv[]) /* Please keep these in the same order as they are in whatis.c. */ if (debug_level) pipecmd_arg (cmd, "-d"); + if (regex_opt) + pipecmd_arg (cmd, "-r"); + if (wildcard) + pipecmd_arg (cmd, "-w"); if (local_man_file) /* actually apropos/whatis --long */ pipecmd_arg (cmd, "-l"); if (colon_sep_section_list) @@ -1417,9 +1422,19 @@ static pipeline *make_roff_command (const char *dir, const char *file, } #endif /* TROFF_IS_GROFF || HEIRLOOM_NROFF */ +#ifdef TROFF_IS_GROFF + /* See also display () for the more complex non-groff case. */ + if (!recode && no_hyphenation) + pipecmd_argf (cmd, "-rHY=0"); +#endif /* !TROFF_IS_GROFF */ + #ifdef NROFF_WARNINGS - GL_LIST_FOREACH (roff_warnings, warning) - pipecmd_argf (cmd, "-w%s", warning); + GL_LIST_FOREACH (roff_warnings, warning) { + if (warning[0] == '!') + pipecmd_argf (cmd, "-W%s", warning + 1); + else + pipecmd_argf (cmd, "-w%s", warning); + } #endif /* NROFF_WARNINGS */ #ifdef HEIRLOOM_NROFF @@ -2116,6 +2131,7 @@ static void display_catman (const char *cat_file, decompress *d, free (tmpcat); } +#ifndef TROFF_IS_GROFF static void disable_hyphenation (void *data MAYBE_UNUSED) { fputs (".nh\n" @@ -2123,12 +2139,17 @@ static void disable_hyphenation (void *data MAYBE_UNUSED) "..\n" ".lf 1\n", stdout); } +#endif /* TROFF_IS_GROFF */ static void disable_justification (void *data MAYBE_UNUSED) { - fputs (".na\n" - ".de ad\n" - "..\n" + fputs (".ie (\\n(.g&((\\n(.x>1):((\\n(.x==1)&(\\n(.y>=23))))" + " .ds AD l\n" + ".el \\{\\\n" + ". na\n" + ". de ad\n" + ". .\n" + ".\\}\n" ".lf 1\n", stdout); } @@ -2239,17 +2260,27 @@ static int display (const char *dir, const char *man_file, else decomp = decompress_fdopen (dup (STDIN_FILENO)); +#ifndef TROFF_IS_GROFF + /* See also make_roff_command () for the simpler groff case. */ if (!recode && no_hyphenation) { pipecmd *hcmd = pipecmd_new_function ( - "echo .nh && echo .de hy && echo ..", + "echo .nh && echo .de hy && echo .. && " + "echo .lf 1", disable_hyphenation, NULL, NULL); pipecmd_sequence_command (seq, hcmd); ++prefixes; } +#endif /* TROFF_IS_GROFF */ if (!recode && no_justification) { pipecmd *jcmd = pipecmd_new_function ( - "echo .na && echo .de ad && echo ..", +#ifdef TROFF_IS_GROFF + /* Technically only for groff >= 1.23.0. */ + "echo .ds AD l && echo .lf 1", +#else /* !TROFF_IS_GROFF */ + "echo .na && echo .de ad && echo .. && " + "echo .lf 1", +#endif /* TROFF_IS_GROFF */ disable_justification, NULL, NULL); pipecmd_sequence_command (seq, jcmd); ++prefixes; @@ -2269,7 +2300,8 @@ static int display (const char *dir, const char *man_file, pipecmd *lcmd; unpack_locale_bits (page_lang, &bits); - name = xasprintf ("echo .mso %s.tmac", + name = xasprintf ("echo .mso %s.tmac && " + "echo .lf 1", bits.language); lcmd = pipecmd_new_function ( name, locale_macros, free, @@ -3727,7 +3759,7 @@ static int grep (const char *file, const char *string, const regex_t *search) } static int do_global_apropos_section (const char *path, const char *sec, - const char *name) + const char *name, gl_set_t seen) { int found = 0; gl_list_t names; @@ -3768,6 +3800,9 @@ static int do_global_apropos_section (const char *path, const char *sec, man_ult = ult_src (found_name, path, NULL, ult_flags); if (!man_ult) goto next; + if (gl_set_search (seen, man_ult->path)) + goto next; + gl_set_add (seen, xstrdup (man_ult->path)); lang = lang_dir (man_ult->path); cat_file = find_cat_file (path, found_name, man_ult->path); if (display (path, man_ult->path, cat_file, title, NULL)) @@ -3796,6 +3831,7 @@ static int do_global_apropos (const char *name, int *found) { gl_list_t my_section_list; const char *sec; + gl_set_t seen; if (section) { my_section_list = gl_list_create_empty (GL_ARRAY_LIST, NULL, @@ -3803,14 +3839,17 @@ static int do_global_apropos (const char *name, int *found) gl_list_add_last (my_section_list, section); } else my_section_list = section_list; + seen = new_string_set (GL_HASH_SET); GL_LIST_FOREACH (my_section_list, sec) { char *mp; GL_LIST_FOREACH (manpathlist, mp) - *found += do_global_apropos_section (mp, sec, name); + *found += do_global_apropos_section (mp, sec, name, + seen); } + gl_set_free (seen); if (section) gl_list_free (my_section_list); diff --git a/src/mandb.c b/src/mandb.c index e62085ea..07ea923c 100644 --- a/src/mandb.c +++ b/src/mandb.c @@ -896,8 +896,15 @@ int main (int argc, char *argv[]) #ifdef MAN_OWNER man_owner = get_man_owner (); - if (!user && euid != 0 && euid != man_owner->pw_uid) + if (!user && euid != 0 && euid != man_owner->pw_uid) { user = true; + if (!quiet) + fprintf (stderr, + _("Only the '%s' user can create or update " + "system-wide databases; acting as if the " + "--user-db option was used.\n"), + man_owner->pw_name); + } #endif /* MAN_OWNER */ read_config_file (user); @@ -1056,35 +1056,50 @@ static void add_dir_to_list (gl_list_t list, const char *dir) static void add_man_subdirs (gl_list_t list, const char *path) { char *newpath; + char *trimmed_path = xstrdup (path); /* don't assume anything about path, especially that it ends in "bin" or even has a '/' in it! */ - char *subdir = strrchr (path, '/'); + char *subdir = strrchr (trimmed_path, '/'); + + /* Trailing slash or root directory. Remove the trailing slash and + try again. If root directory, subdir will be null, so we don't + cause a segfault. If a path element is '/', we will correctly add + /man and /share/man manpaths. */ + if (subdir && strncmp (subdir, "/", 2) == 0) { + subdir[0] = '\0'; + subdir = strrchr (trimmed_path, '/'); + } if (subdir) { - newpath = xasprintf ("%.*s/man", (int) (subdir - path), path); + newpath = xasprintf ("%.*s/man", + (int) (subdir - trimmed_path), + trimmed_path); if (is_directory (newpath) == 1) add_dir_to_list (list, newpath); free (newpath); } - newpath = xasprintf ("%s/man", path); + newpath = xasprintf ("%s/man", trimmed_path); if (is_directory (newpath) == 1) add_dir_to_list (list, newpath); free (newpath); if (subdir) { newpath = xasprintf ("%.*s/share/man", - (int) (subdir - path), path); + (int) (subdir - trimmed_path), + trimmed_path); if (is_directory (newpath) == 1) add_dir_to_list (list, newpath); free (newpath); } - newpath = xasprintf ("%s/share/man", path); + newpath = xasprintf ("%s/share/man", trimmed_path); if (is_directory (newpath) == 1) add_dir_to_list (list, newpath); free (newpath); + + free (trimmed_path); } struct canonicalized_path { diff --git a/src/tests/Makefile.am b/src/tests/Makefile.am index 3cadd2c9..7cdad4ac 100644 --- a/src/tests/Makefile.am +++ b/src/tests/Makefile.am @@ -23,7 +23,8 @@ TESTS_ENVIRONMENT = PATH=$(abs_builddir)/..:$$PATH; export PATH; \ MANDIR_LAYOUT=$(MANDIR_LAYOUT); export MANDIR_LAYOUT; \ abs_top_builddir=$(abs_top_builddir); export abs_top_builddir; \ OVERRIDE_DIR="$(override_dir)"; export OVERRIDE_DIR; \ - troff_is_groff=$(troff_is_groff); export troff_is_groff; + troff_is_groff=$(troff_is_groff); export troff_is_groff; \ + HAVE_ICONV=$(HAVE_ICONV); export HAVE_ICONV; # Each test must use the configure-detected shell, not necessarily /bin/sh. AM_LOG_FLAGS = $(SHELL) ALL_TESTS = \ @@ -56,6 +57,7 @@ ALL_TESTS = \ mandb-symlink-beats-whatis-ref \ mandb-symlink-target-timestamp \ mandb-whatis-broken-link-changes \ + manpath-slash \ whatis-path-to-executable \ zsoelim-so-includes if !CROSS_COMPILING @@ -73,7 +75,7 @@ check_PROGRAMS = fspause get-mtime fspause_SOURCES = fspause.c fspause_LDADD = \ $(top_builddir)/gl/lib/libgnu.la \ - $(LIB_NANOSLEEP) + $(NANOSLEEP_LIB) get_mtime_SOURCES = get-mtime.c get_mtime_LDADD = $(top_builddir)/lib/libman.la diff --git a/src/tests/Makefile.in b/src/tests/Makefile.in index 90d026c5..d82c99d9 100644 --- a/src/tests/Makefile.in +++ b/src/tests/Makefile.in @@ -119,9 +119,9 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/man-arg-automatic-create.m4 \ $(top_srcdir)/gl/m4/absolute-header.m4 \ $(top_srcdir)/gl/m4/alloca.m4 $(top_srcdir)/gl/m4/argp.m4 \ $(top_srcdir)/gl/m4/asm-underscore.m4 \ - $(top_srcdir)/gl/m4/btowc.m4 \ + $(top_srcdir)/gl/m4/assert_h.m4 $(top_srcdir)/gl/m4/btowc.m4 \ $(top_srcdir)/gl/m4/builtin-expect.m4 \ - $(top_srcdir)/gl/m4/calloc.m4 \ + $(top_srcdir)/gl/m4/c-bool.m4 $(top_srcdir)/gl/m4/calloc.m4 \ $(top_srcdir)/gl/m4/canonicalize.m4 \ $(top_srcdir)/gl/m4/chdir-long.m4 $(top_srcdir)/gl/m4/chown.m4 \ $(top_srcdir)/gl/m4/clock_time.m4 $(top_srcdir)/gl/m4/close.m4 \ @@ -133,6 +133,7 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/man-arg-automatic-create.m4 \ $(top_srcdir)/gl/m4/dup.m4 $(top_srcdir)/gl/m4/dup2.m4 \ $(top_srcdir)/gl/m4/eealloc.m4 $(top_srcdir)/gl/m4/environ.m4 \ $(top_srcdir)/gl/m4/errno_h.m4 $(top_srcdir)/gl/m4/error.m4 \ + $(top_srcdir)/gl/m4/error_h.m4 \ $(top_srcdir)/gl/m4/exponentd.m4 \ $(top_srcdir)/gl/m4/extensions.m4 \ $(top_srcdir)/gl/m4/extern-inline.m4 \ @@ -196,7 +197,7 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/man-arg-automatic-create.m4 \ $(top_srcdir)/gl/m4/mmap-anon.m4 $(top_srcdir)/gl/m4/mode_t.m4 \ $(top_srcdir)/gl/m4/msvc-inval.m4 \ $(top_srcdir)/gl/m4/msvc-nothrow.m4 \ - $(top_srcdir)/gl/m4/multiarch.m4 \ + $(top_srcdir)/gl/m4/multiarch.m4 $(top_srcdir)/gl/m4/musl.m4 \ $(top_srcdir)/gl/m4/nanosleep.m4 \ $(top_srcdir)/gl/m4/nl_langinfo.m4 $(top_srcdir)/gl/m4/nls.m4 \ $(top_srcdir)/gl/m4/nocrash.m4 \ @@ -230,10 +231,10 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/man-arg-automatic-create.m4 \ $(top_srcdir)/gl/m4/ssize_t.m4 \ $(top_srcdir)/gl/m4/stat-time.m4 $(top_srcdir)/gl/m4/stat.m4 \ $(top_srcdir)/gl/m4/stdalign.m4 $(top_srcdir)/gl/m4/stdarg.m4 \ - $(top_srcdir)/gl/m4/stdbool.m4 $(top_srcdir)/gl/m4/stddef_h.m4 \ - $(top_srcdir)/gl/m4/stdint.m4 $(top_srcdir)/gl/m4/stdint_h.m4 \ - $(top_srcdir)/gl/m4/stdio_h.m4 $(top_srcdir)/gl/m4/stdlib_h.m4 \ - $(top_srcdir)/gl/m4/stpcpy.m4 $(top_srcdir)/gl/m4/strcase.m4 \ + $(top_srcdir)/gl/m4/stddef_h.m4 $(top_srcdir)/gl/m4/stdint.m4 \ + $(top_srcdir)/gl/m4/stdint_h.m4 $(top_srcdir)/gl/m4/stdio_h.m4 \ + $(top_srcdir)/gl/m4/stdlib_h.m4 $(top_srcdir)/gl/m4/stpcpy.m4 \ + $(top_srcdir)/gl/m4/strcase.m4 \ $(top_srcdir)/gl/m4/strcasestr.m4 \ $(top_srcdir)/gl/m4/strchrnul.m4 $(top_srcdir)/gl/m4/strdup.m4 \ $(top_srcdir)/gl/m4/strerror.m4 \ @@ -272,7 +273,6 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/man-arg-automatic-create.m4 \ $(top_srcdir)/gl/m4/xalloc.m4 $(top_srcdir)/gl/m4/xgetcwd.m4 \ $(top_srcdir)/gl/m4/xsize.m4 $(top_srcdir)/gl/m4/xstrndup.m4 \ $(top_srcdir)/gl/m4/xvasprintf.m4 \ - $(top_srcdir)/gl/m4/year2038.m4 \ $(top_srcdir)/gl/m4/zzgnulib.m4 $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) @@ -571,6 +571,7 @@ APPLE_UNIVERSAL_BUILD = @APPLE_UNIVERSAL_BUILD@ AR = @AR@ ARFLAGS = @ARFLAGS@ ASM_SYMBOL_PREFIX = @ASM_SYMBOL_PREFIX@ +ASSERT_H = @ASSERT_H@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ @@ -584,6 +585,7 @@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CFLAG_VISIBILITY = @CFLAG_VISIBILITY@ +CLOCK_TIME_LIB = @CLOCK_TIME_LIB@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ CSCOPE = @CSCOPE@ @@ -593,6 +595,7 @@ DBLIBS = @DBLIBS@ DBTYPE = @DBTYPE@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ +DIR_HAS_FD_MEMBER = @DIR_HAS_FD_MEMBER@ DLLTOOL = @DLLTOOL@ DSYMUTIL = @DSYMUTIL@ DUMPBIN = @DUMPBIN@ @@ -613,8 +616,10 @@ FGREP = @FGREP@ FILECMD = @FILECMD@ FLOAT_H = @FLOAT_H@ FNMATCH_H = @FNMATCH_H@ +GETLOGIN_LIB = @GETLOGIN_LIB@ GETOPT_CDEFS_H = @GETOPT_CDEFS_H@ GETOPT_H = @GETOPT_H@ +GETRANDOM_LIB = @GETRANDOM_LIB@ GETTEXT_MACRO_VERSION = @GETTEXT_MACRO_VERSION@ GLOB_H = @GLOB_H@ GL_CFLAG_ALLOW_WARNINGS = @GL_CFLAG_ALLOW_WARNINGS@ @@ -711,6 +716,7 @@ GL_GNULIB_GETPAGESIZE = @GL_GNULIB_GETPAGESIZE@ GL_GNULIB_GETPASS = @GL_GNULIB_GETPASS@ GL_GNULIB_GETPASS_GNU = @GL_GNULIB_GETPASS_GNU@ GL_GNULIB_GETPEERNAME = @GL_GNULIB_GETPEERNAME@ +GL_GNULIB_GETPROGNAME = @GL_GNULIB_GETPROGNAME@ GL_GNULIB_GETRANDOM = @GL_GNULIB_GETRANDOM@ GL_GNULIB_GETSOCKNAME = @GL_GNULIB_GETSOCKNAME@ GL_GNULIB_GETSOCKOPT = @GL_GNULIB_GETSOCKOPT@ @@ -761,6 +767,7 @@ GL_GNULIB_MBSSEP = @GL_GNULIB_MBSSEP@ GL_GNULIB_MBSSPN = @GL_GNULIB_MBSSPN@ GL_GNULIB_MBSSTR = @GL_GNULIB_MBSSTR@ GL_GNULIB_MBSTOK_R = @GL_GNULIB_MBSTOK_R@ +GL_GNULIB_MBSTOWCS = @GL_GNULIB_MBSTOWCS@ GL_GNULIB_MBTOWC = @GL_GNULIB_MBTOWC@ GL_GNULIB_MDA_ACCESS = @GL_GNULIB_MDA_ACCESS@ GL_GNULIB_MDA_CHDIR = @GL_GNULIB_MDA_CHDIR@ @@ -808,6 +815,7 @@ GL_GNULIB_MEMCHR = @GL_GNULIB_MEMCHR@ GL_GNULIB_MEMMEM = @GL_GNULIB_MEMMEM@ GL_GNULIB_MEMPCPY = @GL_GNULIB_MEMPCPY@ GL_GNULIB_MEMRCHR = @GL_GNULIB_MEMRCHR@ +GL_GNULIB_MEMSET_EXPLICIT = @GL_GNULIB_MEMSET_EXPLICIT@ GL_GNULIB_MKDIR = @GL_GNULIB_MKDIR@ GL_GNULIB_MKDIRAT = @GL_GNULIB_MKDIRAT@ GL_GNULIB_MKDTEMP = @GL_GNULIB_MKDTEMP@ @@ -924,6 +932,7 @@ GL_GNULIB_SYMLINK = @GL_GNULIB_SYMLINK@ GL_GNULIB_SYMLINKAT = @GL_GNULIB_SYMLINKAT@ GL_GNULIB_SYSTEM_POSIX = @GL_GNULIB_SYSTEM_POSIX@ GL_GNULIB_TCGETSID = @GL_GNULIB_TCGETSID@ +GL_GNULIB_TIME = @GL_GNULIB_TIME@ GL_GNULIB_TIMEGM = @GL_GNULIB_TIMEGM@ GL_GNULIB_TIMESPEC_GET = @GL_GNULIB_TIMESPEC_GET@ GL_GNULIB_TIMESPEC_GETRES = @GL_GNULIB_TIMESPEC_GETRES@ @@ -999,6 +1008,7 @@ GMSGFMT_015 = @GMSGFMT_015@ GNULIBHEADERS_OVERRIDE_WINT_T = @GNULIBHEADERS_OVERRIDE_WINT_T@ GNULIB_GETTIMEOFDAY = @GNULIB_GETTIMEOFDAY@ GREP = @GREP@ +HARD_LOCALE_LIB = @HARD_LOCALE_LIB@ HAVE_ACCEPT4 = @HAVE_ACCEPT4@ HAVE_ALIGNED_ALLOC = @HAVE_ALIGNED_ALLOC@ HAVE_ALLOCA_H = @HAVE_ALLOCA_H@ @@ -1032,6 +1042,7 @@ HAVE_DECL_GETLOGIN = @HAVE_DECL_GETLOGIN@ HAVE_DECL_GETLOGIN_R = @HAVE_DECL_GETLOGIN_R@ HAVE_DECL_GETPAGESIZE = @HAVE_DECL_GETPAGESIZE@ HAVE_DECL_GETUSERSHELL = @HAVE_DECL_GETUSERSHELL@ +HAVE_DECL_GETW = @HAVE_DECL_GETW@ HAVE_DECL_IMAXABS = @HAVE_DECL_IMAXABS@ HAVE_DECL_IMAXDIV = @HAVE_DECL_IMAXDIV@ HAVE_DECL_INITSTATE = @HAVE_DECL_INITSTATE@ @@ -1039,6 +1050,8 @@ HAVE_DECL_LOCALTIME_R = @HAVE_DECL_LOCALTIME_R@ HAVE_DECL_MEMMEM = @HAVE_DECL_MEMMEM@ HAVE_DECL_MEMRCHR = @HAVE_DECL_MEMRCHR@ HAVE_DECL_OBSTACK_PRINTF = @HAVE_DECL_OBSTACK_PRINTF@ +HAVE_DECL_PROGRAM_INVOCATION_NAME = @HAVE_DECL_PROGRAM_INVOCATION_NAME@ +HAVE_DECL_PUTW = @HAVE_DECL_PUTW@ HAVE_DECL_SETENV = @HAVE_DECL_SETENV@ HAVE_DECL_SETHOSTNAME = @HAVE_DECL_SETHOSTNAME@ HAVE_DECL_SETSTATE = @HAVE_DECL_SETSTATE@ @@ -1064,6 +1077,9 @@ HAVE_DIRENT_H = @HAVE_DIRENT_H@ HAVE_DPRINTF = @HAVE_DPRINTF@ HAVE_DUP3 = @HAVE_DUP3@ HAVE_DUPLOCALE = @HAVE_DUPLOCALE@ +HAVE_ERROR = @HAVE_ERROR@ +HAVE_ERROR_AT_LINE = @HAVE_ERROR_AT_LINE@ +HAVE_ERROR_H = @HAVE_ERROR_H@ HAVE_EUIDACCESS = @HAVE_EUIDACCESS@ HAVE_EXECVPE = @HAVE_EXECVPE@ HAVE_EXPLICIT_BZERO = @HAVE_EXPLICIT_BZERO@ @@ -1096,6 +1112,7 @@ HAVE_GETLOGIN = @HAVE_GETLOGIN@ HAVE_GETOPT_H = @HAVE_GETOPT_H@ HAVE_GETPAGESIZE = @HAVE_GETPAGESIZE@ HAVE_GETPASS = @HAVE_GETPASS@ +HAVE_GETPROGNAME = @HAVE_GETPROGNAME@ HAVE_GETRANDOM = @HAVE_GETRANDOM@ HAVE_GETSUBOPT = @HAVE_GETSUBOPT@ HAVE_GETTIMEOFDAY = @HAVE_GETTIMEOFDAY@ @@ -1105,6 +1122,9 @@ HAVE_GLOB_H = @HAVE_GLOB_H@ HAVE_GLOB_PATTERN_P = @HAVE_GLOB_PATTERN_P@ HAVE_GRANTPT = @HAVE_GRANTPT@ HAVE_GROUP_MEMBER = @HAVE_GROUP_MEMBER@ +HAVE_ICONV = @HAVE_ICONV@ +HAVE_IMAXABS = @HAVE_IMAXABS@ +HAVE_IMAXDIV = @HAVE_IMAXDIV@ HAVE_IMAXDIV_T = @HAVE_IMAXDIV_T@ HAVE_INITSTATE = @HAVE_INITSTATE@ HAVE_INTTYPES_H = @HAVE_INTTYPES_H@ @@ -1131,6 +1151,7 @@ HAVE_MBSNRTOWCS = @HAVE_MBSNRTOWCS@ HAVE_MBSRTOWCS = @HAVE_MBSRTOWCS@ HAVE_MBTOWC = @HAVE_MBTOWC@ HAVE_MEMPCPY = @HAVE_MEMPCPY@ +HAVE_MEMSET_EXPLICIT = @HAVE_MEMSET_EXPLICIT@ HAVE_MKDIRAT = @HAVE_MKDIRAT@ HAVE_MKDTEMP = @HAVE_MKDTEMP@ HAVE_MKFIFO = @HAVE_MKFIFO@ @@ -1288,7 +1309,6 @@ HAVE_WMEMPCPY = @HAVE_WMEMPCPY@ HAVE_WMEMSET = @HAVE_WMEMSET@ HAVE_WS2TCPIP_H = @HAVE_WS2TCPIP_H@ HAVE_XLOCALE_H = @HAVE_XLOCALE_H@ -HAVE__BOOL = @HAVE__BOOL@ HAVE__EXIT = @HAVE__EXIT@ IGNORE_UNUSED_LIBRARIES_CFLAGS = @IGNORE_UNUSED_LIBRARIES_CFLAGS@ INCLUDE_NEXT = @INCLUDE_NEXT@ @@ -1302,6 +1322,10 @@ INT32_MAX_LT_INTMAX_MAX = @INT32_MAX_LT_INTMAX_MAX@ INT64_MAX_EQ_LONG_MAX = @INT64_MAX_EQ_LONG_MAX@ INTLLIBS = @INTLLIBS@ INTL_MACOSX_LIBS = @INTL_MACOSX_LIBS@ +LC_COLLATE_IMPLEMENTED = @LC_COLLATE_IMPLEMENTED@ +LC_MONETARY_IMPLEMENTED = @LC_MONETARY_IMPLEMENTED@ +LC_NUMERIC_IMPLEMENTED = @LC_NUMERIC_IMPLEMENTED@ +LC_TIME_IMPLEMENTED = @LC_TIME_IMPLEMENTED@ LD = @LD@ LDFLAGS = @LDFLAGS@ LEX = @LEX@ @@ -1352,13 +1376,18 @@ MAKEINFO = @MAKEINFO@ MANDIR_LAYOUT = @MANDIR_LAYOUT@ MANIFEST_TOOL = @MANIFEST_TOOL@ MAN_SUBDIRS = @MAN_SUBDIRS@ +MBRTOWC_LIB = @MBRTOWC_LIB@ MKDIR_P = @MKDIR_P@ MSGFMT = @MSGFMT@ MSGFMT_015 = @MSGFMT_015@ MSGMERGE = @MSGMERGE@ +NANOSLEEP_LIB = @NANOSLEEP_LIB@ +NEXT_ASSERT_H = @NEXT_ASSERT_H@ +NEXT_AS_FIRST_DIRECTIVE_ASSERT_H = @NEXT_AS_FIRST_DIRECTIVE_ASSERT_H@ NEXT_AS_FIRST_DIRECTIVE_CTYPE_H = @NEXT_AS_FIRST_DIRECTIVE_CTYPE_H@ NEXT_AS_FIRST_DIRECTIVE_DIRENT_H = @NEXT_AS_FIRST_DIRECTIVE_DIRENT_H@ NEXT_AS_FIRST_DIRECTIVE_ERRNO_H = @NEXT_AS_FIRST_DIRECTIVE_ERRNO_H@ +NEXT_AS_FIRST_DIRECTIVE_ERROR_H = @NEXT_AS_FIRST_DIRECTIVE_ERROR_H@ NEXT_AS_FIRST_DIRECTIVE_FCNTL_H = @NEXT_AS_FIRST_DIRECTIVE_FCNTL_H@ NEXT_AS_FIRST_DIRECTIVE_FLOAT_H = @NEXT_AS_FIRST_DIRECTIVE_FLOAT_H@ NEXT_AS_FIRST_DIRECTIVE_FNMATCH_H = @NEXT_AS_FIRST_DIRECTIVE_FNMATCH_H@ @@ -1395,6 +1424,7 @@ NEXT_AS_FIRST_DIRECTIVE_WCTYPE_H = @NEXT_AS_FIRST_DIRECTIVE_WCTYPE_H@ NEXT_CTYPE_H = @NEXT_CTYPE_H@ NEXT_DIRENT_H = @NEXT_DIRENT_H@ NEXT_ERRNO_H = @NEXT_ERRNO_H@ +NEXT_ERROR_H = @NEXT_ERROR_H@ NEXT_FCNTL_H = @NEXT_FCNTL_H@ NEXT_FLOAT_H = @NEXT_FLOAT_H@ NEXT_FNMATCH_H = @NEXT_FNMATCH_H@ @@ -1451,6 +1481,7 @@ PRAGMA_COLUMNS = @PRAGMA_COLUMNS@ PRAGMA_SYSTEM_HEADER = @PRAGMA_SYSTEM_HEADER@ PRIPTR_PREFIX = @PRIPTR_PREFIX@ PTHREAD_H_DEFINES_STRUCT_TIMESPEC = @PTHREAD_H_DEFINES_STRUCT_TIMESPEC@ +PTHREAD_SIGMASK_LIB = @PTHREAD_SIGMASK_LIB@ PTRDIFF_T_SUFFIX = @PTRDIFF_T_SUFFIX@ RANLIB = @RANLIB@ REPLACE_ACCESS = @REPLACE_ACCESS@ @@ -1470,7 +1501,10 @@ REPLACE_DIRFD = @REPLACE_DIRFD@ REPLACE_DPRINTF = @REPLACE_DPRINTF@ REPLACE_DUP = @REPLACE_DUP@ REPLACE_DUP2 = @REPLACE_DUP2@ +REPLACE_DUP3 = @REPLACE_DUP3@ REPLACE_DUPLOCALE = @REPLACE_DUPLOCALE@ +REPLACE_ERROR = @REPLACE_ERROR@ +REPLACE_ERROR_AT_LINE = @REPLACE_ERROR_AT_LINE@ REPLACE_EXECL = @REPLACE_EXECL@ REPLACE_EXECLE = @REPLACE_EXECLE@ REPLACE_EXECLP = @REPLACE_EXECLP@ @@ -1483,6 +1517,7 @@ REPLACE_FCHMODAT = @REPLACE_FCHMODAT@ REPLACE_FCHOWNAT = @REPLACE_FCHOWNAT@ REPLACE_FCLOSE = @REPLACE_FCLOSE@ REPLACE_FCNTL = @REPLACE_FCNTL@ +REPLACE_FDATASYNC = @REPLACE_FDATASYNC@ REPLACE_FDOPEN = @REPLACE_FDOPEN@ REPLACE_FDOPENDIR = @REPLACE_FDOPENDIR@ REPLACE_FFLUSH = @REPLACE_FFLUSH@ @@ -1507,17 +1542,23 @@ REPLACE_GETCWD = @REPLACE_GETCWD@ REPLACE_GETDELIM = @REPLACE_GETDELIM@ REPLACE_GETDOMAINNAME = @REPLACE_GETDOMAINNAME@ REPLACE_GETDTABLESIZE = @REPLACE_GETDTABLESIZE@ +REPLACE_GETENTROPY = @REPLACE_GETENTROPY@ REPLACE_GETGROUPS = @REPLACE_GETGROUPS@ REPLACE_GETLINE = @REPLACE_GETLINE@ +REPLACE_GETLOADAVG = @REPLACE_GETLOADAVG@ REPLACE_GETLOGIN_R = @REPLACE_GETLOGIN_R@ REPLACE_GETPAGESIZE = @REPLACE_GETPAGESIZE@ REPLACE_GETPASS = @REPLACE_GETPASS@ REPLACE_GETPASS_FOR_GETPASS_GNU = @REPLACE_GETPASS_FOR_GETPASS_GNU@ +REPLACE_GETPROGNAME = @REPLACE_GETPROGNAME@ REPLACE_GETRANDOM = @REPLACE_GETRANDOM@ +REPLACE_GETSUBOPT = @REPLACE_GETSUBOPT@ REPLACE_GETTIMEOFDAY = @REPLACE_GETTIMEOFDAY@ REPLACE_GLOB = @REPLACE_GLOB@ REPLACE_GLOB_PATTERN_P = @REPLACE_GLOB_PATTERN_P@ REPLACE_GMTIME = @REPLACE_GMTIME@ +REPLACE_IMAXABS = @REPLACE_IMAXABS@ +REPLACE_IMAXDIV = @REPLACE_IMAXDIV@ REPLACE_INITSTATE = @REPLACE_INITSTATE@ REPLACE_IOCTL = @REPLACE_IOCTL@ REPLACE_ISATTY = @REPLACE_ISATTY@ @@ -1542,14 +1583,19 @@ REPLACE_MBSINIT = @REPLACE_MBSINIT@ REPLACE_MBSNRTOWCS = @REPLACE_MBSNRTOWCS@ REPLACE_MBSRTOWCS = @REPLACE_MBSRTOWCS@ REPLACE_MBSTATE_T = @REPLACE_MBSTATE_T@ +REPLACE_MBSTOWCS = @REPLACE_MBSTOWCS@ REPLACE_MBTOWC = @REPLACE_MBTOWC@ +REPLACE_MB_CUR_MAX = @REPLACE_MB_CUR_MAX@ REPLACE_MEMCHR = @REPLACE_MEMCHR@ REPLACE_MEMMEM = @REPLACE_MEMMEM@ +REPLACE_MEMPCPY = @REPLACE_MEMPCPY@ REPLACE_MKDIR = @REPLACE_MKDIR@ REPLACE_MKFIFO = @REPLACE_MKFIFO@ REPLACE_MKFIFOAT = @REPLACE_MKFIFOAT@ REPLACE_MKNOD = @REPLACE_MKNOD@ REPLACE_MKNODAT = @REPLACE_MKNODAT@ +REPLACE_MKOSTEMP = @REPLACE_MKOSTEMP@ +REPLACE_MKOSTEMPS = @REPLACE_MKOSTEMPS@ REPLACE_MKSTEMP = @REPLACE_MKSTEMP@ REPLACE_MKTIME = @REPLACE_MKTIME@ REPLACE_NANOSLEEP = @REPLACE_NANOSLEEP@ @@ -1561,8 +1607,10 @@ REPLACE_OPEN = @REPLACE_OPEN@ REPLACE_OPENAT = @REPLACE_OPENAT@ REPLACE_OPENDIR = @REPLACE_OPENDIR@ REPLACE_PERROR = @REPLACE_PERROR@ +REPLACE_PIPE2 = @REPLACE_PIPE2@ REPLACE_POPEN = @REPLACE_POPEN@ REPLACE_POSIX_MEMALIGN = @REPLACE_POSIX_MEMALIGN@ +REPLACE_POSIX_OPENPT = @REPLACE_POSIX_OPENPT@ REPLACE_PREAD = @REPLACE_PREAD@ REPLACE_PRINTF = @REPLACE_PRINTF@ REPLACE_PSELECT = @REPLACE_PSELECT@ @@ -1576,6 +1624,7 @@ REPLACE_RAISE = @REPLACE_RAISE@ REPLACE_RANDOM = @REPLACE_RANDOM@ REPLACE_RANDOM_R = @REPLACE_RANDOM_R@ REPLACE_READ = @REPLACE_READ@ +REPLACE_READDIR = @REPLACE_READDIR@ REPLACE_READLINK = @REPLACE_READLINK@ REPLACE_READLINKAT = @REPLACE_READLINKAT@ REPLACE_REALLOCARRAY = @REPLACE_REALLOCARRAY@ @@ -1585,9 +1634,11 @@ REPLACE_REALPATH = @REPLACE_REALPATH@ REPLACE_REMOVE = @REPLACE_REMOVE@ REPLACE_RENAME = @REPLACE_RENAME@ REPLACE_RENAMEAT = @REPLACE_RENAMEAT@ +REPLACE_REWINDDIR = @REPLACE_REWINDDIR@ REPLACE_RMDIR = @REPLACE_RMDIR@ REPLACE_SELECT = @REPLACE_SELECT@ REPLACE_SETENV = @REPLACE_SETENV@ +REPLACE_SETHOSTNAME = @REPLACE_SETHOSTNAME@ REPLACE_SETLOCALE = @REPLACE_SETLOCALE@ REPLACE_SETSTATE = @REPLACE_SETSTATE@ REPLACE_SLEEP = @REPLACE_SLEEP@ @@ -1596,6 +1647,7 @@ REPLACE_SPRINTF = @REPLACE_SPRINTF@ REPLACE_STAT = @REPLACE_STAT@ REPLACE_STDIO_READ_FUNCS = @REPLACE_STDIO_READ_FUNCS@ REPLACE_STDIO_WRITE_FUNCS = @REPLACE_STDIO_WRITE_FUNCS@ +REPLACE_STPCPY = @REPLACE_STPCPY@ REPLACE_STPNCPY = @REPLACE_STPNCPY@ REPLACE_STRCASESTR = @REPLACE_STRCASESTR@ REPLACE_STRCHRNUL = @REPLACE_STRCHRNUL@ @@ -1622,7 +1674,9 @@ REPLACE_STRUCT_LCONV = @REPLACE_STRUCT_LCONV@ REPLACE_STRUCT_TIMEVAL = @REPLACE_STRUCT_TIMEVAL@ REPLACE_SYMLINK = @REPLACE_SYMLINK@ REPLACE_SYMLINKAT = @REPLACE_SYMLINKAT@ +REPLACE_TIME = @REPLACE_TIME@ REPLACE_TIMEGM = @REPLACE_TIMEGM@ +REPLACE_TIMESPEC_GET = @REPLACE_TIMESPEC_GET@ REPLACE_TMPFILE = @REPLACE_TMPFILE@ REPLACE_TOWLOWER = @REPLACE_TOWLOWER@ REPLACE_TRUNCATE = @REPLACE_TRUNCATE@ @@ -1641,23 +1695,31 @@ REPLACE_VPRINTF = @REPLACE_VPRINTF@ REPLACE_VSNPRINTF = @REPLACE_VSNPRINTF@ REPLACE_VSPRINTF = @REPLACE_VSPRINTF@ REPLACE_WCRTOMB = @REPLACE_WCRTOMB@ +REPLACE_WCSCMP = @REPLACE_WCSCMP@ REPLACE_WCSFTIME = @REPLACE_WCSFTIME@ +REPLACE_WCSNCMP = @REPLACE_WCSNCMP@ REPLACE_WCSNRTOMBS = @REPLACE_WCSNRTOMBS@ REPLACE_WCSRTOMBS = @REPLACE_WCSRTOMBS@ +REPLACE_WCSSTR = @REPLACE_WCSSTR@ REPLACE_WCSTOK = @REPLACE_WCSTOK@ REPLACE_WCSWIDTH = @REPLACE_WCSWIDTH@ REPLACE_WCTOB = @REPLACE_WCTOB@ REPLACE_WCTOMB = @REPLACE_WCTOMB@ REPLACE_WCWIDTH = @REPLACE_WCWIDTH@ +REPLACE_WMEMCMP = @REPLACE_WMEMCMP@ +REPLACE_WMEMPCPY = @REPLACE_WMEMPCPY@ REPLACE_WRITE = @REPLACE_WRITE@ +REPLACE__EXIT = @REPLACE__EXIT@ +SCHED_YIELD_LIB = @SCHED_YIELD_LIB@ SED = @SED@ +SELECT_LIB = @SELECT_LIB@ +SETLOCALE_NULL_LIB = @SETLOCALE_NULL_LIB@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ SIG_ATOMIC_T_SUFFIX = @SIG_ATOMIC_T_SUFFIX@ SIZE_T_SUFFIX = @SIZE_T_SUFFIX@ -STDALIGN_H = @STDALIGN_H@ STDARG_H = @STDARG_H@ -STDBOOL_H = @STDBOOL_H@ +STDCKDINT_H = @STDCKDINT_H@ STDDEF_H = @STDDEF_H@ STDINT_H = @STDINT_H@ STRIP = @STRIP@ @@ -1816,7 +1878,8 @@ TESTS_ENVIRONMENT = PATH=$(abs_builddir)/..:$$PATH; export PATH; \ MANDIR_LAYOUT=$(MANDIR_LAYOUT); export MANDIR_LAYOUT; \ abs_top_builddir=$(abs_top_builddir); export abs_top_builddir; \ OVERRIDE_DIR="$(override_dir)"; export OVERRIDE_DIR; \ - troff_is_groff=$(troff_is_groff); export troff_is_groff; + troff_is_groff=$(troff_is_groff); export troff_is_groff; \ + HAVE_ICONV=$(HAVE_ICONV); export HAVE_ICONV; # Each test must use the configure-detected shell, not necessarily /bin/sh. AM_LOG_FLAGS = $(SHELL) @@ -1850,6 +1913,7 @@ ALL_TESTS = \ mandb-symlink-beats-whatis-ref \ mandb-symlink-target-timestamp \ mandb-whatis-broken-link-changes \ + manpath-slash \ whatis-path-to-executable \ zsoelim-so-includes @@ -1864,7 +1928,7 @@ AM_CFLAGS = $(WARN_CFLAGS) fspause_SOURCES = fspause.c fspause_LDADD = \ $(top_builddir)/gl/lib/libgnu.la \ - $(LIB_NANOSLEEP) + $(NANOSLEEP_LIB) get_mtime_SOURCES = get-mtime.c get_mtime_LDADD = $(top_builddir)/lib/libman.la @@ -2358,6 +2422,13 @@ mandb-whatis-broken-link-changes.log: mandb-whatis-broken-link-changes --log-file $$b.log --trs-file $$b.trs \ $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \ "$$tst" $(AM_TESTS_FD_REDIRECT) +manpath-slash.log: manpath-slash + @p='manpath-slash'; \ + b='manpath-slash'; \ + $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \ + --log-file $$b.log --trs-file $$b.trs \ + $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \ + "$$tst" $(AM_TESTS_FD_REDIRECT) whatis-path-to-executable.log: whatis-path-to-executable @p='whatis-path-to-executable'; \ b='whatis-path-to-executable'; \ diff --git a/src/tests/man-recode-in-place b/src/tests/man-recode-in-place index 45c63add..7262a0c8 100755 --- a/src/tests/man-recode-in-place +++ b/src/tests/man-recode-in-place @@ -36,11 +36,16 @@ run $MAN_RECODE -t UTF-8 --in-place \ "$tmpdir/a.1" "$tmpdir/b.1.gz" "$tmpdir/c.1.gz" expect_files_equal '--in-place with no coding tag' \ "$tmpdir/a.1.exp" "$tmpdir/a.1" -expect_files_equal '--in-place with gzip and coding tag matching target encoding' \ - "$tmpdir/b.1.exp" "$tmpdir/b.1" -expect_files_equal \ - '--in-place with gzip and coding tag not matching target encoding' \ - "$tmpdir/c.1.exp" "$tmpdir/c.1" +if [ "$HAVE_ICONV" = yes ]; then + expect_files_equal '--in-place with gzip and coding tag matching target encoding' \ + "$tmpdir/b.1.exp" "$tmpdir/b.1" + expect_files_equal \ + '--in-place with gzip and coding tag not matching target encoding' \ + "$tmpdir/c.1.exp" "$tmpdir/c.1" +else + report_skip '--in-place with gzip and coding tag matching target encoding' + report_skip '--in-place with gzip and coding tag not matching target encoding' +fi test ! -f "$tmpdir/b.1.gz" && test ! -f "$tmpdir/c.1.gz" report '--in-place removes compressed input files' "$?" diff --git a/src/tests/man-recode-suffix b/src/tests/man-recode-suffix index 7c0a32cc..75b9424b 100755 --- a/src/tests/man-recode-suffix +++ b/src/tests/man-recode-suffix @@ -39,8 +39,12 @@ expect_files_equal '--suffix with no coding tag' \ expect_files_equal \ '--suffix with gzip and coding tag matching target encoding' \ "$tmpdir/b.1.exp" "$tmpdir/b.1.out" -expect_files_equal \ - '--suffix with gzip and coding tag not matching target encoding' \ - "$tmpdir/c.1.exp" "$tmpdir/c.1.out" +if [ "$HAVE_ICONV" = yes ]; then + expect_files_equal \ + '--suffix with gzip and coding tag not matching target encoding' \ + "$tmpdir/c.1.exp" "$tmpdir/c.1.out" +else + report_skip '--suffix with gzip and coding tag not matching target encoding' +fi finish diff --git a/src/tests/manconv-coding-tags b/src/tests/manconv-coding-tags index 7e753076..102a81ed 100755 --- a/src/tests/manconv-coding-tags +++ b/src/tests/manconv-coding-tags @@ -19,7 +19,11 @@ cat >"$tmpdir/1.inp" <<'EOF' EOF <"$tmpdir/1.exp" tail -n +2 | iconv -f UTF-8 -t ISO-8859-1 >>"$tmpdir/1.inp" run $MANCONV -f UTF-8 -t UTF-8 <"$tmpdir/1.inp" >"$tmpdir/1.out" -expect_files_equal 'simple coding tag' "$tmpdir/1.exp" "$tmpdir/1.out" +if [ "$HAVE_ICONV" = yes ]; then + expect_files_equal 'simple coding tag' "$tmpdir/1.exp" "$tmpdir/1.out" +else + report_skip 'simple coding tag' +fi cat >"$tmpdir/2.exp" <<'EOF' '\" -*- mode: troff; coding: UTF-8 -*- @@ -30,7 +34,11 @@ cat >"$tmpdir/2.inp" <<'EOF' EOF <"$tmpdir/2.exp" tail -n +2 | iconv -f UTF-8 -t ISO-8859-1 >>"$tmpdir/2.inp" run $MANCONV -f UTF-8 -t UTF-8 <"$tmpdir/2.inp" >"$tmpdir/2.out" -expect_files_equal 'mode and coding tags' "$tmpdir/2.exp" "$tmpdir/2.out" +if [ "$HAVE_ICONV" = yes ]; then + expect_files_equal 'mode and coding tags' "$tmpdir/2.exp" "$tmpdir/2.out" +else + report_skip 'mode and coding tags' +fi cat >"$tmpdir/3.exp" <<'EOF' '\" -*- mode: troff; coding: UTF-8 -*- @@ -41,7 +49,11 @@ cat >"$tmpdir/3.inp" <<'EOF' EOF <"$tmpdir/3.exp" tail -n +2 | iconv -f UTF-8 -t ISO-8859-1 >>"$tmpdir/3.inp" run $MANCONV -f UTF-8 -t UTF-8 <"$tmpdir/3.inp" >"$tmpdir/3.out" -expect_files_equal 'iso-latin-1 coding alias' "$tmpdir/3.exp" "$tmpdir/3.out" +if [ "$HAVE_ICONV" = yes ]; then + expect_files_equal 'iso-latin-1 coding alias' "$tmpdir/3.exp" "$tmpdir/3.out" +else + report_skip 'iso-latin-1 coding alias' +fi cat >"$tmpdir/4.inp" <<'EOF' '\" -*- nroff -*- diff --git a/src/tests/manconv-guess-from-encoding b/src/tests/manconv-guess-from-encoding index 2fd5a988..ca6f0bd0 100755 --- a/src/tests/manconv-guess-from-encoding +++ b/src/tests/manconv-guess-from-encoding @@ -11,6 +11,10 @@ init +if [ "$HAVE_ICONV" != yes ]; then + skip 'encoding conversion requires a working iconv' +fi + write_page coding-tag 7 \ "$tmpdir/usr/share/man/man7/coding-tag.7" \ ISO-8859-1 '' '' 'coding-tag \- é' diff --git a/src/tests/manconv-incomplete-char-at-eof b/src/tests/manconv-incomplete-char-at-eof index 96f88cfd..e1cdd786 100755 --- a/src/tests/manconv-incomplete-char-at-eof +++ b/src/tests/manconv-incomplete-char-at-eof @@ -10,6 +10,10 @@ init +if [ "$HAVE_ICONV" != yes ]; then + skip 'encoding conversion requires a working iconv' +fi + printf '\314' >"$tmpdir/1.inp" # 0xCC ! run $MANCONV -f EUC-JP -t UTF-8//IGNORE <"$tmpdir/1.inp" >/dev/null report 'incomplete character at EOF' "$?" diff --git a/src/tests/manconv-odd-combinations b/src/tests/manconv-odd-combinations index 087d6fc0..b99c2fb3 100755 --- a/src/tests/manconv-odd-combinations +++ b/src/tests/manconv-odd-combinations @@ -17,14 +17,22 @@ echo) >"$tmpdir/1.inp" iconv -f ISO-8859-1 -t UTF-8 <"$tmpdir/1.inp" >"$tmpdir/1.exp" run $MANCONV -f UTF-8:ISO-8859-1 -t UTF-8 <"$tmpdir/1.inp" >"$tmpdir/1.out" -expect_files_equal '-f UTF-8:ISO-8859-1 -t UTF-8 on ISO-8859-1 input' \ - "$tmpdir/1.exp" "$tmpdir/1.out" +if [ "$HAVE_ICONV" = yes ]; then + expect_files_equal '-f UTF-8:ISO-8859-1 -t UTF-8 on ISO-8859-1 input' \ + "$tmpdir/1.exp" "$tmpdir/1.out" +else + report_skip '-f UTF-8:ISO-8859-1 -t UTF-8 on ISO-8859-1 input' +fi iconv -f ISO-8859-2 -t UTF-8 <"$tmpdir/1.inp" >"$tmpdir/1-latin2.exp" run $MANCONV -f UTF-8:ISO-8859-2 -t UTF-8 \ <"$tmpdir/1.inp" >"$tmpdir/1-latin2.out" -expect_files_equal '-f UTF-8:ISO-8859-2 -t UTF-8 on ISO-8859-2 input' \ - "$tmpdir/1-latin2.exp" "$tmpdir/1-latin2.out" +if [ "$HAVE_ICONV" = yes ]; then + expect_files_equal '-f UTF-8:ISO-8859-2 -t UTF-8 on ISO-8859-2 input' \ + "$tmpdir/1-latin2.exp" "$tmpdir/1-latin2.out" +else + report_skip '-f UTF-8:ISO-8859-2 -t UTF-8 on ISO-8859-2 input' +fi (for x in $(seq 1 1000); do printf '‐' @@ -33,9 +41,13 @@ echo 'Б' | iconv -f UTF-8 -t KOI8-R echo '‐') >"$tmpdir/2.inp" iconv -f KOI8-R -t UTF-8 <"$tmpdir/2.inp" >"$tmpdir/2.exp" run $MANCONV -f UTF-8:KOI8-R -t UTF-8 <"$tmpdir/2.inp" >"$tmpdir/2.out" -expect_files_equal \ - '-f UTF-8:KOI8-R -t UTF-8 on KOI8-R input with UTF-8 prefix' \ - "$tmpdir/2.exp" "$tmpdir/2.out" +if [ "$HAVE_ICONV" = yes ]; then + expect_files_equal \ + '-f UTF-8:KOI8-R -t UTF-8 on KOI8-R input with UTF-8 prefix' \ + "$tmpdir/2.exp" "$tmpdir/2.out" +else + report_skip '-f UTF-8:KOI8-R -t UTF-8 on KOI8-R input with UTF-8 prefix' +fi (for x in $(seq 160 255); do printf %b "\\$(printf %03o "$x")" @@ -56,9 +68,13 @@ iconv -f UTF-8 -t ISO-8859-2 >"$tmpdir/4.exp" <<EOF EOF run $MANCONV -f UTF-8:ISO-8859-2 -t ISO-8859-2//IGNORE \ <"$tmpdir/4.inp" >"$tmpdir/4.out" -expect_files_equal \ - 'recognises input encoding and omits invalid output character' \ - "$tmpdir/4.exp" "$tmpdir/4.out" +if [ "$HAVE_ICONV" = yes ]; then + expect_files_equal \ + 'recognises input encoding and omits invalid output character' \ + "$tmpdir/4.exp" "$tmpdir/4.out" +else + report_skip 'recognises input encoding and omits invalid output character' +fi # 0xAE does not exist in ISO-8859-7, so manconv won't be able to recode this # to UTF-8 without conversion errors. (In the original case where this was @@ -75,7 +91,11 @@ EOF >>"$tmpdir/5.exp" 2>/dev/null run $MANCONV -f UTF-8:ISO-8859-1 -t UTF-8//IGNORE \ <"$tmpdir/5.inp" >"$tmpdir/5.out" -expect_files_equal 'copes with invalid input characters' \ - "$tmpdir/5.exp" "$tmpdir/5.out" +if [ "$HAVE_ICONV" = yes ]; then + expect_files_equal 'copes with invalid input characters' \ + "$tmpdir/5.exp" "$tmpdir/5.out" +else + report_skip 'copes with invalid input characters' +fi finish diff --git a/src/tests/manpath-slash b/src/tests/manpath-slash new file mode 100755 index 00000000..181bd92b --- /dev/null +++ b/src/tests/manpath-slash @@ -0,0 +1,28 @@ +#! /bin/sh + +: "${srcdir=.}" +# shellcheck source-path=SCRIPTDIR +. "$srcdir/testlib.sh" + +: "${MANPATH=manpath}" + +# Check whether manpath correctly parses PATH elements with trailing slash. + +init +fake_config /usr/share/man +mkdir -p "$tmpdir/bin" +mkdir -p "$tmpdir/share/man" +OLDPATH="$PATH" +export PATH="$tmpdir/bin/:$OLDPATH" +output=$(run $MANPATH) +case "$output" in + "$tmpdir/share/man:"*) report "manpath with trailing slash" 0 ;; + *) report "manpath with trailing slash" 1 ;; +esac +export PATH="$tmpdir/bin:$OLDPATH" +output=$(run $MANPATH) +case "$output" in + "$tmpdir/share/man:"*) report "manpath without trailing slash" 0 ;; + *) report "manpath without trailing slash" 1 ;; +esac +finish diff --git a/src/tests/testlib.sh b/src/tests/testlib.sh index 9732f8f8..c4872292 100644 --- a/src/tests/testlib.sh +++ b/src/tests/testlib.sh @@ -93,8 +93,12 @@ expect_files_equal () { report "$1" "$ret" } -skip () { +report_skip () { echo " SKIP: $1" +} + +skip () { + report_skip "$1" rm -rf "$abstmpdir" exit 77 } diff --git a/src/ult_src.c b/src/ult_src.c index 08413d20..c21aa514 100644 --- a/src/ult_src.c +++ b/src/ult_src.c @@ -191,7 +191,7 @@ static char *test_for_include (const char *buffer) buffer += 3; /* strip out any whitespace between the command and - it's argumant */ + its argument */ while (CTYPE (isspace, *buffer)) buffer++; |