当我为库cashlib运行'make'时,我有以下错误。我按照wiki中的说明执行相同的步骤。我在Mac OS X Yosemite中遇到这些错误。但是,当我在Ubuntu 12.04版中执行相同的步骤时,我没有任何问题。我想这个问题是一些不相容的问题,但我无法完全理解。
g++ -O3 -Wno-deprecated -Wall -Wno-sequence-point -Wno-parentheses -g -I. -I/pro/brownie/local/include -I/opt/local/include -fno-inline -MD -c -o Serialize.h.gch Serialize.h
In file included from Serialize.h:4:
In file included from /opt/local/include/boost/archive/binary_oarchive.hpp:21:
In file included from /opt/local/include/boost/archive/binary_oarchive_impl.hpp:22:
In file included from /opt/local/include/boost/archive/basic_binary_oarchive.hpp:33:
In file included from /opt/local/include/boost/archive/detail/common_oarchive.hpp:22:
In file included from /opt/local/include/boost/archive/detail/interface_oarchive.hpp:23:
In file included from /opt/local/include/boost/archive/detail/oserializer.hpp:38:
In file included from /opt/local/include/boost/serialization/extended_type_info_typeid.hpp:27:
In file included from /opt/local/include/boost/serialization/static_warning.hpp:67:
/opt/local/include/boost/mpl/print.hpp:50:19: warning: in-class initialization of non-static data member is a C++11
extension [-Wc++11-extensions]
const int m_x = 1 / (sizeof(T) - sizeof(T));
^
In file included from Serialize.h:27:
./Serialize_map.h:31:8: error: 'Archive' does not refer to a value
Archive,
^
./Serialize_map.h:23:16: note: declared here
template<class Archive, class Type, class Key, class Hash, class
^
./Serialize_map.h:30:31: error: no member named 'load_collection' in namespace 'boost::serialization::stl'
boost::serialization::stl::load_collection<
~~~~~~~~~~~~~~~~~~~~~~~~~~~^
./Serialize_map.h:76:8: error: 'Archive' does not refer to a value
Archive,
^
./Serialize_map.h:68:16: note: declared here
template<class Archive, class Type, class Key, class Hash, class
^
./Serialize_map.h:75:31: error: no member named 'load_collection' in namespace 'boost::serialization::stl'
boost::serialization::stl::load_collection<
~~~~~~~~~~~~~~~~~~~~~~~~~~~^
1 warning and 4 errors generated.
make: *** [Serialize.h.gch] Error 1