Updated CMake stuff to handle the configurations needed for release

builds.


cmakelists.txt:
  Get the correct options for storage engines and defines from
  config-version.js.
mysys/cmakelists.txt:
  Set USE_TLS only for release builds, as it crashes in debug builds.
sql/cmakelists.txt:
  Fix build options to only include the configured storage engines.
sql/mysqld.cc:
  Fix dummy innodb declarations, otherwise non-innodb build fails.
storage/bdb/cmakelists.txt:
  Create cmakelists.txt for BDB.
win/README:
  Update with new configure.js options.
win/config-handlerton.js:
  Extend with more storage engines.
win/config-version.js:
  Extend to handle storage engines and other configuration parameters.
This commit is contained in:
unknown 2006-03-23 16:34:52 +01:00
commit f19b2c0a00
9 changed files with 235 additions and 39 deletions

View file

@ -34,12 +34,25 @@ Clone your bk tree to any location you like.
Step 4
------
From the root of your bk clone, execute the command: win\configure <options>.
The options right now are WITH_INNODB and WITH_PARTITION. So the command line
would look like:
The options right now are
win\configure WITH_INNODB WITH_PARTITION
WITH_INNOBASE_STORAGE_ENGINE Enable particular storage engines
WITH_PARTITION_STORAGE_ENGINE
WITH_ARCHIVE_STORAGE_ENGINE
WITH_BERKELEY_STORAGE_ENGINE
WITH_BLACKHOLE_STORAGE_ENGINE
WITH_EXAMPLE_STORAGE_ENGINE
WITH_FEDERATED_STORAGE_ENGINE
WITH_INNOBASE_STORAGE_ENGINE
__NT__ Enable named pipe support
MYSQL_SERVER_SUFFIX=<suffix> Server suffix, default none
COMPILATION_COMMENT=<comment> Server comment, default "Source distribution"
MYSQL_TCP_PORT=<port> Server port, default 3306
CYBOZU
These are the only two flags supported right now. Others will come later.
So the command line could look like:
win\configure WITH_INNOBASE_STORAGE_ENGINE WITH_PARTITION_STORAGE_ENGINE MYSQL_SERVER_SUFFIX=-pro
Step 5
------
@ -60,11 +73,5 @@ click the build solution menu option.
Current issues
--------------
1. Not all configurations are currently available. i.e. Classic, Pro, Max.
Currently, only debug and release are available. This will change in the near
future.
2. The definitions set for features (partitioning, blackhole, etc) are not
changed based on the options given with configure. This will soon be fixed
as well.
1. After changing configuration (eg. adding or removing a storage engine), it
may be necessary to clean the build tree to remove any stale objects.

View file

@ -17,16 +17,41 @@ try
while (! datafile.AtEndOfStream)
{
var line = datafile.ReadLine();
if (line == "WITH_INNODB")
if (line == "WITH_INNOBASE_STORAGE_ENGINE")
{
extern_line += ",innobase_hton";
address_line += ",&innobase_hton";
}
else if (line == "WITH_PARTITION")
else if (line == "WITH_PARTITION_STORAGE_ENGINE")
{
extern_line += ",partition_hton";
address_line += ",&partition_hton";
}
else if (line == "WITH_ARCHIVE_STORAGE_ENGINE")
{
extern_line += ",archive_hton";
address_line += ",&archive_hton";
}
else if (line == "WITH_BERKELEY_STORAGE_ENGINE")
{
extern_line += ",berkeley_hton";
address_line += ",&berkeley_hton";
}
else if (line == "WITH_BLACKHOLE_STORAGE_ENGINE")
{
extern_line += ",blackhole_hton";
address_line += ",&blackhole_hton";
}
else if (line == "WITH_EXAMPLE_STORAGE_ENGINE")
{
extern_line += ",example_hton";
address_line += ",&example_hton";
}
else if (line == "WITH_FEDERATED_STORAGE_ENGINE")
{
extern_line += ",federated_hton";
address_line += ",&federated_hton";
}
}
datafile.Close();

View file

