[llvm-dev] Clang includes search path
don hinton via llvm-dev
llvm-dev at lists.llvm.org
Mon Oct 12 09:00:54 PDT 2015
I think the libc++ folks recommend building libc++ along with clang. If
you do that, the c++ includes files will get copied under the relative
include path and will be found automatically. However, you'll need to set
DYLD_LIBRARY_PATH in order to pick up the correct, just built, libc++
But if you really do want to use the installed version of libc++, you can
use xcrun to dynamically find the path via xcrun and set CPLUS_INCLUDE_PATH.
$ export CPLUS_INCLUDE_PATH=$(dirname $(xcrun -f clang))/../include/c++/v1
On Mon, Oct 12, 2015 at 10:13 AM, Rinaldini Julien via llvm-dev <
llvm-dev at lists.llvm.org> wrote:
> I’m trying to set the includes search path in clang, but I can’t figure
> out how to do it?
> I’m working on OSX and every time I compile a C/C++ code, I have to
> specify it with -isysroot (and I don’t want an alias, or a symlink to
> /usr/include) since the includes are not in a really standard path on OSX
> Is there a way to do that?
> LLVM Developers mailing list
> llvm-dev at lists.llvm.org
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the llvm-dev