1
我尝试编译clng,并将clang和libC++链接为我的项目,该项目使用ginac(本身使用cln)需要某些C++ 11功能。在我的努力,我发现,这对链接的libC++来代替stdlibC++应该做的伎俩,所以我在使用下面的命令来配置结束了:使用clang和libC++编译cln
./configure CXX=/usr/bin/clang++ CXXFLAGS="-stdlib=libc++ -std=c++11" LDFLAGS="-stdlib=libc++"
工作正常。但是我得到调用时进行以下错误信息:
Making all in src
/bin/sh ../libtool --tag=CXX --mode=compile /usr/bin/clang++ -DHAVE_CONFIG_H -I. - I../autoconf -I../include -I../src -I../include -I../src -stdlib=libc++ -std=c++11 -MT cl_alloca.lo -MD -MP -MF .deps/cl_alloca.Tpo -c -o cl_alloca.lo `test -f 'base/cl_alloca.cc' || echo './'`base/cl_alloca.cc
libtool: compile: /usr/bin/clang++ -DHAVE_CONFIG_H -I. -I../autoconf -I../include - I../src -I../include -I../src -stdlib=libc++ -std=c++11 -MT cl_alloca.lo -MD -MP -MF .deps/cl_alloca.Tpo -c base/cl_alloca.cc -fno-common -DPIC -o .libs/cl_alloca.o
In file included from base/cl_alloca.cc:4:
In file included from ./base/cl_sysdep.h:56:
In file included from ./base/cl_macros.h:7:
../include/cln/exception.h:14:24: error: implicit instantiation of undefined template 'std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >'
: std::runtime_error(std::string()) {}
^
/usr/bin/../lib/c++/v1/iosfwd:187:28: note: template is declared here
class _LIBCPP_TYPE_VIS basic_string;
^
1 error generated.
make[1]: *** [cl_alloca.lo] Error 1
make: *** [all-recursive] Error 1
什么我做错了,我怎么能解释此errormessage的最终解决我的问题?