diff options
Diffstat (limited to 'mysql-test/mysql-test-run.pl')
-rwxr-xr-x | mysql-test/mysql-test-run.pl | 32 |
1 files changed, 20 insertions, 12 deletions
diff --git a/mysql-test/mysql-test-run.pl b/mysql-test/mysql-test-run.pl index a73d97c072b..f16f9d00f5f 100755 --- a/mysql-test/mysql-test-run.pl +++ b/mysql-test/mysql-test-run.pl @@ -419,7 +419,8 @@ sub initial_setup () { { # Windows programs like 'mysqld' needs Windows paths $glob_mysql_test_dir= `cygpath -m $glob_mysql_test_dir`; - $glob_cygwin_shell= `cygpath -w $ENV{'SHELL'}`; # The Windows path c:\... + my $shell= $ENV{'SHELL'} || "/bin/bash"; + $glob_cygwin_shell= `cygpath -w $shell`; # The Windows path c:\... chomp($glob_mysql_test_dir); chomp($glob_cygwin_shell); } @@ -791,13 +792,15 @@ sub executable_setup () { my $path_examples= "$glob_basedir/libmysqld/examples"; $exe_mysqltest= mtr_exe_exists("$path_examples/mysqltest"); $exe_mysql_client_test= - mtr_exe_exists("$path_examples/mysql_client_test_embedded"); + mtr_exe_exists("$path_examples/mysql_client_test_embedded", + "/usr/bin/false"); } else { $exe_mysqltest= mtr_exe_exists("$path_client_bindir/mysqltest"); $exe_mysql_client_test= - mtr_exe_exists("$glob_basedir/tests/mysql_client_test"); + mtr_exe_exists("$glob_basedir/tests/mysql_client_test", + "/usr/bin/false"); } $exe_mysqldump= mtr_exe_exists("$path_client_bindir/mysqldump"); $exe_mysqlshow= mtr_exe_exists("$path_client_bindir/mysqlshow"); @@ -819,7 +822,8 @@ sub executable_setup () { $exe_mysqladmin= mtr_exe_exists("$path_client_bindir/mysqladmin"); $exe_mysql= mtr_exe_exists("$path_client_bindir/mysql"); $exe_mysql_fix_system_tables= - mtr_script_exists("$path_client_bindir/mysql_fix_privilege_tables"); + mtr_script_exists("$path_client_bindir/mysql_fix_privilege_tables", + "$glob_basedir/scripts/mysql_fix_privilege_tables"); $path_language= mtr_path_exists("$glob_basedir/share/mysql/english/", "$glob_basedir/share/english/"); @@ -833,13 +837,15 @@ sub executable_setup () { $exe_mysqltest= mtr_exe_exists("$path_client_bindir/mysqltest_embedded"); $exe_mysql_client_test= mtr_exe_exists("$glob_basedir/tests/mysql_client_test_embedded", - "$path_client_bindir/mysql_client_test_embedded"); + "$path_client_bindir/mysql_client_test_embedded", + "/usr/bin/false"); } else { $exe_mysqltest= mtr_exe_exists("$path_client_bindir/mysqltest"); $exe_mysql_client_test= - mtr_exe_exists("$path_client_bindir/mysql_client_test"); + mtr_exe_exists("$path_client_bindir/mysql_client_test", + "/usr/bin/false"); # FIXME temporary } $path_ndb_tools_dir= "$glob_basedir/bin"; @@ -1548,7 +1554,7 @@ sub do_before_start_master ($$) { $tname ne "rpl_crash_binlog_ib_3b") { # FIXME we really want separate dir for binlogs - foreach my $bin ( glob("$opt_vardir/log/master*-bin.*") ) + foreach my $bin ( glob("$opt_vardir/log/master*-bin*") ) { unlink($bin); } @@ -1586,13 +1592,13 @@ sub do_before_start_slave ($$) { $tname ne "rpl_crash_binlog_ib_3b" ) { # FIXME we really want separate dir for binlogs - foreach my $bin ( glob("$opt_vardir/log/slave*-bin.*") ) + foreach my $bin ( glob("$opt_vardir/log/slave*-bin*") ) { unlink($bin); } # FIXME really master?! - unlink("$opt_vardir/slave-data/master.info"); - unlink("$opt_vardir/slave-data/relay-log.info"); + unlink("$slave->[0]->{'path_myddir'}/master.info"); + unlink("$slave->[0]->{'path_myddir'}/relay-log.info"); } # Run slave initialization shell script if one exists @@ -1606,8 +1612,10 @@ sub do_before_start_slave ($$) { } } - `rm -f $opt_vardir/slave-data/log.*`; -# unlink("$opt_vardir/slave-data/log.*"); + foreach my $bin ( glob("$slave->[0]->{'path_myddir'}/log.*") ) + { + unlink($bin); + } } sub mysqld_arguments ($$$$$) { |