[binutils-gdb] objcopy binary symbol type check
Alan Modra
amodra@sourceware.org
Fri Nov 14 01:25:50 GMT 2025
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=35e1c33162bf61a6d2e2da1128e8a841bd829e84
commit 35e1c33162bf61a6d2e2da1128e8a841bd829e84
Author: Alan Modra <amodra@gmail.com>
Date: Fri Nov 14 11:50:59 2025 +1030
objcopy binary symbol type check
This exposes an error on alpha-linux-gnuecoff where the start and end
syms are given the wrong storage class.
* testsuite/binutils-all/objcopy.exp (binary_symbol): Tighten
symbol type checking.
Diff:
---
binutils/testsuite/binutils-all/objcopy.exp | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/binutils/testsuite/binutils-all/objcopy.exp b/binutils/testsuite/binutils-all/objcopy.exp
index 43814ac5a70..5f1f7c6b49e 100644
--- a/binutils/testsuite/binutils-all/objcopy.exp
+++ b/binutils/testsuite/binutils-all/objcopy.exp
@@ -1631,8 +1631,11 @@ proc binary_symbol {name file args sym_prefix} {
return
}
- foreach sym [list "start" "end" "size"] {
- set exp "^\[0-9a-fA-F\]+ +\[TtDdA\] +${sym_prefix}_${sym}$"
+ set syms [list {D start} {D end} {A size}]
+ foreach e $syms {
+ set typ [lindex $e 0]
+ set sym [lindex $e 1]
+ set exp "^\[0-9a-fA-F\]+ +${typ} +${sym_prefix}_${sym}$"
if ![regexp -line $exp $got] {
send_log "failed to match: $exp\n"
fail $test
More information about the Binutils-cvs
mailing list