2014-02-17 106 views
0

我已经在我的Ubuntu 12.04 LTS上安装了提升以及Cassandra cpp driver所需的其他依赖。当我尝试运行下面的命令时,最终会出现两个错误。我寻找解决方案,但找不到任何。有人说通过添加我尝试过的选项-lboost_system来链接libboost_system,但没有帮助。未定义的引用符号'boost :: future_category()'

这里是cmd:cmake。 & &使& &使cql_demo & &使cql_test & &化妆测试& &使安装-lboost_system

所有我想要做的是从驱动程序运行演示,并与卡桑德拉数据库进行通信!

错误:

-- info CMAKE_BINARY_DIR: /home/pi/experiments/cpp-driver-master2 
-- Configuring done 
-- Generating done 
-- Build files have been written to: /home/pi/experiments/cpp-driver-master2 
[ 42%] Built target cql 
[ 85%] Built target cql_static 
[ 87%] Built target CCMBridge 
Linking CXX executable cql_integration_tests 
/usr/bin/ld: warning: libboost_thread.so.1.55.0, needed by /usr/local/lib/libboost_log.so, may conflict with libboost_thread.so.1.46.1 
/usr/bin/ld: CMakeFiles/cql_integration_tests.dir/src/test_utils.cpp.o: undefined reference to symbol 'boost::future_category()' 
/usr/bin/ld: note: 'boost::future_category()' is defined in DSO /usr/local/lib/libboost_thread.so.1.55.0 so try adding it to the linker command line 
/usr/local/lib/libboost_thread.so.1.55.0: could not read symbols: Invalid operation 
collect2: ld returned 1 exit status 
make[2]: *** [test/integration_tests/cql_integration_tests] Error 1 
make[1]: *** [test/integration_tests/CMakeFiles/cql_integration_tests.dir/all] Error 2 
make: *** [all] Error 2 

回答

0

以下错误:

/usr/bin/ld: warning: libboost_thread.so.1.55.0, needed by /usr/local/lib/libboost_log.so, may conflict with libboost_thread.so.1.46.1 

基本上是说,你必须安装升压的两个版本:

  • 定制的一个在/usr/local/lib/,大概版1.55.0。
  • 另一个在系统目录中,可能是版本1.46.1。

当他们都获得链接到您的二进制版本1.46.1胜。

您需要查看CMake调用的所有完整命令行,以确切地说明问题所在。

+0

你说得对!谢谢! – zuubs

相关问题