diff options
-rw-r--r-- | Makefile.depend | 18 | ||||
-rwxr-xr-x | configure | 3 | ||||
-rw-r--r-- | dba_write.c | 4 | ||||
-rw-r--r-- | dbm.c | 4 | ||||
-rw-r--r-- | dbm_map.c | 4 | ||||
-rw-r--r-- | mansearch.c | 3 | ||||
-rw-r--r-- | mansearch.h | 2 | ||||
-rw-r--r-- | test-EFTYPE.c | 7 |
8 files changed, 34 insertions, 11 deletions
diff --git a/Makefile.depend b/Makefile.depend index e0c3a2e9..e55157b7 100644 --- a/Makefile.depend +++ b/Makefile.depend @@ -1,13 +1,13 @@ att.o: att.c config.h roff.h mdoc.h libmdoc.h cgi.o: cgi.c config.h mandoc_aux.h mandoc.h roff.h mdoc.h man.h main.h manconf.h mansearch.h cgi.h -chars.o: chars.c config.h mandoc.h mandoc_aux.h mandoc_ohash.h libmandoc.h +chars.o: chars.c config.h mandoc.h mandoc_aux.h mandoc_ohash.h compat_ohash.h libmandoc.h compat_err.o: compat_err.c config.h -compat_fts.o: compat_fts.c config.h +compat_fts.o: compat_fts.c config.h compat_fts.h compat_getline.o: compat_getline.c config.h compat_getsubopt.o: compat_getsubopt.c config.h compat_isblank.o: compat_isblank.c config.h compat_mkdtemp.o: compat_mkdtemp.c config.h -compat_ohash.o: compat_ohash.c config.h +compat_ohash.o: compat_ohash.c config.h compat_ohash.h compat_progname.o: compat_progname.c config.h compat_reallocarray.o: compat_reallocarray.c config.h compat_strcasestr.o: compat_strcasestr.c config.h @@ -20,9 +20,9 @@ compat_vasprintf.o: compat_vasprintf.c config.h dba.o: dba.c mandoc_aux.h mansearch.h dba_write.h dba_array.h dba.h dba_array.o: dba_array.c mandoc_aux.h dba_write.h dba_array.h dba_read.o: dba_read.c mandoc_aux.h mansearch.h dba_array.h dba.h dbm.h -dba_write.o: dba_write.c dba_write.h -dbm.o: dbm.c mansearch.h dbm_map.h dbm.h -dbm_map.o: dbm_map.c mansearch.h dbm_map.h dbm.h +dba_write.o: dba_write.c config.h dba_write.h +dbm.o: dbm.c config.h mansearch.h dbm_map.h dbm.h +dbm_map.o: dbm_map.c config.h mansearch.h dbm_map.h dbm.h demandoc.o: demandoc.c config.h roff.h man.h mdoc.h mandoc.h eqn.o: eqn.c config.h mandoc.h mandoc_aux.h libmandoc.h libroff.h eqn_html.o: eqn_html.c config.h mandoc.h out.h html.h @@ -39,10 +39,10 @@ man_validate.o: man_validate.c config.h mandoc_aux.h mandoc.h roff.h man.h libma mandoc.o: mandoc.c config.h mandoc.h mandoc_aux.h libmandoc.h mandoc_aux.o: mandoc_aux.c config.h mandoc.h mandoc_aux.h mandoc_ohash.o: mandoc_ohash.c mandoc_aux.h mandoc_ohash.h compat_ohash.h -mandocdb.o: mandocdb.c config.h mandoc_aux.h mandoc_ohash.h mandoc.h roff.h mdoc.h man.h manconf.h mansearch.h dba_array.h dba.h +mandocdb.o: mandocdb.c config.h compat_fts.h mandoc_aux.h mandoc_ohash.h compat_ohash.h mandoc.h roff.h mdoc.h man.h manconf.h mansearch.h dba_array.h dba.h manpage.o: manpage.c config.h manconf.h mansearch.h manpath.o: manpath.c config.h mandoc_aux.h manconf.h -mansearch.o: mansearch.c mandoc.h mandoc_aux.h mandoc_ohash.h compat_ohash.h manconf.h mansearch.h dbm.h +mansearch.o: mansearch.c config.h mandoc.h mandoc_aux.h mandoc_ohash.h compat_ohash.h manconf.h mansearch.h dbm.h mdoc.o: mdoc.c config.h mandoc_aux.h mandoc.h roff.h mdoc.h libmandoc.h roff_int.h libmdoc.h mdoc_argv.o: mdoc_argv.c config.h mandoc_aux.h mandoc.h roff.h mdoc.h libmandoc.h roff_int.h libmdoc.h mdoc_hash.o: mdoc_hash.c config.h mandoc.h roff.h mdoc.h libmandoc.h libmdoc.h @@ -59,7 +59,7 @@ read.o: read.c config.h mandoc_aux.h mandoc.h roff.h mdoc.h man.h libmandoc.h ro roff.o: roff.c config.h mandoc.h mandoc_aux.h roff.h libmandoc.h roff_int.h libroff.h predefs.in soelim.o: soelim.c config.h compat_stringlist.h st.o: st.c config.h roff.h mdoc.h libmdoc.h st.in -tag.o: tag.c config.h mandoc_aux.h mandoc_ohash.h tag.h +tag.o: tag.c config.h mandoc_aux.h mandoc_ohash.h compat_ohash.h tag.h tbl.o: tbl.c config.h mandoc.h mandoc_aux.h libmandoc.h libroff.h tbl_data.o: tbl_data.c config.h mandoc.h mandoc_aux.h libmandoc.h libroff.h tbl_html.o: tbl_html.c config.h mandoc.h out.h html.h @@ -45,6 +45,7 @@ STATIC="-static" BUILD_CGI=0 HAVE_DIRENT_NAMLEN= +HAVE_EFTYPE= HAVE_ERR= HAVE_FTS= HAVE_GETLINE= @@ -173,6 +174,7 @@ runtest() { # --- library functions --- runtest dirent-namlen DIRENT_NAMLEN || true +runtest EFTYPE EFTYPE || true runtest err ERR || true runtest fts FTS || true runtest getline GETLINE || true @@ -245,6 +247,7 @@ echo "#define MAN_CONF_FILE \"/etc/${MANM_MANCONF}\"" echo "#define MANPATH_DEFAULT \"${MANPATH_DEFAULT}\"" [ -n "${OSNAME}" ] && echo "#define OSNAME \"${OSNAME}\"" [ -n "${HOMEBREWDIR}" ] && echo "#define HOMEBREWDIR \"${HOMEBREWDIR}\"" +[ ${HAVE_EFTYPE} -eq 0 ] && echo "#define EFTYPE EINVAL" cat << __HEREDOC__ #define HAVE_DIRENT_NAMLEN ${HAVE_DIRENT_NAMLEN} diff --git a/dba_write.c b/dba_write.c index 9746d575..8b911f90 100644 --- a/dba_write.c +++ b/dba_write.c @@ -17,9 +17,13 @@ * Low-level functions for serializing allocation-based data to disk. * The interface is defined in "dba_write.h". */ +#include "config.h" + #include <assert.h> #include <endian.h> +#if HAVE_ERR #include <err.h> +#endif #include <errno.h> #include <fcntl.h> #include <stdint.h> @@ -17,9 +17,13 @@ * Map-based version of the mandoc database, for read-only access. * The interface is defined in "dbm.h". */ +#include "config.h" + #include <assert.h> #include <endian.h> +#if HAVE_ERR #include <err.h> +#endif #include <errno.h> #include <regex.h> #include <stdint.h> @@ -18,12 +18,16 @@ * of the mandoc database, for read-only access. * The interface is defined in "dbm_map.h". */ +#include "config.h" + #include <sys/mman.h> #include <sys/stat.h> #include <sys/types.h> #include <endian.h> +#if HAVE_ERR #include <err.h> +#endif #include <errno.h> #include <fcntl.h> #include <regex.h> diff --git a/mansearch.c b/mansearch.c index b2410e99..30e7768b 100644 --- a/mansearch.c +++ b/mansearch.c @@ -1,7 +1,7 @@ /* $OpenBSD: mansearch.c,v 1.50 2016/07/09 15:23:36 schwarze Exp $ */ /* * Copyright (c) 2012 Kristaps Dzonsons <kristaps@bsd.lv> - * Copyright (c) 2013, 2014, 2015 Ingo Schwarze <schwarze@openbsd.org> + * Copyright (c) 2013, 2014, 2015, 2016 Ingo Schwarze <schwarze@openbsd.org> * * Permission to use, copy, modify, and distribute this software for any * purpose with or without fee is hereby granted, provided that the above @@ -15,6 +15,7 @@ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ +#include "config.h" #include <sys/mman.h> #include <sys/types.h> diff --git a/mansearch.h b/mansearch.h index 82076e23..142cda0e 100644 --- a/mansearch.h +++ b/mansearch.h @@ -1,7 +1,7 @@ /* $Id$ */ /* * Copyright (c) 2012 Kristaps Dzonsons <kristaps@bsd.lv> - * Copyright (c) 2013, 2014 Ingo Schwarze <schwarze@openbsd.org> + * Copyright (c) 2013, 2014, 2016 Ingo Schwarze <schwarze@openbsd.org> * * Permission to use, copy, modify, and distribute this software for any * purpose with or without fee is hereby granted, provided that the above diff --git a/test-EFTYPE.c b/test-EFTYPE.c new file mode 100644 index 00000000..148f54f7 --- /dev/null +++ b/test-EFTYPE.c @@ -0,0 +1,7 @@ +#include <errno.h> + +int +main(void) +{ + return !EFTYPE; +} |