This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: bfd patch for gdb cross-debugging support


On Mon, 2009-09-14 at 09:08 -0700, Ian Lance Taylor wrote:
> Danny Backx <danny.backx@scarlet.be> writes:
> > If I do this, is the consequence also that I replace all occurrences of
> > HAVE_DOS_BASED_FILE_SYSTEM by uses of this new function, or should I go
> > for a minimalistic change ?
> 
> Think bigger: instead of having a function which returns whether or not
> you are on a DOS based file system, find the cases which test that and
> write functions which implement the functionality that they need.  Have
> those functions test your new global variable.  You already need to
> change that code anyhow.
> 
> To be clear, I am not making requirements for this commit.  That is up
> to Nick.  I'm saying what I think is the right thing to do here for
> long-term maintainability and ease of use.
> 
> Aside from API issues, I will note that using a global variable is not
> an ideal choice when BFD is compiled as a shared library.

You're implying that I extend some existing data structure with a field.
Is this structure the "struct bfd" ?

And as a consequence, the functions I create for working with this will
have this (a pointer to a bfd) as a parameter. Right ?

Then this'll work its way up in e.g. IS_DIR_SEPARATOR, and
(bfd/archive.c) adjust_relative_path which doesn't have a bfd.

I suspect that this may go on for a while.

If anyone can confirm that this is the intention, then I can try to look
up how far this leads us...

	Danny
-- 
Danny Backx ; danny.backx - at - scarlet.be ; http://danny.backx.info


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]