Libitm C++ tests pass -B/full/path/to/build/libstc++/src/.libs on the
options argument to dg-runtest and the libstdc++ include paths as
the default-extra-options. This causes 2 problems:
1) If a test uses `dg-options' then the libstdc++ include paths are
not passed to the compiler.
2) The `-B/full/path/to/build/libstc++/src/.libs' gets added to the
test name. This makes comparing build done in different directories
harder because the hardcoded full path.
This patch moves both options to additional_flags to fix both issues.
libitm/ChangeLog:
PR libitm/69018
* testsuite/libitm.c++/c++.exp: Move $stdcxxadder and
$libstdcxx_includes to additional_flags.
Signed-off-by: Pietro Monteiro <[email protected]>
---
libitm/testsuite/libitm.c++/c++.exp | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/libitm/testsuite/libitm.c++/c++.exp
b/libitm/testsuite/libitm.c++/c++.exp
index a1ce7ce4062..fe5a9411070 100644
--- a/libitm/testsuite/libitm.c++/c++.exp
+++ b/libitm/testsuite/libitm.c++/c++.exp
@@ -73,8 +73,11 @@ if { $lang_test_file_found } {
set libstdcxx_includes ""
}
+ lappend ALWAYS_CFLAGS "additional_flags=$stdcxxadder"
+ lappend ALWAYS_CFLAGS "additional_flags=$libstdcxx_includes"
+
# Main loop.
- dg-runtest $tests $stdcxxadder $libstdcxx_includes
+ dg-runtest $tests "" ""
}
# All done.
--
2.52.0