List:Commits« Previous MessageNext Message »
From:Rafal Somla Date:June 3 2011 11:44am
Subject:bzr commit into mysql-5.5 branch (rafal.somla:3426) Bug#12612143
View as plain text  
#At file:///D:/source/bzr2/mysql-5.5/ based on revid:vasil.dimov@stripped

 3426 Rafal Somla	2011-06-03
      Bug#12612143 - LIBMYSQL 5.5.13 BREAKS USER APPLICATION BUILD
      
      Since the Windows authentication support has been added to libmysql, this library depends on the system Secur32 library. Consequently, clients which are linked against libmysql should be also linked with Secur32 (in addition to ws2_32).
      
      In MS VC++ it is possible to embed information about required libraries into object file using #pragma directive. This patch adds such directive when the Windows authentiaction support is compiled. This is similar to analogous #pragma for ws2_32 library in my_init.c

    modified:
      libmysql/authentication_win/plugin_client.cc
=== modified file 'libmysql/authentication_win/plugin_client.cc'
--- a/libmysql/authentication_win/plugin_client.cc	2011-04-28 19:17:29 +0000
+++ b/libmysql/authentication_win/plugin_client.cc	2011-06-03 11:44:33 +0000
@@ -20,6 +20,16 @@
 
 #include "common.h"
 
+/*
+  The following MS C++ specific pragma embeds a comment in the resulting
+  object file. A "lib" comment tells the linker to use the specified 
+  library, thus the dependency is handled automagically.
+*/
+
+#ifdef _MSC_VER
+#pragma comment(lib, "Secur32")
+#endif
+
 static int win_auth_client_plugin_init(char*, size_t, int, va_list)
 {
   return 0;


Attachment: [text/bzr-bundle] bzr/rafal.somla@oracle.com-20110603114433-igs88mozmspm9y2l.bundle
Thread
bzr commit into mysql-5.5 branch (rafal.somla:3426) Bug#12612143Rafal Somla4 Jun