Warning: file_get_contents(/data/phpspider/zhask/data//catemap/6/cplusplus/138.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

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/solr/3.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
C++ 未定义的引用;std::tr1::“详细信息::“素数列表”;在G++;4.8_C++ - Fatal编程技术网

C++ 未定义的引用;std::tr1::“详细信息::“素数列表”;在G++;4.8

C++ 未定义的引用;std::tr1::“详细信息::“素数列表”;在G++;4.8,c++,C++,我正在尝试用G++4.8构建一些代码。操作系统为FreeBSD 9.2 64位。 以下是我得到的错误: /usr/local/lib/gcc48/include/c++/tr1/hashtable_policy.h:384: undefined reference to `std::tr1::__detail::__prime_list' /usr/local/lib/gcc48/include/c++/bits/stl_list.h:1570: undefined reference to `

我正在尝试用G++4.8构建一些代码。操作系统为FreeBSD 9.2 64位。
以下是我得到的错误:

/usr/local/lib/gcc48/include/c++/tr1/hashtable_policy.h:384: undefined reference to `std::tr1::__detail::__prime_list'
/usr/local/lib/gcc48/include/c++/bits/stl_list.h:1570: undefined reference to `std::__detail::_List_node_base::_M_unhook()'
/usr/local/lib/gcc48/include/c++/bits/stl_list.h:1562: undefined reference to `std::__detail::_List_node_base::_M_hook(std::__detail::_List_node_base*)'

我在某处读到这些函数在
libstdc++
中。在阅读本文时,我在我的项目中添加了该库,但仍然会出现这些错误。我应该添加
libstdg++
?或者是别的什么?我不明白。

由于Makefile程序的错误配置,当我使用cc而不是gcc链接程序时,我遇到了相同的错误。

请发布一个。。。您是否使用EclipseCDT编译此程序??