Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: Jim Blandy <jimb@redhat.com>
To: Roland McGrath <roland@redhat.com>
Cc: Randolph Chung <randolph@tausq.org>,
	Joel Brobecker <brobecker@gnat.com>,
	gdb@sources.redhat.com
Subject: Re: add-symbol-file-from-memory patch breaks non-elf targets?
Date: Thu, 22 Apr 2004 13:30:00 -0000	[thread overview]
Message-ID: <vt265bs30cs.fsf@zenia.home> (raw)
In-Reply-To: <200404210709.i3L795Cx002971@magilla.sf.frob.com>


Roland McGrath <roland@redhat.com> writes:
> In gdb, I could not find, and still cannot find, a reasonable way to
> conditionalize something at compile time on "will there be ELF".  Hence the
> runtime check for bfd_target_elf_flavour, and the unconditional link-time
> reference to bfd_elf_bfd_from_remote_memory.  AFAICT, elfread.c is always
> built into gdb even for non-ELF targets, as a further example telling me
> there really is no good way to conditionalize this correctly.  It happens
> not to use any bfd_elf_* interfaces and so links ok and is just dead code
> in ELFless configurations.  
> 
> I am open to suggestions.

I remember this coming up now; I wish I had remembered it before I
approved the patch.

I messed around with it, and I couldn't find a good place either.  How
about creating a new file, elf-tdep.c, putting the code there, and
having linux.mt add elf-tdep.o to the link?


  parent reply	other threads:[~2004-04-22  8:07 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-04-21  7:09 Randolph Chung
2004-04-21 10:37 ` Roland McGrath
2004-04-21 16:06   ` Randolph Chung
2004-04-21 18:42     ` Roland McGrath
2004-04-22  1:09     ` Andrew Cagney
2004-04-22  7:33       ` Joel Brobecker
2004-04-22 13:30   ` Jim Blandy [this message]
2004-04-22 14:57     ` Andrew Cagney
2004-04-23  4:19 ` Jim Blandy
2004-04-23  4:35   ` Roland McGrath
2004-04-23 10:05     ` Jim Blandy
2004-05-07 20:38       ` Andrew Cagney
2004-04-23 22:15   ` Joel Brobecker

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=vt265bs30cs.fsf@zenia.home \
    --to=jimb@redhat.com \
    --cc=brobecker@gnat.com \
    --cc=gdb@sources.redhat.com \
    --cc=randolph@tausq.org \
    --cc=roland@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox