Change in openvpn[master]: configure/CMake: Unify Windows handling
A message that is not in the archive (sent off-list or not yet received): gerrit.1764176932000.Ic55e1288b0d3160e68eef07ff4edbb070a03dd31@...2715...
Attention is currently required from: plaisthos.
Hello plaisthos,
I'd like you to do a code review.
Please visit
http://gerrit.openvpn.net/c/openvpn/+/1410?usp=email
to review the following change.
Change subject: configure/CMake: Unify Windows handling
......................................................................
configure/CMake: Unify Windows handling
Some things were detected in configure.ac and just hard-coded in CMake. Move the hard-coding to syshead.h instead and remove the additional code in configure.ac. These are really Windows-specific so I think not dynamically detecting is okay.
---
M config.h.cmake.in
M configure.ac
M src/openvpn/syshead.h
3 files changed, 29 insertions(+), 83 deletions(-)
git pull ssh://gerrit.openvpn.net:29418/openvpn refs/changes/10/1410/1
config.h.cmake.in +0 -29
@@ -411,32 +411,3 @@ #ifndef _GNU_SOURCE # define _GNU_SOURCE 1 #endif - -/* if inttypes.h is included this breaks rc.exe when using the ClangCL - * Toolchain as it pulls in a inttypes.h variant for clang that rc.exe does - * not understand (#include_next preprocessor directive) */ -#if defined(_WIN32) && !defined(RC_INVOKED) -#include <inttypes.h> -typedef uint32_t in_addr_t; -typedef uint16_t in_port_t; - -#define SIGHUP 1 -#define SIGINT 2 -#define SIGUSR1 10 -#define SIGUSR2 12 -#define SIGTERM 15 -#endif - -#if defined(_MSC_VER) && !defined(RC_INVOKED) -#include <BaseTsd.h> -typedef SSIZE_T ssize_t; -#define strncasecmp strnicmp -#define strcasecmp _stricmp - -#define S_IRUSR _S_IREAD -#define S_IWUSR _S_IWRITE -#define R_OK 4 -#define W_OK 2 -#define X_OK 1 -#define F_OK 0 -#endif
configure.ac +0 -54
66 lines not on this page · raw message
src/openvpn/syshead.h +29 -0
@@ -44,6 +44,35 @@#define srandom srand#endif +/* if inttypes.h is included this breaks rc.exe when using the ClangCL +* Toolchain as it pulls in a inttypes.h variant for clang that rc.exe does +* not understand (#include_next preprocessor directive) */ +#if defined(_WIN32) && !defined(RC_INVOKED ) +#include <inttypes.h> +typedef uint32_t in_addr_t ; +typedef uint16_t in_port_t ; + +#define SIGHUP 1 +#define SIGINT 2 +#define SIGUSR1 10 +#define SIGUSR2 12 +#define SIGTERM 15 +#endif + +#if defined(_MSC_VER) && !defined(RC_INVOKED ) +#include <BaseTsd.h> +typedef SSIZE_T ssize_t ; +#define strncasecmp strnicmp +#define strcasecmp _stricmp + +#define S_IRUSR _S_IREAD +#define S_IWUSR _S_IWRITE +#define R_OK 4 +#define W_OK 2 +#define X_OK 1 +#define F_OK 0 +#endif +#if defined(_MSC_VER) && !defined(__clang__)/* Microsoft compiler */ #define __func__ __FUNCTION__#define __attribute__ (x)
--
To view, visit http://gerrit.openvpn.net/c/openvpn/+/1410?usp=email
To unsubscribe, or for help writing mail filters, visit http://gerrit.openvpn.net/settings?usp=email
Gerrit-MessageType: newchange
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: Ic55e1288b0d3160e68eef07ff4edbb070a03dd31
Gerrit-Change-Number: 1410
Gerrit-PatchSet: 1
Gerrit-Owner: flichtenheld <[email protected]...>
Gerrit-Reviewer: plaisthos <[email protected]...>
Gerrit-CC: openvpn-devel <[email protected]>
Gerrit-Attention: plaisthos <[email protected]...>
Attention is currently required from: flichtenheld.
plaisthos has posted comments on this change by flichtenheld. ( http://gerrit.openvpn.net/c/openvpn/+/1410?usp=email )
Change subject: configure/CMake: Unify Windows handling
......................................................................
Patch Set 2: Code-Review+2
--
To view, visit http://gerrit.openvpn.net/c/openvpn/+/1410?usp=email
To unsubscribe, or for help writing mail filters, visit http://gerrit.openvpn.net/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: Ic55e1288b0d3160e68eef07ff4edbb070a03dd31
Gerrit-Change-Number: 1410
Gerrit-PatchSet: 2
Gerrit-Owner: flichtenheld <[email protected]...>
Gerrit-Reviewer: plaisthos <[email protected]...>
Gerrit-CC: openvpn-devel <[email protected]>
Gerrit-Attention: flichtenheld <[email protected]...>
Gerrit-Comment-Date: Thu, 27 Nov 2025 10:22:57 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
PATCH v2 1/1 configure/CMake: Unify Windows handling
In reply to a message not in the archiveFrom: Frank Lichtenheld <[email protected]...>
Some things were detected in configure.ac and just hard-coded in CMake. Move the hard-coding to syshead.h instead and remove the additional code in configure.ac. These are really Windows-specific so I think not dynamically detecting is okay.
Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/1410
---
This change was reviewed on Gerrit and approved by at least one developer. I request to merge it to master.
Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/1410
This mail reflects revision 2 of this Change.
Acked-by according to Gerrit (reflected above):
Arne Schwabe <[email protected]...>
config.h.cmake.in +0 -29
@@ -411,32 +411,3 @@ #ifndef _GNU_SOURCE # define _GNU_SOURCE 1 #endif - -/* if inttypes.h is included this breaks rc.exe when using the ClangCL - * Toolchain as it pulls in a inttypes.h variant for clang that rc.exe does - * not understand (#include_next preprocessor directive) */ -#if defined(_WIN32) && !defined(RC_INVOKED) -#include <inttypes.h> -typedef uint32_t in_addr_t; -typedef uint16_t in_port_t; - -#define SIGHUP 1 -#define SIGINT 2 -#define SIGUSR1 10 -#define SIGUSR2 12 -#define SIGTERM 15 -#endif - -#if defined(_MSC_VER) && !defined(RC_INVOKED) -#include <BaseTsd.h> -typedef SSIZE_T ssize_t; -#define strncasecmp strnicmp -#define strcasecmp _stricmp - -#define S_IRUSR _S_IREAD -#define S_IWUSR _S_IWRITE -#define R_OK 4 -#define W_OK 2 -#define X_OK 1 -#define F_OK 0 -#endif
configure.ac +0 -54
66 lines not on this page · raw message
src/openvpn/syshead.h +29 -0
@@ -44,6 +44,35 @@#define srandom srand#endif +/* if inttypes.h is included this breaks rc.exe when using the ClangCL +* Toolchain as it pulls in a inttypes.h variant for clang that rc.exe does +* not understand (#include_next preprocessor directive) */ +#if defined(_WIN32) && !defined(RC_INVOKED ) +#include <inttypes.h> +typedef uint32_t in_addr_t ; +typedef uint16_t in_port_t ; + +#define SIGHUP 1 +#define SIGINT 2 +#define SIGUSR1 10 +#define SIGUSR2 12 +#define SIGTERM 15 +#endif + +#if defined(_MSC_VER) && !defined(RC_INVOKED ) +#include <BaseTsd.h> +typedef SSIZE_T ssize_t ; +#define strncasecmp strnicmp +#define strcasecmp _stricmp + +#define S_IRUSR _S_IREAD +#define S_IWUSR _S_IWRITE +#define R_OK 4 +#define W_OK 2 +#define X_OK 1 +#define F_OK 0 +#endif +#if defined(_MSC_VER) && !defined(__clang__)/* Microsoft compiler */ #define __func__ __FUNCTION__#define __attribute__ (x)
[Openvpn-devel] [PATCH applied] Re: configure/CMake: Unify Windows handling
Aaand another one. This one I have tested on Ubuntu 24.04/MinGW64 with autoconf, because BB only does cmake building (IIRC?), and also pushed to GHA (more windows build variants, windows UTs). All green.
Your patch has been applied to the master branch.
commit afdf0028808b9b7809059f3368a396dcbcdf2565
Author: Frank Lichtenheld Date: Thu Nov 27 11:37:05 2025 +0100
configure/CMake: Unify Windows handling
Signed-off-by: Frank Lichtenheld <[email protected]...>
Acked-by: Arne Schwabe <[email protected]...>
Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/1410
Message-Id: <[email protected]...>
URL: https://www.mail-archive.com/[email protected]/msg34736.html
Signed-off-by: Gert Doering <[email protected]...>--
kind regards,
Gert Doering
[Openvpn-devel] [PATCH applied] Re: configure/CMake: Unify Windows handling
In reply to Gert DoeringAaand another one. This one I have tested on Ubuntu 24.04/MinGW64 with autoconf, because BB only does cmake building (IIRC?), and also pushed to GHA (more windows build variants, windows UTs). All green.
Your patch has been applied to the master branch.
commit afdf0028808b9b7809059f3368a396dcbcdf2565
Author: Frank Lichtenheld Date: Thu Nov 27 11:37:05 2025 +0100
configure/CMake: Unify Windows handling
Signed-off-by: Frank Lichtenheld <[email protected]...>
Acked-by: Arne Schwabe <[email protected]...>
Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/1410
Message-Id: <[email protected]...>
URL: https://www.mail-archive.com/[email protected]/msg34736.html
Signed-off-by: Gert Doering <[email protected]...>--
kind regards,
Gert Doering
cron2 has uploaded a new patch set (#3) to the change originally created by flichtenheld. ( http://gerrit.openvpn.net/c/openvpn/+/1410?usp=email )
The following approvals got outdated and were removed:
Code-Review+2 by plaisthos
Change subject: configure/CMake: Unify Windows handling
......................................................................
configure/CMake: Unify Windows handling
Some things were detected in configure.ac and just hard-coded in CMake. Move the hard-coding to syshead.h instead and remove the additional code in configure.ac. These are really Windows-specific so I think not dynamically detecting is okay.
Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/1410
Message-Id: <[email protected]...>
URL: https://www.mail-archive.com/[email protected]/msg34736.html
---
M config.h.cmake.in
M configure.ac
M src/openvpn/syshead.h
3 files changed, 29 insertions(+), 83 deletions(-)
git pull ssh://gerrit.openvpn.net:29418/openvpn refs/changes/10/1410/3
config.h.cmake.in +0 -29
@@ -411,32 +411,3 @@ #ifndef _GNU_SOURCE # define _GNU_SOURCE 1 #endif - -/* if inttypes.h is included this breaks rc.exe when using the ClangCL - * Toolchain as it pulls in a inttypes.h variant for clang that rc.exe does - * not understand (#include_next preprocessor directive) */ -#if defined(_WIN32) && !defined(RC_INVOKED) -#include <inttypes.h> -typedef uint32_t in_addr_t; -typedef uint16_t in_port_t; - -#define SIGHUP 1 -#define SIGINT 2 -#define SIGUSR1 10 -#define SIGUSR2 12 -#define SIGTERM 15 -#endif - -#if defined(_MSC_VER) && !defined(RC_INVOKED) -#include <BaseTsd.h> -typedef SSIZE_T ssize_t; -#define strncasecmp strnicmp -#define strcasecmp _stricmp - -#define S_IRUSR _S_IREAD -#define S_IWUSR _S_IWRITE -#define R_OK 4 -#define W_OK 2 -#define X_OK 1 -#define F_OK 0 -#endif
configure.ac +0 -54
66 lines not on this page · raw message
src/openvpn/syshead.h +29 -0
@@ -44,6 +44,35 @@#define srandom srand#endif +/* if inttypes.h is included this breaks rc.exe when using the ClangCL +* Toolchain as it pulls in a inttypes.h variant for clang that rc.exe does +* not understand (#include_next preprocessor directive) */ +#if defined(_WIN32) && !defined(RC_INVOKED ) +#include <inttypes.h> +typedef uint32_t in_addr_t ; +typedef uint16_t in_port_t ; + +#define SIGHUP 1 +#define SIGINT 2 +#define SIGUSR1 10 +#define SIGUSR2 12 +#define SIGTERM 15 +#endif + +#if defined(_MSC_VER) && !defined(RC_INVOKED ) +#include <BaseTsd.h> +typedef SSIZE_T ssize_t ; +#define strncasecmp strnicmp +#define strcasecmp _stricmp + +#define S_IRUSR _S_IREAD +#define S_IWUSR _S_IWRITE +#define R_OK 4 +#define W_OK 2 +#define X_OK 1 +#define F_OK 0 +#endif +#if defined(_MSC_VER) && !defined(__clang__)/* Microsoft compiler */ #define __func__ __FUNCTION__#define __attribute__ (x)
--
To view, visit http://gerrit.openvpn.net/c/openvpn/+/1410?usp=email
To unsubscribe, or for help writing mail filters, visit http://gerrit.openvpn.net/settings?usp=email
Gerrit-MessageType: newpatchset
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: Ic55e1288b0d3160e68eef07ff4edbb070a03dd31
Gerrit-Change-Number: 1410
Gerrit-PatchSet: 3
Gerrit-Owner: flichtenheld <[email protected]...>
Gerrit-Reviewer: plaisthos <[email protected]...>
Gerrit-CC: openvpn-devel <[email protected]>
cron2 has submitted this change. ( http://gerrit.openvpn.net/c/openvpn/+/1410?usp=email )
Change subject: configure/CMake: Unify Windows handling
......................................................................
configure/CMake: Unify Windows handling
Some things were detected in configure.ac and just hard-coded in CMake. Move the hard-coding to syshead.h instead and remove the additional code in configure.ac. These are really Windows-specific so I think not dynamically detecting is okay.
Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/1410
Message-Id: <[email protected]...>
URL: https://www.mail-archive.com/[email protected]/msg34736.html
---
M config.h.cmake.in
M configure.ac
M src/openvpn/syshead.h
3 files changed, 29 insertions(+), 83 deletions(-)
config.h.cmake.in +0 -29
@@ -411,32 +411,3 @@ #ifndef _GNU_SOURCE # define _GNU_SOURCE 1 #endif - -/* if inttypes.h is included this breaks rc.exe when using the ClangCL - * Toolchain as it pulls in a inttypes.h variant for clang that rc.exe does - * not understand (#include_next preprocessor directive) */ -#if defined(_WIN32) && !defined(RC_INVOKED) -#include <inttypes.h> -typedef uint32_t in_addr_t; -typedef uint16_t in_port_t; - -#define SIGHUP 1 -#define SIGINT 2 -#define SIGUSR1 10 -#define SIGUSR2 12 -#define SIGTERM 15 -#endif - -#if defined(_MSC_VER) && !defined(RC_INVOKED) -#include <BaseTsd.h> -typedef SSIZE_T ssize_t; -#define strncasecmp strnicmp -#define strcasecmp _stricmp - -#define S_IRUSR _S_IREAD -#define S_IWUSR _S_IWRITE -#define R_OK 4 -#define W_OK 2 -#define X_OK 1 -#define F_OK 0 -#endif
configure.ac +0 -54
66 lines not on this page · raw message
src/openvpn/syshead.h +29 -0
@@ -44,6 +44,35 @@#define srandom srand#endif +/* if inttypes.h is included this breaks rc.exe when using the ClangCL +* Toolchain as it pulls in a inttypes.h variant for clang that rc.exe does +* not understand (#include_next preprocessor directive) */ +#if defined(_WIN32) && !defined(RC_INVOKED ) +#include <inttypes.h> +typedef uint32_t in_addr_t ; +typedef uint16_t in_port_t ; + +#define SIGHUP 1 +#define SIGINT 2 +#define SIGUSR1 10 +#define SIGUSR2 12 +#define SIGTERM 15 +#endif + +#if defined(_MSC_VER) && !defined(RC_INVOKED ) +#include <BaseTsd.h> +typedef SSIZE_T ssize_t ; +#define strncasecmp strnicmp +#define strcasecmp _stricmp + +#define S_IRUSR _S_IREAD +#define S_IWUSR _S_IWRITE +#define R_OK 4 +#define W_OK 2 +#define X_OK 1 +#define F_OK 0 +#endif +#if defined(_MSC_VER) && !defined(__clang__)/* Microsoft compiler */ #define __func__ __FUNCTION__#define __attribute__ (x)
--
To view, visit http://gerrit.openvpn.net/c/openvpn/+/1410?usp=email
To unsubscribe, or for help writing mail filters, visit http://gerrit.openvpn.net/settings?usp=email
Gerrit-MessageType: merged
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: Ic55e1288b0d3160e68eef07ff4edbb070a03dd31
Gerrit-Change-Number: 1410
Gerrit-PatchSet: 3
Gerrit-Owner: flichtenheld <[email protected]...>
Gerrit-Reviewer: plaisthos <[email protected]...>
Gerrit-CC: openvpn-devel <[email protected]>