[cfe-dev] controlling the value of DW_AT_comp_dir

Devang Patel dpatel at apple.com
Thu Oct 20 18:08:47 PDT 2011




On Oct 20, 2011, at 5:25 PM, Chandler Carruth <chandlerc at google.com> wrote:

> On Thu, Oct 20, 2011 at 5:03 PM, Devang Patel <dpatel at apple.com> wrote:
> 
> On Oct 20, 2011, at 4:14 PM, Nick Lewycky wrote:
> 
>> On 20 October 2011 16:00, Devang Patel <dpatel at apple.com> wrote:
>> What about following approach... 
>> 
>> I don't like it because we've been nearly successful avoiding things which would diverge a Google-build of clang from an open-source build of clang. Is there no way we can get this functionality without an ifdef? Is there a reason you don't like adding a flag?
> 
> Essentially, what you're looking  for to say is, "on this platform use pwd". Have you considered an alternative to use configure check to enable use of PWD ?
> 
> I want you to exhaust all alternatives before deciding to add a command line flag. Adding a command line flag is usually easy way out, but removing an command line flag is almost impossible. 
> 
> But hold on, the latest proposal has no such flag. We have an *internal* flag for the CC1 layer merely to factor the logic that deals with platforms and shells and other such oddities into the driver. Users will never see or use this flag.
> 
> Also, PWD is a useful thing to base the working directory on for many platforms. Mac, Linux, BSD, etc. I think Nick's latest patch is very clean and minimal. The Frontend has a clear narrow and explicit interface with no system knowledge (it uses a flag, but an internal one). The Driver automatically sets that flag appropriately based on the user's system, no flags or other changes necessary.

Ok, fine with me!
-
Devang
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20111020/8e3bf20c/attachment.html>


More information about the cfe-dev mailing list