<div dir="ltr"><div class="gmail_quote"><div dir="ltr">On Fri, Feb 26, 2016 at 11:46 AM Jacob Carlborg via cfe-dev <<a href="mailto:cfe-dev@lists.llvm.org">cfe-dev@lists.llvm.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">On 2016-02-26 10:37, Pedro Delgado Perez via cfe-dev wrote:<br>
> Hello,<br>
><br>
> Perhaps this question has been asked before, but I couldn't find a<br>
> proper solution for this issue. When I produce an executable and use it<br>
> in another machine, sometimes Clang is not able to find system header<br>
> files (for instance "limits.h") because the paths to find these headers<br>
> are relative to the location of the Clang libraries.<br>
><br>
> All the same, when I'm using FIXED COMPILATION, I'm able to<br>
> automatically retrieve the paths to system headers of the machine where<br>
> the executable is being run. I mean, I retrieve the paths and add them<br>
> after "--" to the command through the option -isystem. However, when I'm<br>
> using JSON COMPILATION DATABASE, I can't do that, so in this case I<br>
> don't know how to solve this issue.<br>
><br>
> What is the appropriate manner to handle this matter of the paths to<br>
> system header files?<br>
<br>
Not sure if ti's the most appropriate way of doing it but I'm embedding<br>
the internal Clang headers in my executable. This post [1] [2].<br>
<br>
[1]<br>
<a href="http://clang-developers.42468.n3.nabble.com/Builtin-headers-td4049705.html#message4049716" rel="noreferrer" target="_blank">http://clang-developers.42468.n3.nabble.com/Builtin-headers-td4049705.html#message4049716</a><br>
<br>
[2]<br>
<a href="http://clang-developers.42468.n3.nabble.com/Builtin-headers-td4049705.html#message4049772" rel="noreferrer" target="_blank">http://clang-developers.42468.n3.nabble.com/Builtin-headers-td4049705.html#message4049772</a><br>
<br>
--<br>
/Jacob Carlborg<br>
<br>
_______________________________________________<br>
cfe-dev mailing list<br>
<a href="mailto:cfe-dev@lists.llvm.org" target="_blank">cfe-dev@lists.llvm.org</a><br>
<a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev</a><br>
</blockquote></div></div>