mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-07-01 18:32:32 +08:00
Properly check linker warnings
* lib/ld-lib.exp (run_cc_link_tests): Properly check linker warnings.
This commit is contained in:
@ -1,3 +1,8 @@
|
|||||||
|
2012-12-07 H.J. Lu <hongjiu.lu@intel.com>
|
||||||
|
|
||||||
|
* lib/ld-lib.exp (run_cc_link_tests): Properly check linker
|
||||||
|
warnings.
|
||||||
|
|
||||||
2012-12-07 H.J. Lu <hongjiu.lu@intel.com>
|
2012-12-07 H.J. Lu <hongjiu.lu@intel.com>
|
||||||
|
|
||||||
* lib/ld-lib.exp (ar_simple_create): Pass -rc to ar.
|
* lib/ld-lib.exp (ar_simple_create): Pass -rc to ar.
|
||||||
|
@ -1407,21 +1407,26 @@ proc run_cc_link_tests { ldtests } {
|
|||||||
} else {
|
} else {
|
||||||
set failed 0
|
set failed 0
|
||||||
}
|
}
|
||||||
} elseif { ![ld_simple_link $cc_cmd $binfile "-L$srcdir/$subdir $ldflags $objfiles"] } {
|
} else {
|
||||||
|
if { ![ld_simple_link $cc_cmd $binfile "-L$srcdir/$subdir $ldflags $objfiles"] } {
|
||||||
|
set failed 1
|
||||||
|
} else {
|
||||||
|
set failed 0
|
||||||
|
}
|
||||||
|
|
||||||
# Check if exec_output is expected.
|
# Check if exec_output is expected.
|
||||||
if { $warnings != "" } then {
|
if { $warnings != "" } then {
|
||||||
verbose -log "returned with: <$exec_output>, expected: <$warnings>"
|
verbose -log "returned with: <$exec_output>, expected: <$warnings>"
|
||||||
if { [regexp $warnings $exec_output] } then {
|
if { [regexp $warnings $exec_output] } then {
|
||||||
set failed 0
|
set failed 2
|
||||||
} else {
|
} else {
|
||||||
set failed 1
|
set failed 1
|
||||||
}
|
}
|
||||||
} else {
|
}
|
||||||
|
|
||||||
|
if { $failed == 1 } {
|
||||||
fail $testname
|
fail $testname
|
||||||
set failed 1
|
|
||||||
}
|
}
|
||||||
} else {
|
|
||||||
set failed 0
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if { $failed == 0 } {
|
if { $failed == 0 } {
|
||||||
|
Reference in New Issue
Block a user