=================================================================== RCS file: /cvs/mandoc/configure,v retrieving revision 1.32 retrieving revision 1.34 diff -u -p -r1.32 -r1.34 --- mandoc/configure 2015/11/07 13:14:21 1.32 +++ mandoc/configure 2015/11/07 17:58:55 1.34 @@ -44,7 +44,6 @@ BUILD_CGI=0 HAVE_DIRENT_NAMLEN= HAVE_ERR= -HAVE_FGETLN= HAVE_FTS= HAVE_GETSUBOPT= HAVE_ISBLANK= @@ -176,7 +175,6 @@ runtest() { # --- library functions --- runtest dirent-namlen DIRENT_NAMLEN || true runtest err ERR || true -runtest fgetln FGETLN || true runtest fts FTS || true runtest getsubopt GETSUBOPT || true runtest isblank ISBLANK || true @@ -276,6 +274,10 @@ fi exec > config.h cat << __HEREDOC__ +#ifdef __cplusplus +#error "Do not use C++. See the INSTALL file." +#endif + #ifndef MANDOC_CONFIG_H #define MANDOC_CONFIG_H @@ -285,11 +287,10 @@ cat << __HEREDOC__ __HEREDOC__ -[ ${HAVE_FGETLN} -eq 0 -o ${HAVE_REALLOCARRAY} -eq 0 -o \ +[ ${HAVE_REALLOCARRAY} -eq 0 -o \ ${HAVE_STRLCAT} -eq 0 -o ${HAVE_STRLCPY} -eq 0 ] \ && echo "#include " [ ${HAVE_VASPRINTF} -eq 0 ] && echo "#include " -[ ${HAVE_FGETLN} -eq 0 ] && echo "#include " echo echo "#define MAN_CONF_FILE \"/etc/${MANM_MANCONF}\"" @@ -300,7 +301,6 @@ echo "#define MANPATH_DEFAULT \"${MANPATH_DEFAULT}\"" cat << __HEREDOC__ #define HAVE_DIRENT_NAMLEN ${HAVE_DIRENT_NAMLEN} #define HAVE_ERR ${HAVE_ERR} -#define HAVE_FGETLN ${HAVE_FGETLN} #define HAVE_FTS ${HAVE_FTS} #define HAVE_GETSUBOPT ${HAVE_GETSUBOPT} #define HAVE_ISBLANK ${HAVE_ISBLANK} @@ -331,21 +331,6 @@ cat << __HEREDOC__ #define BINM_SOELIM "${BINM_SOELIM}" #define BINM_WHATIS "${BINM_WHATIS}" -#if !defined(__BEGIN_DECLS) -# ifdef __cplusplus -# define __BEGIN_DECLS extern "C" { -# else -# define __BEGIN_DECLS -# endif -#endif -#if !defined(__END_DECLS) -# ifdef __cplusplus -# define __END_DECLS } -# else -# define __END_DECLS -# endif -#endif - __HEREDOC__ if [ ${HAVE_ERR} -eq 0 ]; then @@ -353,9 +338,6 @@ if [ ${HAVE_ERR} -eq 0 ]; then echo "extern void warn(const char *, ...);" echo "extern void warnx(const char *, ...);" fi - -[ ${HAVE_FGETLN} -eq 0 ] && \ - echo "extern char *fgetln(FILE *, size_t *);" [ ${HAVE_GETSUBOPT} -eq 0 ] && \ echo "extern int getsubopt(char **, char * const *, char **);"