From: MichaƂ Skalski Date: Sun, 24 Jan 2021 20:14:57 +0000 (+0100) Subject: pkcs11: Fix build on Windows X-Git-Tag: 5.9.2dr2~18 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f30187d422ae062d311f7b9c12de867c3ca8fe22;p=thirdparty%2Fstrongswan.git pkcs11: Fix build on Windows Windows provides CreateMutexA/W with an alias called CreateMutex that selects one of the other two based on the UNICODE constant. --- diff --git a/src/libstrongswan/plugins/pkcs11/pkcs11_library.c b/src/libstrongswan/plugins/pkcs11/pkcs11_library.c index 119126fedd..6c0dda3fa1 100644 --- a/src/libstrongswan/plugins/pkcs11/pkcs11_library.c +++ b/src/libstrongswan/plugins/pkcs11/pkcs11_library.c @@ -18,7 +18,12 @@ #include "pkcs11_library.h" +#ifndef WIN32 #include +#else +/* macro defined by synchapi.h that maps to CreateMutexA/W */ +#undef CreateMutex +#endif #include #include