aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/configure
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@openbsd.org>2015-11-07 14:01:16 +0000
committerIngo Schwarze <schwarze@openbsd.org>2015-11-07 14:01:16 +0000
commite7e94cd5a1663f3e3046a449030b33f9bd0dba7b (patch)
tree7ba5510993159310af2cea05939713b7f1233ac0 /configure
parent2a54c3c99c10d6c8060ed7584a79927b150f1f9c (diff)
downloadmandoc-e7e94cd5a1663f3e3046a449030b33f9bd0dba7b.tar.gz
mandoc-e7e94cd5a1663f3e3046a449030b33f9bd0dba7b.tar.zst
mandoc-e7e94cd5a1663f3e3046a449030b33f9bd0dba7b.zip
In private header files, __BEGIN_DECLS and __END_DECLS are pointless.
Because these work slightly differently on different systems, they are becoming a maintenance burden in the portable version, so delete them. Besides, one of the chief design goals of the mandoc toolbox is to make sure that nothing related to documentation requires C++. Consequently, linking mandoc against any kind of C++ program would defeat the purpose and is not supported. I don't understand why kristaps@ added them in the first place.
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure19
1 files changed, 4 insertions, 15 deletions
diff --git a/configure b/configure
index 54ebfca1..cae2f5c9 100755
--- a/configure
+++ b/configure
@@ -276,6 +276,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
@@ -331,21 +335,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