[cfe-dev] Getting clang header search path

Craig Tenenbaum zarathustra.zoroaster at gmail.com
Fri Aug 15 07:23:11 PDT 2014


On Fri, Aug 15, 2014 at 9:28 AM, Edward Diener <
eldlistmailingz at tropicsoft.com> wrote:

> Here is my output:
>
>  C:\Programming\VersionControl\bninja_installed_clang\bin>clang++ -E -v
>> -### -x c
>> ++ NUL
>>
>> clang version 3.6.0 (215674)
>> Target: i686-pc-windows-gnu
>> Thread model: posix
>>  "C:\\Programming\\VersionControl\\bninja_installed_clang\\bin\\clang++.exe"
>> "-c
>> c1" "-triple" "i686-pc-windows-gnu" "-E" "-disable-free"
>> "-disable-llvm-verifier
>> " "-main-file-name" "NUL" "-mrelocation-model" "static"
>> "-mdisable-fp-elim" "-fm
>> ath-errno" "-masm-verbose" "-mconstructor-aliases" "-target-cpu"
>> "pentium4" "-v"
>>  "-dwarf-column-info" "-resource-dir" "C:\\Programming\\
>> VersionControl\\bninja_i
>> nstalled_clang\\bin\\..\\lib\\clang\\3.6.0" "-fdeprecated-macro"
>> "-fdebug-compil
>> ation-dir" "C:\\Programming\\VersionControl\\bninja_installed_clang\\bin"
>> "-ferr
>> or-limit" "19" "-fmessage-length" "80" "-mstackrealign"
>> "-fno-use-cxa-atexit" "-
>> fobjc-runtime=gcc" "-fcxx-exceptions" "-fexceptions"
>> "-fdiagnostics-show-option"
>>  "-fcolor-diagnostics" "-o" "-" "-x" "c++" "NUL"
>>
>
> I do not see header path information anywhere.

Sorry, my bad, try: clang++ -E -v -x c++ NUL

My output (except that I obviously used /dev/null):

> clang version 3.6.0 (04f9ed5f8cf30195a85743d43e56d06f62b87ce2)
> (99cd10fe111560b9921e731a89109972a149dfab)
> Target: x86_64-pc-linux-gnu
> Thread model: posix
> Found candidate GCC installation:
> /usr/bin/../lib/gcc/x86_64-pc-linux-gnu/4.1.2
> Found candidate GCC installation:
> /usr/bin/../lib/gcc/x86_64-pc-linux-gnu/4.6.3
> Found candidate GCC installation:
> /usr/bin/../lib/gcc/x86_64-pc-linux-gnu/4.7.3
> Found candidate GCC installation:
> /usr/bin/../lib/gcc/x86_64-pc-linux-gnu/4.8.2
> Found candidate GCC installation:
> /usr/bin/../lib/gcc/x86_64-pc-linux-gnu/4.9.1
> Found candidate GCC installation:
> /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/4.1.2
> Found candidate GCC installation:
> /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/4.6.3
> Found candidate GCC installation:
> /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/4.7.3
> Found candidate GCC installation:
> /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/4.8.2
> Found candidate GCC installation:
> /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/4.9.1
> Found candidate GCC installation: /usr/lib/gcc/x86_64-pc-linux-gnu/4.1.2
> Found candidate GCC installation: /usr/lib/gcc/x86_64-pc-linux-gnu/4.6.3
> Found candidate GCC installation: /usr/lib/gcc/x86_64-pc-linux-gnu/4.7.3
> Found candidate GCC installation: /usr/lib/gcc/x86_64-pc-linux-gnu/4.8.2
> Found candidate GCC installation: /usr/lib/gcc/x86_64-pc-linux-gnu/4.9.1
> Found candidate GCC installation: /usr/lib64/gcc/x86_64-pc-linux-gnu/4.1.2
> Found candidate GCC installation: /usr/lib64/gcc/x86_64-pc-linux-gnu/4.6.3
> Found candidate GCC installation: /usr/lib64/gcc/x86_64-pc-linux-gnu/4.7.3
> Found candidate GCC installation: /usr/lib64/gcc/x86_64-pc-linux-gnu/4.8.2
> Found candidate GCC installation: /usr/lib64/gcc/x86_64-pc-linux-gnu/4.9.1
> Selected GCC installation: /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/4.9.1
> Candidate multilib: .;@m64
> Candidate multilib: 32;@m32
> Selected multilib: .;@m64
>  "/usr/bin/x86_64-pc-linux-gnu-clang-9999" -cc1 -triple
> x86_64-pc-linux-gnu -E -disable-free -disable-llvm-verifier -main-file-name
> null -mrelocation-model static -mdisable-fp-elim -fmath-errno -masm-verbose
> -mconstructor-aliases -munwind-tables -fuse-init-array -target-cpu x86-64
> -target-linker-version 2.23.2 -v -dwarf-column-info -resource-dir
> /usr/bin/../lib/clang/3.6.0 -internal-isystem
> /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/4.9.1/include/g++-v4
> -internal-isystem
> /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/4.9.1/include/g++-v4/x86_64-pc-linux-gnu
> -internal-isystem
> /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/4.9.1/include/g++-v4/backward
> -internal-isystem /usr/local/include -internal-isystem
> /usr/bin/../lib/clang/3.6.0/include -internal-externc-isystem /include
> -internal-externc-isystem /usr/include -fdeprecated-macro
> -fdebug-compilation-dir /home/craig -ferror-limit 19 -fmessage-length 243
> -mstackrealign -fobjc-runtime=gcc -fcxx-exceptions -fexceptions
> -fdiagnostics-show-option -fcolor-diagnostics -o - -x c++ /dev/null
> clang -cc1 version 3.6.0 based upon LLVM 3.6.0svn default target
> x86_64-pc-linux-gnu
> ignoring nonexistent directory "/usr/local/include"
> ignoring nonexistent directory "/include"
> #include "..." search starts here:
> #include <...> search starts here:
>  /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/4.9.1/include/g++-v4
>
>  /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/4.9.1/include/g++-v4/x86_64-pc-linux-gnu
>  /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/4.9.1/include/g++-v4/backward
>  /usr/bin/../lib/clang/3.6.0/include
>  /usr/include
> End of search list.
> # 1 "/dev/null"
> # 1 "<built-in>" 1
> # 1 "<built-in>" 3
> # 318 "<built-in>" 3
> # 1 "<command line>" 1
> # 1 "<built-in>" 2
> # 1 "/dev/null" 2
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20140815/db7fbea1/attachment.html>


More information about the cfe-dev mailing list