forked from Imagelibrary/binutils-gdb
* peXXigen.c (pe_print_resource_entries): New function: Displays
an entry in a .rsrc section. (pe_print_resource_directory): New function: Displays a directory in a .rsrc section. (pe_print_rsrc): New function: Displays the contents of .rsrc section. (_bfd_XX_print_private_bfd_data_common): Call pe_print_rsrc. * binutils-all/windres/windres.exp: Run for x86_64-pc-cygwin. Add test of "objump -p" output.
This commit is contained in:
@@ -1,3 +1,8 @@
|
||||
2013-12-03 Nick Clifton <nickc@redhat.com>
|
||||
|
||||
* binutils-all/windres/windres.exp: Run for x86_64-pc-cygwin.
|
||||
Add test of "objump -p" output.
|
||||
|
||||
2013-11-27 Matthew Fortune <matthew.fortune@imgtec.com>
|
||||
|
||||
* binutils-all/objcopy.exp: Consider mips-mti-elf the same as
|
||||
|
||||
@@ -19,15 +19,18 @@
|
||||
|
||||
# Written by DJ Delorie <dj@redhat.com>
|
||||
|
||||
if {![istarget "i*86-*-*"] && ![istarget "x86_64-*-mingw*"] } {
|
||||
if {![istarget "i*86-*-*"] && ![istarget "x86_64-*-mingw*"] && ![istarget "x86_64-*-cygwin"] } {
|
||||
verbose "Not a Cygwin/Mingw target" 1
|
||||
return
|
||||
}
|
||||
|
||||
if {![info exists WINDRES]} then {
|
||||
verbose "WINDRES not defined" 1
|
||||
return
|
||||
}
|
||||
|
||||
if {[which $WINDRES] == 0} then {
|
||||
verbose "$WINDRES not found" 1
|
||||
return
|
||||
}
|
||||
|
||||
@@ -139,3 +142,37 @@ foreach res $res_list {
|
||||
file delete "tmpdir/$broot.dump"
|
||||
}
|
||||
}
|
||||
|
||||
# Test objdump -p
|
||||
|
||||
if {[which $OBJDUMP] == 0} then {
|
||||
unsupported "objdump -p"
|
||||
return
|
||||
}
|
||||
|
||||
verbose "$wr $cpp_opts -J rc $srcdir/$subdir/version.rc tmpdir/version.o" 1
|
||||
catch "exec $wr $cpp_opts -J rc $srcdir/$subdir/version.rc tmpdir/version.o" err
|
||||
|
||||
if ![string match "" $err] then {
|
||||
send_log "$err\n"
|
||||
verbose "$err" 1
|
||||
if [string match "*windows.h: No such file*" $err] then {
|
||||
unsupported "objdump -p (no header files found)"
|
||||
} else {
|
||||
fail "objdump -p (build)"
|
||||
}
|
||||
continue
|
||||
}
|
||||
|
||||
set got [binutils_run $OBJDUMP "$OBJDUMPFLAGS -p tmpdir/version.o"]
|
||||
|
||||
# FIXME: We should extend this regexp to check for more information.
|
||||
set want ".*The .rsrc Resource Directory section.*Type Table:.*Entry: ID:.*Name Table:.*Entry: ID:.*Language Table:.*Entry: ID:.*"
|
||||
|
||||
if ![regexp $want $got] then {
|
||||
fail "objdump -p"
|
||||
} else {
|
||||
pass "objdump -p"
|
||||
}
|
||||
|
||||
# file delete "tmpdir/version.o"
|
||||
|
||||
Reference in New Issue
Block a user