diff options
Diffstat (limited to 'gcc/testsuite/gcc.misc-tests/gcov.exp')
-rw-r--r-- | gcc/testsuite/gcc.misc-tests/gcov.exp | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/gcc/testsuite/gcc.misc-tests/gcov.exp b/gcc/testsuite/gcc.misc-tests/gcov.exp index c8f20e1..4d427c8 100644 --- a/gcc/testsuite/gcc.misc-tests/gcov.exp +++ b/gcc/testsuite/gcc.misc-tests/gcov.exp @@ -21,12 +21,19 @@ load_lib gcc-dg.exp load_lib gcov.exp global GCC_UNDER_TEST +global GCOV_UNDER_TEST -# For now find gcov in the same directory as $GCC_UNDER_TEST. -if { ![is_remote host] && [string match "*/*" [lindex $GCC_UNDER_TEST 0]] } { - set GCOV [file dirname [lindex $GCC_UNDER_TEST 0]]/[gcc-transform-out-of-tree gcov] +# For now find gcov in the same directory as $GCC_UNDER_TEST, unless +# GCOV_UNDER_TEST is defined. + +if ![info exists GCOV_UNDER_TEST] { + if { ![is_remote host] && [string match "*/*" [lindex $GCC_UNDER_TEST 0]] } { + set GCOV [file dirname [lindex $GCC_UNDER_TEST 0]]/[gcc-transform-out-of-tree gcov] + } else { + set GCOV [gcc-transform-out-of-tree gcov] + } } else { - set GCOV [gcc-transform-out-of-tree gcov] + set GCOV $GCOV_UNDER_TEST } # Initialize harness. |