This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: Patch for readelf testsuite
- To: "H . J . Lu" <hjl at lucon dot org>
- Subject: Re: Patch for readelf testsuite
- From: Alan Modra <alan at linuxcare dot com dot au>
- Date: Sat, 31 Mar 2001 09:32:59 +1000 (EST)
- cc: binutils at sources dot redhat dot com
On Fri, 30 Mar 2001, H . J . Lu wrote:
> --- binutils-all/readelf.exp 2001/03/15 22:51:57 1.1.1.5
> +++ binutils-all/readelf.exp 2001/03/30 19:23:18
> @@ -218,11 +218,24 @@ proc readelf_test { options binary_file
> # For now be paranoid and assume that if ELF is not mentioned
> # in the target string, then the target is not an ELF based port.
>
> -if ![istarget "*-*elf"] then {
> +if { ![istarget *-*-elf*] \
> + && ![istarget *-*-linux*] \
> + && ![istarget i?86-*-sysv4*] \
> + && ![istarget i?86-*-unixware] \
> + && ![istarget mips*-*-irix5*] \
> + && ![istarget mips*-*-irix6*] \
> + && ![istarget powerpc-*-sysv4*] \
> + && ![istarget sparc*-*-solaris2*] } {
> verbose "$READELF is only intended for ELF targets" 2
> return
> }
>
> +if { [istarget *-*-linuxoldld*] \
> + || [istarget *-*-linuxaout*] } {
> + verbose "$READELF is only intended for ELF targets" 2
> + return
> +}
Thanks HJ. Something like the above really ought to be put some place in
a function where it can be used by other tests (gas and ld too). There
are quite a few places where we want a "is this target elf?" test, and it
would be nice to have just one place to update for odd targets. Hmm,
better yet, why not assemble a tiny file and look for the magic
"ELF" string in the object. Are there any dejagnu experts out there
reading this list? With a little spare time???
Alan
--
Linuxcare