Bug #80071 NDB TEST PROGRAMS opt_core COMPILATION FAILURE
Submitted: 20 Jan 2016 11:30 Modified: 27 Jan 2016 14:58
Reporter: Magnus Blåudd Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Cluster: Cluster (NDB) storage engine Severity:S3 (Non-critical)
Version:7.5.1 OS:Any
Assigned to: CPU Architecture:Any

[20 Jan 2016 11:30] Magnus Blåudd
Description:
The testfk program falis to compile on Windows due to unresolved external "opt_core". The opt_core variable is provided from ndb_opts.c and is a variable in the standard option processing of ndb_ programs which you activate by including ndb_opts.h

This standard option processing should be done by all ndb_ program. i.e our ndb tools, but need not be done by all test* programs.

How to repeat:
Compile the NDB test programs on Windows. Using "cmake -DWITH_NDB_TEST=1"

Error	9	error LNK2001: unresolved external symbol "char opt_core" (?opt_core@@3DA)	D:\ade\mysql\7.5\bld\storage\ndb\test\ndbapi\testFK.obj	testFK
Error	10	error LNK1120: 1 unresolved externals	D:\ade\mysql\7.5\bld\storage\ndb\test\ndbapi\RelWithDebInfo\testFK.exe	testFK

Suggested fix:
There is probably a missing 'extern "C"' when the opt_core variable is referenced in testFk.cpp

But probably we need not refernce opt_core from that test, since it's a test program it can core always or behave like the other test programs. See no need for special behavious in this test program.

Fix in 7.4 if it occurs there as well.
[27 Jan 2016 14:58] Jon Stephens
Fixed in NDB 7.4.11 & 7.5.1.

Testing only--no end user changes to document.

Closed.