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: Fix in-src-tree builds by making gdbserver/gnulib/ a separate library (a la libiberty, etc.), and adding ACX_CONFIGURE_DIR.


On 04/18/2012 01:32 PM, Jan Kratochvil wrote:

> On Wed, 18 Apr 2012 12:17:02 +0200, Pedro Alves wrote:
>> GNULIB_CFLAGS=-I$(srcdir)/gnulib/import -I$(GNULIB_BUILDDIR)/import
>>
>> isn't that confusing.  $(GNULIB_BUILDDIR)/import is the build of
>> the gnulib import.
>>
>> Would that make everybody happy?
> 
> IIUC there are still two directories containing different kinds of files while
> having the same basename.


I'm not sure what you mean.  The proposal is to move:

Move src/gdb/gnulib -> src/gdb/gnulib/import/

Then src/gdb/gnulib/ gains new autoconf/makefile glue.

When building src/gdb/gnulib/, the build descends into
gnulib/import/, and builds that, just like when building
src/, we descend into src/gdb/ -> build/gdb , and then descent
into src/gdb/gdbserver/ -> build/gdb/gdbserver/ .

gnulib generates headers when it is built.  We need to point
the compiler at both the gnulib sources, and to those generated
headers.  Hence,

GNULIB_CFLAGS=-I$(srcdir)/gnulib/import -I$(GNULIB_BUILDDIR)/import

The first -I is the gnulib imported sources, the second -I is the
built gnulib, which contains the generated headers.

This is no different from src/gdb/ vs build/gdb.

Does that clear things up?

-- 
Pedro Alves


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