This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] add -foverride-comp-dir
- From: Geoffrey Keating <geoffk at apple dot com>
- To: Dan Aloni <da-x at monatomic dot org>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: 27 Sep 2006 00:25:32 -0700
- Subject: Re: [PATCH] add -foverride-comp-dir
- References: <20060926135209.GA3599@localdomain>
Dan Aloni <da-x@monatomic.org> writes:
> Hello,
>
> The following patch adds a new switch to gcc that allows to override
> the DW_AT_comp_dir DWARF2 attribute. The reason why I need this change
> is that one of our project's build system is using content-hashing in
> order to save build and compilation time among several developers that
> are working on that project.
>
> When debug information is used, we need to make sure that that the
> result binaries are identical if compiled from the same source between
> several developers working from different directories, and also to be
> able to look at core files from gdb with proper (i.e. path-relative)
> source code lookup. By simply passing -foverride-comp-dir=. to gcc
> after this feature is patched in, we are able to achieve our goals.
Would it be better to simply have a -fno-comp-dir flag, to omit this
information entirely from the DWARF output?