summaryrefslogtreecommitdiff
path: root/mysql-test/mysql-test-run.pl
diff options
context:
space:
mode:
authorAnel Husakovic <anel@mariadb.org>2020-10-05 23:39:07 +0200
committerAnel Husakovic <anel@mariadb.org>2020-10-06 00:00:58 +0200
commit8c34a242aa2d4e8e894fa7b2e07e02021a7df9d2 (patch)
treeb509142e20d87abf6abed38c1455711dc6d662d2 /mysql-test/mysql-test-run.pl
parent01ffccd6a4ec2af645b81bcfef8a02f031a492e5 (diff)
downloadmariadb-git-bb-10.2-MDEV-20787.tar.gz
MDEV-20787: Script dgcov.pl does not workbb-10.2-MDEV-20787
- This patch is done after doing test on 00f9df29224ada9cdbb796c99f4 where difference was found between versions of gcov. - This patch doesn't take gcov versions in account since is extracting filename of a `.gcov` file, which is generated with `gcov -i <source-file>.gcda` during `dgcov.pl --generate`. - There is a check if file exists. Reason for that is because some generated `gcov` files are outliers from above rule (that a file generated in intermediate format(gcov) has the same source name). Example 1: `aestables.cpp.gcda` is not generating `aestables.cpp.gcov`, but only the files used in #include `modes.hpp.gcov runtime.hpp.gcov` Example 2: `my_sha256.cc.gcda` is generating `my_sha.ic.gcov` - Make sure to test `MTR_BINDIR` which gets set during out-of-source build and generate error when running `./mysql-test/mtr --gcov alias` - During the testing: 10.1 results are stored in - `<basedir>//mysql-test-gcov.msg` and errors in - `<basedir>//mysql-test-gcov.err` 10.2 results should be stored in `./mysql-test/var/last_changes.dgcov`, but only empty results are obtained (tests `1st` and `alias`).
Diffstat (limited to 'mysql-test/mysql-test-run.pl')
-rwxr-xr-xmysql-test/mysql-test-run.pl2
1 files changed, 1 insertions, 1 deletions
diff --git a/mysql-test/mysql-test-run.pl b/mysql-test/mysql-test-run.pl
index 178d65aca41..be51a79e0be 100755
--- a/mysql-test/mysql-test-run.pl
+++ b/mysql-test/mysql-test-run.pl
@@ -1791,7 +1791,7 @@ sub command_line_setup {
# --------------------------------------------------------------------------
# Gcov flag
# --------------------------------------------------------------------------
- if ( ($opt_gcov or $opt_gprof) and ! $source_dist )
+ if ( ($opt_gcov or $opt_gprof) and (! $source_dist or -d $ENV{MTR_BINDIR}))
{
mtr_error("Coverage test needs the source - please use source dist");
}