Description:
Build on SunStudio12 has been broken by usage of non standard C++ features.
These problems are also reported by Pushbuild2 on the Telco-6.4 branch:
----------------
2.
=== modified file 'storage/ndb/include/ndbinfo.h'
--- storage/ndb/include/ndbinfo.h 2008-10-08 10:52:32 +0000
+++ storage/ndb/include/ndbinfo.h 2008-10-15 11:52:11 +0000
@@ -39,7 +39,7 @@
struct ndbinfo_table {
NDBINFO_TABLE_MEMBERS
- struct ndbinfo_column col[];
+ struct ndbinfo_column col[0];
};
Arrays with 'flexible size' is only allowed as function argument. It was not possible to
get this through the compiler without defining it as '[0]'. However, this is non-standard C++ code and requires the addition of '-features=zla' to compile.
3. opt_ndb_connectstring and opt_ndb_constrbuf_len 'defined twice' when linking mysqld:
Handling of OPT_NDB_MGMD , OPT_NODED_ID and OPT_NDB_CONNECTSTRING
was added to ndb_opts.c. This duplicates code - and declaration - found in mysqld.cc.
A fix to this problem may be to declare these variables extern in mysqld.cc. However, I am not sure if this may break other code (At least it compiles & links)
=== modified file 'sql/mysqld.cc'
--- sql/mysqld.cc 2008-10-03 12:02:23 +0000
+++ sql/mysqld.cc 2008-10-16 12:12:28 +0000
@@ -412,9 +412,11 @@
#ifdef WITH_NDBCLUSTER_STORAGE_ENGINE
const char *opt_ndbcluster_connectstring= 0;
-const char *opt_ndb_connectstring= 0;
+extern const char *opt_ndb_connectstring;
char opt_ndb_constrbuf[1024]= {0};
-unsigned opt_ndb_constrbuf_len= 0;
+extern unsigned opt_ndb_constrbuf_len;
my_bool opt_ndb_shm;
ulong opt_ndb_cache_check_time, opt_ndb_wait_connected;
ulong opt_ndb_cluster_connection_pool;
4: Syntax error compiling APIService.cpp - explicit call of SocketServer::Session c'tor not allowed:
=== modified file 'storage/ndb/src/cw/cpcd/APIService.cpp'
--- storage/ndb/src/cw/cpcd/APIService.cpp 2008-09-17 13:23:21 +0000
+++ storage/ndb/src/cw/cpcd/APIService.cpp 2008-10-15 13:47:41 +0000
@@ -151,8 +151,8 @@
}
CPCDAPISession::CPCDAPISession(FILE * f, CPCD & cpcd)
- : SocketServer::Session::Session(my_socket_create_invalid())
+ : SocketServer::Session(my_socket_create_invalid())
, m_cpcd(cpcd)
{
m_input = new FileInputStream(f);
m_parser = new Parser<CPCDAPISession>(commands, *m_input, true, true, true);
How to repeat:
Try to compile the code, Look pushbuild2 compile logs. for 'Sol10'
Suggested fix:
See above diff for the involved files