aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorIain Sandoe <iain@sandoe.co.uk>2025-03-31 13:54:37 +0100
committerIain Sandoe <iain@sandoe.co.uk>2025-04-06 10:29:49 +0100
commit24f79780148613ea8539209c30ec6e102b007ee6 (patch)
treee01f607d08467d0cd9d26b961ffdb88efae3b53b /gcc
parent54932496a8b36a3991f7e533cc3a47ae41148b3e (diff)
downloadgcc-24f79780148613ea8539209c30ec6e102b007ee6.zip
gcc-24f79780148613ea8539209c30ec6e102b007ee6.tar.gz
gcc-24f79780148613ea8539209c30ec6e102b007ee6.tar.bz2
testsuite, cobol: Avoid adding duplicate libs.
The discovered paths already include the multilib and so there is no need to add an extra library to COBOL_UNDER_TEST. Doing so makes a duplicate, which causes test fails on Darwin, where the linker warns when duplicate libraries are provided on the link line. gcc/testsuite/ChangeLog: * lib/cobol.exp: Simplify the setting of COBOL_UNDER_TEST. Signed-off-by: Iain Sandoe <iain@sandoe.co.uk>
Diffstat (limited to 'gcc')
-rw-r--r--gcc/testsuite/lib/cobol.exp15
1 files changed, 2 insertions, 13 deletions
diff --git a/gcc/testsuite/lib/cobol.exp b/gcc/testsuite/lib/cobol.exp
index a0eeb4e..8ea91e3 100644
--- a/gcc/testsuite/lib/cobol.exp
+++ b/gcc/testsuite/lib/cobol.exp
@@ -163,7 +163,6 @@ proc cobol_init { args } {
global gcc_warning_prefix
global gcc_error_prefix
global TEST_ALWAYS_FLAGS
- global cobol_init_set_COBOL_UNDER_TEST
# We set LC_ALL and LANG to C so that we get the same error messages as expected.
setenv LC_ALL C
@@ -179,24 +178,14 @@ proc cobol_init { args } {
setenv LANG C.ASCII
}
- # COBOL_UNDER_TEST as set below contains $specpath, which depends on
- # the used multilib config. Thus, its value may need to be reset;
- # that's tracked via gfortran_init_set_COBOL_UNDER_TEST.
- if { ![info exists COBOL_UNDER_TEST]
- || [info exists cobol_init_set_COBOL_UNDER_TEST] } then {
+ if ![info exists COBOL_UNDER_TEST] then {
if [info exists TOOL_EXECUTABLE] {
set COBOL_UNDER_TEST $TOOL_EXECUTABLE
} else {
if { [is_remote host] || ! [info exists TESTING_IN_BUILD_TREE] } {
set COBOL_UNDER_TEST [transform gcobol]
} else {
- if [info exists TOOL_OPTIONS] {
- set specpath [get_multilibs ${TOOL_OPTIONS}]
- } else {
- set specpath [get_multilibs]
- }
- set cobol_init_set_COBOL_UNDER_TEST 1
- set COBOL_UNDER_TEST [findfile $base_dir/../../gcobol "$base_dir/../../gcobol -B$base_dir/../../ -B$specpath/libgcobol/.libs" [findfile $base_dir/gcobol "$base_dir/gcobol -B$base_dir/" [transform gcobol]]]
+ set COBOL_UNDER_TEST [findfile $base_dir/../../gcobol "$base_dir/../../gcobol -B$base_dir/../../" [findfile $base_dir/gcobol "$base_dir/gcobol -B$base_dir/" [transform gcobol]]]
}
}
}