llvm-config --includedir returns wrong directory

Mikael Lepistö mikael.lepisto at tut.fi
Thu Sep 17 11:53:09 UTC 2009


Hi,

Is it really correct that llvm-config --includedir command returns 
/usr/include/llvm ?

Normally llvm headers are always included style #include 
<llvm/Support/Debug.h> where llvm prefix is added explicitly. It's 
usually ok for compilation that the wrong path is returned since the 
includes are found by default searched from /usr/include, but with 
llvm-gcc compilation it does not work.

llvm-gcc (trunk version) Makefile makes dependency 
/usr/include/llvm/Intrinsics.gen for one llvm specific file and 
/usr/include part is asked from llvm-config --includedir since it is the 
only way to ask where includes are actually found (since libraries and 
includes are not even installed to the same prefix on this package).  So 
compilation fails to find dependency and build fails.

Normally llvm-config --includedir returns llvminstalldir/include and all 
include files are under include/llvm directory.

Best regards, Mikael Lepistö




More information about the Pkg-llvm-team mailing list