Description:
If mysqld binary is built as mysqld-debug (i.e by. -DBUILD_CONFIG=mysql_release or -DDEBUG_EXTNAME=ON), main.check_basedir reports a not-really-correct testcase check error:
...
MTR's internal check of the test case 'main.check_basedir' failed.
...
This is the diff of the states of the servers before and after the
test case was executed:
...
@@ -68,10 +68,12 @@
run
std_data
tmp
+tmpniAbUx
#-------------- MYSQLTEST_VARDIR/run --------------
mysqld.1.pid
#-------------- MYSQLTEST_VARDIR/tmp --------------
mysqld.1
+server.out
#------------- MYSQLTEST_VARDIR/std_data ------------
.mylogin.cnf
14897.frm
First of all, this is misleading, this is not a testcase check error for a passing test, this is a test failure posing as a check error. tmp/server.out contains
sh: runtime_output_directory/mysqld: No such file or directory
which is the actual failure here, caused by test Perl snippets constructing relative paths to mysqld binary and assuming it is named "mysqld", while it is actually "mysqld-debug" under this CMake setup:
line 39: my $exe= File::Spec->catfile($relbindir, "mysqld");
line 64: my $syscmd= "mysqld $ENV{'HVARGS'}";
If --nocheck-testcases is given, the test is "skipped" with the following message, again not correct:
[100%] main.check_basedir [ skipped ] perl not found in path
The test passes if it is patched to use mysqld-debug.
How to repeat:
See above
Suggested fix:
Make test logic work with both mysqld and mysqld-debug