[cfe-users] libcxx.llvm.org linux build instructions unclear
Jeffrey Walton
noloader at gmail.com
Thu Jul 10 13:23:34 PDT 2014
> Unfortunately, when using libcxx with a hello_world.cpp, get missing files:
>
> make
> ls -ld /usr/local/lib/libc++*
> lrwxrwxrwx 1 root root 11 Jul 10 12:45 /usr/local/lib/libc++.so ->
> libc++.so.1
> lrwxrwxrwx 1 root root 13 Jul 10 12:45 /usr/local/lib/libc++.so.1 ->
> libc++.so.1.0
> -rw-r--r-- 1 root root 1054759 Jul 10 11:53 /usr/local/lib/libc++.so.1.0
> ls -ld /usr/local/include/c++/v1/../*
> drwxr-xr-x 19 root root 4096 Jul 7 12:11 /usr/local/include/c++/v1/../4.9.0
> drwxr-xr-x 5 root root 4096 Jul 10 12:45 /usr/local/include/c++/v1/../v1
> /usr/local/bin/clang++ -std=c++11 -stdlib=libc++ -nostdinc
> -I/usr/local/include/c++/v1 -I/usr/local/include/c++/v1/../4.9.0
> -L/usr/local/lib hello_world.cpp -o hello_world.exe
> In file included from hello_world.cpp:1:
> /usr/local/include/c++/v1/../4.9.0/iostream:38:10: fatal error:
> 'bits/c++config.h' file not found
> #include <bits/c++config.h>
> ^
> 1 error generated.
> make: *** [run] Error 1
>
> Anyone have any ideas how to get libcxx to work on ubuntu?
>
Its a distant memory, but....
I seem to recall I had to use -I to include the path to the correct
headers like <bits/c++config.h>. This was on Debian with an updated
Clang (I built and used 3.3 in /usr/local/bin, while Debian provided
3.1, IIRC).
Jeff
More information about the cfe-users
mailing list