This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB 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: [RFC] Add expat to the GDB sources


> Date: Mon, 31 Jul 2006 16:24:22 -0400
> From: Daniel Jacobowitz <drow@false.org>
> 
> On Mon, Jul 31, 2006 at 01:33:12PM -0400, Daniel Jacobowitz wrote:
> > As for optional versus required, I don't think there's a relevant FSF
> > position.  However, I very much wanted to use the XML target
> > descriptions in some cases to replace the C-coded ones.  So obviously
> > I prefer to require expat.
> 
> Which yields this patch.
> 
> If our final decision is to make all features which require expat
> optional, I can rework this patch to only issue a warning message,
> and update the documentation accordingly.  It currently:
>   - Searches $prefix/lib and $prefix/include for expat, as well
>     as the standard system directories.
>   - Offers a documented option to find expat elsewhere.
>   - Defines HAVE_LIBEXPAT in config.h.
> 
> I think I've said everything useful that I can say on this subject;
> I am not sure how to proceed.  The options that I see are:
> 
>   1. Refuse to use external libraries.
>   2. Make external libraries optional.
>   3. Require external libraries, with moderation and documentation.
> 
> Obviously I prefer 3, followed by 2.
> 
> Your thoughts welcome!

It all depends on what the external library is used for.  Making
readline optional wouldn't make much sense, since it is used for GDB's
primary user interface.  Making expat optional make much more sense to
me, as I can't see why I'd need it for a native debugger.

There's another reason why I'd like to see expat as an optional
library.  Currently we (OpenBSD) ship GDB in our base system.  This
would mean we'd have to include expat in our base system too;
something we'd rather not do especially if it doesn't give us any
benefits.  NetBSD and FreeBSD are in a similar situation I guess.

That said, I'm willing to give in under two conditions:

1. We add the necessary glue to the toplevel configure such that it
   accepts a --with-expat-dir option similar to the --with-gmp-dir
   option that's already there for GCC.  This will make it possible to
   keep building everything in one tree, which would come close to
   removing the objections I raised earlier about problemms installing
   expat on systems I use to test GDB on.

2. Try to keep the bits that need expat "optional", and review whether
   the code that needs it really benefits all of us, or only a few.

Mark


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