@ -9,11 +9,91 @@ try
// first we attempt to open the main configure.in file
var fso = new ActiveXObject("Scripting.FileSystemObject");
var args = WScript.Arguments
// Find any configured MYSQL_SERVER_SUFFIX.
// Find any extra preprocessor definitions.
var datafile = fso.OpenTextFile(args.Item(0), ForReading);
var server_suffix = '';
var server_comment = 'Source distribution';
var server_port = '';
var defs = '';
var htons = '';
var subdirs = '';
var depends = '';
while (! datafile.AtEndOfStream)
{
var line = datafile.ReadLine();
if (line.indexOf("MYSQL_SERVER_SUFFIX=") == 0)
{
server_suffix = line.substring(20, line.length);
}
else if (line.indexOf("COMPILATION_COMMENT=") == 0)
{
server_comment = line.substring(20, line.length);
}
else if (line.indexOf("MYSQL_TCP_PORT=") == 0)
{
server_port = line.substring(15, line.length);
}
else if (line == "WITH_ARCHIVE_STORAGE_ENGINE")
{
defs += " -D" + line;
htons += " ha_archive.cc";
subdirs += " storage/archive";
depends += " archive";
}
else if (line == "WITH_BERKELEY_STORAGE_ENGINE")
{
defs += " -D" + line;
htons += " ha_berkeley.cc";
subdirs += " storage/bdb";
depends += " bdb";
}
else if (line == "WITH_BLACKHOLE_STORAGE_ENGINE")
{
defs += " -D" + line;
htons += " ha_blackhole.cc";
}
else if (line == "WITH_EXAMPLE_STORAGE_ENGINE")
{
defs += " -D" + line;
subdirs += " storage/example";
depends += " example";
}
else if (line == "WITH_FEDERATED_STORAGE_ENGINE")
{
defs += " -D" + line;
htons += " ha_federated.cc";
}
else if (line == "WITH_INNOBASE_STORAGE_ENGINE")
{
defs += " -D" + line;
htons += " ha_innodb.cc";
subdirs += " storage/innobase";
depends += " innobase";
}
else if (line == "WITH_PARTITION_STORAGE_ENGINE")
{
defs += " -D" + line;
htons += " ha_partition.cc";
}
else if (line == "__NT__" ||
line == "CYBOZU" ||
line.indexOf("LICENSE=") == 0) {
defs += " -D" + line;
}
}
datafile.Close();
ConfigureMySqlVersion();
//ConfigureBDB();
fso = null;
WScript.Echo("done!");
WScript.Echo("DEFINITIONS@" + defs + "@");
WScript.Echo("HANDLERTONS@" + htons + "@");
WScript.Echo("DEPENDS@" + depends + "@");
WScript.Echo("SUBDIRS@" + subdirs + "@");
}
catch (e)
{
@ -63,10 +143,11 @@ function ConfigureMySqlVersion()
mysqlin = mysqlin.replace("@PROTOCOL_VERSION@", GetValue(configureIn, "PROTOCOL_VERSION"));
mysqlin = mysqlin.replace("@DOT_FRM_VERSION@", GetValue(configureIn, "DOT_FRM_VERSION"));
mysqlin = mysqlin.replace("@MYSQL_TCP_PORT@", GetValue(configureIn, "MYSQL_TCP_PORT_DEFAULT"));
if (server_port == '') { server_port = GetValue(configureIn, "MYSQL_TCP_PORT_DEFAULT"); }
mysqlin = mysqlin.replace("@MYSQL_TCP_PORT@", server_port);
mysqlin = mysqlin.replace("@MYSQL_UNIX_ADDR@", GetValue(configureIn, "MYSQL_UNIX_ADDR_DEFAULT"));
mysqlin = mysqlin.replace("@MYSQL_SERVER_SUFFIX@", '');
mysqlin = mysqlin.replace("@COMPILATION_COMMENT@", 'Source distribution');
mysqlin = mysqlin.replace("@MYSQL_SERVER_SUFFIX@", server_suffix);
mysqlin = mysqlin.replace("@COMPILATION_COMMENT@", server_comment);
var version = GetVersion(configureIn);