aboutsummaryrefslogtreecommitdiff
path: root/m4
diff options
context:
space:
mode:
authorArne Schwabe2021-03-28 16:20:38 +0200
committerGert Doering2021-03-28 16:34:42 +0200
commitf91e21163708b5dc01115806cb71643144d6c3d1 (patch)
tree4fd4bde1f79696ace2c977cd4377a3ed296ae00b /m4
parent7975e33bd9122045d26d1a47294f2c47854a5f0e (diff)
downloadopenvpn-f91e21163708b5dc01115806cb71643144d6c3d1.zip
openvpn-f91e21163708b5dc01115806cb71643144d6c3d1.tar.gz
Remove support for non ISO C99 vararg support
We require ISO C99 as minimum support for our source code and all compilers should support the ISO C99 macros. Especially gcc does not need the gcc extensions anymore. Also MSVC has support for it (as defined in the config-msvc.h but also double checked) LCLINT seems to be a C analyzer that history has forgotten about. I could only find https://splint.org/release1.3.html and an similarly old research paper. Patch V2: Also remove AX_ macros from configure.ac Signed-off-by: Arne Schwabe <arne@rfc2549.org> Acked-by: Steffan Karger <steffan.karger@foxcrypto.com> Acked-by: Gert Doering <gert@greenie.muc.de> Message-Id: <20210328142038.8826-2-arne@rfc2549.org> URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg21883.html Signed-off-by: Gert Doering <gert@greenie.muc.de>
Diffstat (limited to 'm4')
-rw-r--r--m4/ax_varargs.m477
1 files changed, 0 insertions, 77 deletions
diff --git a/m4/ax_varargs.m4 b/m4/ax_varargs.m4
deleted file mode 100644
index c295d21..0000000
--- a/m4/ax_varargs.m4
+++ /dev/null
@@ -1,77 +0,0 @@
-dnl @synopsis AX_CPP_VARARG_MACRO_GCC
-dnl
-dnl Test if the preprocessor understands GNU GCC-style vararg macros.
-dnl If it does, defines HAVE_CPP_VARARG_MACRO_GCC to 1.
-dnl
-dnl @version
-dnl @author James Yonan <jim@yonan.net>, Matthias Andree <matthias.andree@web.de>
-AC_DEFUN([AX_CPP_VARARG_MACRO_GCC], [dnl
- AS_VAR_PUSHDEF([VAR], [ax_cv_cpp_vararg_macro_gcc])dnl
- AC_CACHE_CHECK(
- [for GNU GCC vararg macro support],
- [VAR],
- [AC_COMPILE_IFELSE(
- [AC_LANG_PROGRAM(
- [[
-#define macro(a, b...) func(a, b)
-int func(int a, int b, int c);
- ]],
- [[
-int i = macro(1, 2, 3);
- ]]
- )],
- [VAR=yes],
- [VAR=no]
- )]
- )dnl
-
- AS_VAR_IF(
- [VAR],
- [yes],
- [AC_DEFINE(
- [HAVE_CPP_VARARG_MACRO_GCC],
- [1],
- [Define to 1 if your compiler supports GNU GCC-style variadic macros]
- )]
- )dnl
- AS_VAR_POPDEF([VAR])dnl
-])
-
-dnl @synopsis AX_CPP_VARARG_MACRO_ISO
-dnl
-dnl Test if the preprocessor understands ISO C 1999 vararg macros.
-dnl If it does, defines HAVE_CPP_VARARG_MACRO_ISO to 1.
-dnl
-dnl @version
-dnl @author James Yonan <jim@yonan.net>, Matthias Andree <matthias.andree@web.de>
-AC_DEFUN([AX_CPP_VARARG_MACRO_ISO], [dnl
- AS_VAR_PUSHDEF([VAR],[ax_cv_cpp_vararg_macro_iso])dnl
- AC_CACHE_CHECK(
- [for ISO C 1999 vararg macro support],
- [VAR],
- [AC_COMPILE_IFELSE(
- [AC_LANG_PROGRAM(
- [[
-#define macro(a, ...) func(a, __VA_ARGS__)
-int func(int a, int b, int c);
- ]],
- [[
-int i = macro(1, 2, 3);
- ]]
- )],
- [VAR=yes],
- [VAR=no]
- )]
- )dnl
-
- AS_VAR_IF(
- [VAR],
- [yes],
- [AC_DEFINE(
- [HAVE_CPP_VARARG_MACRO_ISO],
- [1],
- [Define to 1 if your compiler supports ISO C99 variadic macros]
- )]
- )dnl
- AS_VAR_POPDEF([VAR])dnl
-])