Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/video/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
如何构建clang+;具有非系统gcc的LLVM_Gcc_Clang_Llvm - Fatal编程技术网

如何构建clang+;具有非系统gcc的LLVM

如何构建clang+;具有非系统gcc的LLVM,gcc,clang,llvm,Gcc,Clang,Llvm,我正在尝试切换到/usr/local/bin/gcc中的gcc47+设置。默认系统gcc是/usr/bin/gcc中的4.4.6 类似的头文件: /usr/include/c++/4.4.4/bits/stl\u pair.h /usr/local/include/c++/4.7.1/bits/stl_pair.h locate exception_ptr.h /usr/include/c++/4.4.4/exception_ptr.h /usr/local/include/c++/4.7.1/

我正在尝试切换到
/usr/local/bin/gcc
中的gcc47+设置。默认系统gcc是
/usr/bin/gcc
中的4.4.6

类似的头文件:

/usr/include/c++/4.4.4/bits/stl\u pair.h
/usr/local/include/c++/4.7.1/bits/stl_pair.h

locate exception_ptr.h
/usr/include/c++/4.4.4/exception_ptr.h
/usr/local/include/c++/4.7.1/bits/exception_ptr.h
我试图用
cd/apps/llvmbuild构建llvm-clang/apps/llvm/configure--prefix=/apps/llvmbuild--enable-optimized--enable-cxx11--enable docs=no--enable targets=host only--disable断言CPPFLAGS=-I/usr/local/include/cxflags=-I/usr/local/include/

然后
cd/apps/llvmbuild;make-j12 ENABLE_OPTIMIZED=1 DISABLE_ASSERTIONS=1

<>但是我发现了错误,显示它正在搜索4.4.6目录中的C++文件:
/usr/lib/gcc/x86_64-redhat-linux/4.4.6/../../../../../../include/c++/4.4.6/exception_ptr.h

locate exception_ptr.h
/usr/include/c++/4.4.4/exception_ptr.h
/usr/local/include/c++/4.7.1/bits/exception_ptr.h

使用CCCXX环境变量。 有关信息,请参见
configure--help

Some influential environment variables:
  CC          C compiler command
  ...
  CXX         C++ compiler command

Use these variables to override the choices made by `configure' or to help
it to find libraries and programs with nonstandard names/locations.
大概是这样的:

CXX=/usr/local/bin/g++ CC=/usr/local/bin/gcc /apps/llvm/configure --your --other --options