Skip to content

Commit 2f6c4e4

Browse files
committed
WL#15166 patch #4 Win32 fixes
On Win32, every binary needs one instance of openssl/applink.c. MySQL has one in client_authentication.cc, and this one is present in the server and in the client library. This patch adds instances to ndb_sign_keys, ndb_mgmd, ndbd, and testNodeCertificate-t, and includes fixes for other assorted compiler errors and warnings on Win32. Change-Id: I2d7f940b92ddac7d860d2c6fc2d98ead23e195b2
1 parent ddade52 commit 2f6c4e4

File tree

4 files changed

+15
-0
lines changed

4 files changed

+15
-0
lines changed

storage/ndb/src/common/util/NodeCertificate.cpp

+1
Original file line numberDiff line numberDiff line change
@@ -1344,6 +1344,7 @@ bool NodeCertificate::parse_name(const char * name) {
13441344
#ifdef TEST_NODECERTIFICATE
13451345

13461346
#ifdef _WIN32
1347+
#include <openssl/applink.c>
13471348
static constexpr bool isWin32 = 1;
13481349
#else
13491350
static constexpr bool isWin32 = 0;

storage/ndb/src/kernel/main.cpp

+5
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,11 @@
3737

3838
#include <EventLogger.hpp>
3939

40+
/* On Win32 applink.c must be included in one compilation unit */
41+
#ifdef _WIN32
42+
#include <openssl/applink.c>
43+
#endif
44+
4045
#define JAM_FILE_ID 485
4146

4247
#if defined VM_TRACE

storage/ndb/src/mgmsrv/main.cpp

+4
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,10 @@
4545
#include <LogBuffer.hpp>
4646
#include <OutputStream.hpp>
4747

48+
/* On Win32 applink.c must be included in one compilation unit */
49+
#ifdef _WIN32
50+
#include <openssl/applink.c>
51+
#endif
4852

4953
#if defined VM_TRACE || defined ERROR_INSERT
5054
extern int g_errorInsert;

storage/ndb/tools/sign_keys.cpp

+5
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,11 @@
5353
#include "util/SocketServer.hpp"
5454
#include "util/TlsKeyErrors.h"
5555

56+
/* On Win32 applink.c must be included in one compilation unit */
57+
#ifdef _WIN32
58+
#include <openssl/applink.c>
59+
#endif
60+
5661
/* ndb_basename() is not declared in any header file: */
5762
const char * ndb_basename(const char *path);
5863

0 commit comments

Comments
 (0)