Commit f9b856b0 authored by Marko Mäkelä's avatar Marko Mäkelä

Merge 10.2 into 10.3

parents d5bcccda 7d6617e9
......@@ -159,7 +159,7 @@ sub my_build_path_list {
# User can select to look in a special build dir
# which is a subdirectory of any of the paths
my @extra_dirs;
my $build_dir= $::opt_vs_config || $ENV{MTR_VS_CONFIG} || $ENV{MTR_BUILD_DIR};
my $build_dir= $::multiconfig || $ENV{MTR_VS_CONFIG} || $ENV{MTR_BUILD_DIR};
push(@extra_dirs, $build_dir) if defined $build_dir;
if (defined $extension){
......
......@@ -141,7 +141,7 @@ our $opt_tmpdir; # A path but set directly on cmd line
# configuration used to build them. To make life easier, an environment
# variable or command-line option may be specified to control which set of
# executables will be used by the test suite.
our $opt_vs_config = $ENV{'MTR_VS_CONFIG'};
our $multiconfig = $ENV{'MTR_VS_CONFIG'};
our $default_vardir;
......@@ -502,7 +502,7 @@ sub command_line_setup () {
'compress' => \$opt_compress,
'bench' => \$opt_bench,
'small-bench' => \$opt_small_bench,
'vs-config' => \$opt_vs_config,
'vs-config' => \$multiconfig,
# Control what test suites or cases to run
'force' => \$opt_force,
......@@ -2213,9 +2213,9 @@ sub vs_config_dirs ($$) {
$exe = "" if not defined $exe;
if ($opt_vs_config)
if ($multiconfig)
{
return ("$glob_bindir/$path_part/$opt_vs_config/$exe");
return ("$glob_bindir/$path_part/$multiconfig/$exe");
}
return ("$glob_bindir/$path_part/release/$exe",
......
......@@ -172,7 +172,7 @@ my $path_config_file; # The generated config file, var/my.cnf
# configuration used to build them. To make life easier, an environment
# variable or command-line option may be specified to control which set of
# executables will be used by the test suite.
our $opt_vs_config = $ENV{'MTR_VS_CONFIG'};
our $multiconfig = $ENV{'MTR_VS_CONFIG'};
my @DEFAULT_SUITES= qw(
main-
......@@ -426,7 +426,7 @@ sub check_wsrep_support() {
my $my_print_defaults_exe=
mtr_exe_maybe_exists(
"$bindir/extra/my_print_defaults",
"$bindir/extra/Debug/my_print_defaults",
"$bindir/extra/$multiconfig/my_print_defaults",
"$path_client_bindir/my_print_defaults");
my $epath= "";
if ($my_print_defaults_exe ne "") {
......@@ -487,7 +487,7 @@ sub check_mariabackup_support() {
$mariabackup_path= "";
$mariabackup_exe=
mtr_exe_maybe_exists(
"$bindir/extra/mariabackup$opt_vs_config/mariabackup",
"$bindir/extra/mariabackup$multiconfig/mariabackup",
"$path_client_bindir/mariabackup");
if ($mariabackup_exe ne "") {
my $bpath= dirname($mariabackup_exe);
......@@ -499,7 +499,7 @@ sub check_mariabackup_support() {
$ENV{XTRABACKUP}= $mariabackup_exe;
$ENV{XBSTREAM}= mtr_exe_maybe_exists(
"$bindir/extra/mariabackup/$opt_vs_config/mbstream",
"$bindir/extra/mariabackup/$multiconfig/mbstream",
"$path_client_bindir/mbstream");
$ENV{INNOBACKUPEX}= "$mariabackup_exe --innobackupex";
......@@ -1242,7 +1242,7 @@ sub command_line_setup {
'ssl|with-openssl' => \$opt_ssl,
'skip-ssl' => \$opt_skip_ssl,
'compress' => \$opt_compress,
'vs-config=s' => \$opt_vs_config,
'vs-config=s' => \$multiconfig,
# Max number of parallel threads to use
'parallel=s' => \$opt_parallel,
......@@ -1423,8 +1423,8 @@ sub command_line_setup {
{
$path_client_bindir= mtr_path_exists("$bindir/client_release",
"$bindir/client_debug",
"$bindir/client/debug",
"$bindir/client$opt_vs_config",
"$bindir/client/$multiconfig",
"$bindir/client$multiconfig",
"$bindir/client",
"$bindir/bin");
}
......@@ -1981,7 +1981,7 @@ sub executable_setup () {
if ( $opt_embedded_server )
{
$exe_mysqltest=
mtr_exe_exists("$bindir/libmysqld/examples$opt_vs_config/mysqltest_embedded",
mtr_exe_exists("$bindir/libmysqld/examples$multiconfig/mysqltest_embedded",
"$path_client_bindir/mysqltest_embedded");
}
else
......@@ -2085,10 +2085,10 @@ sub mysql_client_test_arguments(){
# mysql_client_test executable may _not_ exist
if ( $opt_embedded_server ) {
$exe= mtr_exe_maybe_exists(
"$bindir/libmysqld/examples$opt_vs_config/mysql_client_test_embedded",
"$bindir/libmysqld/examples$multiconfig/mysql_client_test_embedded",
"$bindir/bin/mysql_client_test_embedded");
} else {
$exe= mtr_exe_maybe_exists("$bindir/tests$opt_vs_config/mysql_client_test",
$exe= mtr_exe_maybe_exists("$bindir/tests$multiconfig/mysql_client_test",
"$bindir/bin/mysql_client_test");
}
......@@ -2258,7 +2258,7 @@ sub environment_setup {
my $client_config_exe=
mtr_exe_maybe_exists(
"$bindir/libmariadb/mariadb_config$opt_vs_config/mariadb_config",
"$bindir/libmariadb/mariadb_config$multiconfig/mariadb_config",
"$bindir/bin/mariadb_config");
if ($client_config_exe)
{
......@@ -2277,7 +2277,7 @@ sub environment_setup {
# some versions, test using it should be skipped
# ----------------------------------------------------
my $exe_bug25714=
mtr_exe_maybe_exists("$bindir/tests$opt_vs_config/bug25714");
mtr_exe_maybe_exists("$bindir/tests$multiconfig/bug25714");
$ENV{'MYSQL_BUG25714'}= native_path($exe_bug25714);
# ----------------------------------------------------
......@@ -2294,7 +2294,7 @@ sub environment_setup {
# my_print_defaults
# ----------------------------------------------------
my $exe_my_print_defaults=
mtr_exe_exists("$bindir/extra$opt_vs_config/my_print_defaults",
mtr_exe_exists("$bindir/extra$multiconfig/my_print_defaults",
"$path_client_bindir/my_print_defaults");
$ENV{'MYSQL_MY_PRINT_DEFAULTS'}= native_path($exe_my_print_defaults);
......@@ -2329,16 +2329,16 @@ sub environment_setup {
# ----------------------------------------------------
# perror
# ----------------------------------------------------
my $exe_perror= mtr_exe_exists("$bindir/extra$opt_vs_config/perror",
my $exe_perror= mtr_exe_exists("$bindir/extra$multiconfig/perror",
"$path_client_bindir/perror");
$ENV{'MY_PERROR'}= native_path($exe_perror);
# ----------------------------------------------------
# mysql_tzinfo_to_sql
# ----------------------------------------------------
my $exe_mysql_tzinfo_to_sql= mtr_exe_exists("$basedir/sql$opt_vs_config/mysql_tzinfo_to_sql",
my $exe_mysql_tzinfo_to_sql= mtr_exe_exists("$basedir/sql$multiconfig/mysql_tzinfo_to_sql",
"$path_client_bindir/mysql_tzinfo_to_sql",
"$bindir/sql$opt_vs_config/mysql_tzinfo_to_sql");
"$bindir/sql$multiconfig/mysql_tzinfo_to_sql");
$ENV{'MYSQL_TZINFO_TO_SQL'}= native_path($exe_mysql_tzinfo_to_sql);
# ----------------------------------------------------
......@@ -2346,7 +2346,7 @@ sub environment_setup {
# ----------------------------------------------------
my $exe_replace= mtr_exe_exists(vs_config_dirs('extra', 'replace'),
"$basedir/extra/replace",
"$bindir/extra$opt_vs_config/replace",
"$bindir/extra$multiconfig/replace",
"$path_client_bindir/replace");
$ENV{'REPLACE'}= native_path($exe_replace);
......@@ -2354,7 +2354,7 @@ sub environment_setup {
# innochecksum
# ----------------------------------------------------
my $exe_innochecksum=
mtr_exe_maybe_exists("$bindir/extra$opt_vs_config/innochecksum",
mtr_exe_maybe_exists("$bindir/extra$multiconfig/innochecksum",
"$path_client_bindir/innochecksum");
if ($exe_innochecksum)
{
......@@ -2542,10 +2542,10 @@ sub setup_vardir() {
{
if (!$opt_embedded_server)
{
for (<$bindir/storage/*$opt_vs_config/*.dll>,
<$bindir/plugin/*$opt_vs_config/*.dll>,
<$bindir/libmariadb$opt_vs_config/*.dll>,
<$bindir/sql$opt_vs_config/*.dll>)
for (<$bindir/storage/*$multiconfig/*.dll>,
<$bindir/plugin/*$multiconfig/*.dll>,
<$bindir/libmariadb$multiconfig/*.dll>,
<$bindir/sql$multiconfig/*.dll>)
{
my $pname=basename($_);
copy rel2abs($_), "$plugindir/$pname";
......@@ -2562,11 +2562,11 @@ sub setup_vardir() {
unlink "$plugindir/symlink_test";
}
for (<$bindir/storage/*/*.so>,
<$bindir/plugin/*/*.so>,
for (<$bindir/storage/*$multiconfig/*.so>,
<$bindir/plugin/*$multiconfig/*.so>,
<$bindir/libmariadb/plugins/*/*.so>,
<$bindir/libmariadb/*.so>,
<$bindir/sql/*.so>)
<$bindir/libmariadb/$multiconfig/*.so>,
<$bindir/sql$multiconfig/*.so>)
{
my $pname=basename($_);
if ($opt_use_copy)
......@@ -2688,23 +2688,24 @@ sub check_debug_support {
# executables, and plugins - that is, something that can affect the test suite
#
sub fix_vs_config_dir () {
return $opt_vs_config="" unless IS_WINDOWS;
return $opt_vs_config="/$opt_vs_config" if $opt_vs_config;
return $multiconfig="/$multiconfig" if $multiconfig;
my $modified = 1e30;
$opt_vs_config="";
$multiconfig="";
for (<$bindir/sql/*/mysqld.exe>) { #/
for (<$bindir/sql/*/mysqld.exe>,
<$bindir/sql/*/mysqld>
) { #/
if (-M $_ < $modified)
{
$modified = -M _;
$opt_vs_config = basename(dirname($_));
$multiconfig = basename(dirname($_));
}
}
mtr_report("VS config: $opt_vs_config");
$opt_vs_config="/$opt_vs_config" if $opt_vs_config;
mtr_report("VS config: $multiconfig");
$multiconfig="/$multiconfig" if $multiconfig;
}
......@@ -2724,9 +2725,9 @@ sub vs_config_dirs ($$) {
# Don't look in these dirs when not on windows
return () unless IS_WINDOWS;
if ($opt_vs_config)
if ($multiconfig)
{
return ("$basedir/$path_part/$opt_vs_config/$exe");
return ("$basedir/$path_part/$multiconfig/$exe");
}
return ("$basedir/$path_part/release/$exe",
......
......@@ -39,7 +39,7 @@ sub start_test {
my $bin=$ENV{MTR_BINDIR} || '..';
return "Not run for embedded server" if $::opt_embedded_server;
return "Not configured to run ctest" unless -f "$bin/CTestTestfile.cmake";
my ($ctest_vs)= $::opt_vs_config ? "-C ".substr($::opt_vs_config,1) : "";
my ($ctest_vs)= $::multiconfig ? "-C ".substr($::multiconfig,1) : "";
my (@ctest_list)= `cd "$bin" && ctest $ctest_vs --show-only --verbose`;
return "No ctest" if $?;
......
......@@ -45,8 +45,8 @@ int main(int, char**)
!memcmp(&fts_info[i].buf, buf, len) &&
fts_decode_vlc(&fts_buf) == fts_info[i].val &&
fts_buf == &buf[len])
ok(true, "FTS Encoded for %d bytes", fts_info[i].len);
ok(true, "FTS Encoded for %zu bytes", fts_info[i].len);
else
ok(false, "FTS Encoded for %d bytes", fts_info[i].len);
ok(false, "FTS Encoded for %zu bytes", fts_info[i].len);
}
}
......@@ -15,7 +15,7 @@ use strict;
my $sst_dump=
::mtr_exe_maybe_exists(
"$::bindir/storage/rocksdb$::opt_vs_config/sst_dump",
"$::bindir/storage/rocksdb$::multiconfig/sst_dump",
"$::path_client_bindir/sst_dump");
return "RocksDB is not compiled, no sst_dump" unless $sst_dump;
$ENV{MARIAROCKS_SST_DUMP}="$sst_dump";
......
......@@ -13,7 +13,7 @@ use strict;
my $sst_dump=
::mtr_exe_maybe_exists(
"$::bindir/storage/rocksdb$::opt_vs_config/sst_dump",
"$::bindir/storage/rocksdb$::multiconfig/sst_dump",
"$::path_client_bindir/sst_dump");
return "RocksDB is not compiled, no sst_dump" unless $sst_dump;
$ENV{MARIAROCKS_SST_DUMP}="$sst_dump";
......
......@@ -15,7 +15,7 @@ use strict;
my $sst_dump=
::mtr_exe_maybe_exists(
"$::bindir/storage/rocksdb$::opt_vs_config/sst_dump",
"$::bindir/storage/rocksdb$::multiconfig/sst_dump",
"$::path_client_bindir/sst_dump");
return "RocksDB is not compiled, no sst_dump" unless $sst_dump;
$ENV{MARIAROCKS_SST_DUMP}="$sst_dump";
......
......@@ -12,7 +12,7 @@ use strict;
my $sst_dump=
::mtr_exe_maybe_exists(
"$::bindir/storage/rocksdb$::opt_vs_config/sst_dump",
"$::bindir/storage/rocksdb$::multiconfig/sst_dump",
"$::path_client_bindir/sst_dump");
return "RocksDB is not compiled, no sst_dump" unless $sst_dump;
$ENV{MARIAROCKS_SST_DUMP}="$sst_dump";
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment