.so 依赖目录 cmake_工程后端Cmake问题解决记录(二)

XX核心区域

./bootstrap --prefix=/usr/local --enable-s3

make -j 8 && make install-xxdb

问题12:

/usr/local/lib/libtiledb.so: undefined reference to `tbb::task::note_affinity(unsigned short)'

/usr/local/lib/libtiledb.so: undefined reference to `tbb::task_group_context::cancel_group_execution()'

/usr/local/lib/libtiledb.so: undefined reference to `tbb::task_scheduler_init::terminate()'

/usr/local/lib/libtiledb.so: undefined reference to `typeinfo for tbb::task'

/usr/local/lib/libtiledb.so: undefined reference to `tbb::internal::allocate_root_with_context_proxy::free(tbb::task&) const'

/usr/local/lib/libtiledb.so: undefined reference to `tbb::task_group_context::init()'

/usr/local/lib/libtiledb.so: undefined reference to `tbb::task_scheduler_init::default_num_threads()'

/usr/local/lib/libtiledb.so: undefined reference to `tbb::internal::get_initial_auto_partitioner_divisor()'

/usr/local/lib/libtiledb.so: undefined reference to `tbb::task_group_context::~task_group_context()'

/usr/local/lib/libtiledb.so: undefined reference to `tbb::internal::allocate_child_proxy::allocate(unsigned long) const'

/usr/local/lib/libtiledb.so: undefined reference to `tbb::internal::allocate_continuation_proxy::allocate(unsigned long) const'

/usr/local/lib/libtiledb.so: undefined reference to `tbb::task_group_context::is_group_execution_cancelled() const'

/usr/local/lib/libtiledb.so: undefined reference to `tbb::task::self()'

/usr/local/lib/libtiledb.so: undefined reference to `tbb::task_scheduler_init::initialize(int, unsigned long)'

/usr/local/lib/libtiledb.so: undefined reference to `tbb::internal::allocate_root_with_context_proxy::allocate(unsigned long) con

解决问题的方法是:在CMakefile.txt中加入对tbb的引用

target_link_libraries(ImageStorage tbb)

问题13:

/usr/local/satellive-core-svn/core/src/main.cpp:4:10: fatal error: evpp/http/http_server.h: No such file or directory

解决问题的办法是:

在/usr/local/satellive-core-svn/core/evpp目录下面

编译和安装evpp库,mkdir build && cd build && make && make install

问题14:

evpp/evpp/logging.h:9:10: fatal error: glog/logging.h: No such file or directory

sudo apt-get install libgoogle-glog-dev

缺少google的日志头文件,下一波自己做本地镜像,生成docker

问题15:

src/../query_image/s2coords_map.h:7:10: fatal error: s2/s2coords.h: No such file or directory

缺少S2的编译和安装

问题16:(全面使用boost库,结合libevent进行开发

/usr/local/satellive-core-svn/core/s2geometry/src/s2/s2shapeutil_testing.cc:20:10: fatal error: gtest/gtest.h: No such file or directory

在CMakeList.txt 中确认有add_subdirectory(core/googletest)

在/usr/local/satellive-core-svn/core/googletest目录中编译和安装

/usr/local/satellive-core-svn/core/googletest/build中make && make install

问题17:

/usr/local/satellive-core-svn/core/s2geometry/build过程中出现的问题是

CMake Error at cmake_install.cmake:239 (file):

file INSTALL cannot find

"/usr/local/satellive-core-svn/core/s2geometry/   ".

将cmake_install.cmake的239行改造成:

/usr/local/satellive-core-svn/core/s2geometry/

使得该cmake_install.cmake文件的有关内容变为:(注意如果没看到该文件,应该首先使用cmake ..产生该文件)

if("x${CMAKE_INSTALL_COMPONENT}x" STREQUAL "xUnspecifiedx" OR NOT CMAKE_INSTALL_COMPONENT)

file(INSTALL DESTINATION "${CMAKE_INSTALL_PREFIX}/include/s2/third_party/absl/strings" TYPE FILE FILES

"/usr/local/satellive-core-svn/core/s2geometry/src/s2/third_party/absl/strings/numbers.h"

"/usr/local/satellive-core-svn/core/s2geometry/src/s2/third_party/absl/strings/str_cat.h"

"/usr/local/satellive-core-svn/core/s2geometry/src/s2/third_party/absl/strings/string_view.h"

"/usr/local/satellive-core-svn/core/s2geometry/"

"/usr/local/satellive-core-svn/core/s2geometry/src/s2/third_party/absl/strings/str_join.h"

"/usr/local/satellive-core-svn/core/s2geometry/src/s2/third_party/absl/strings/match.h"

)

endif()

问题18:

/src/../query_image/query.h:50:10: fatal error: kml/base/file.h: No such file or directory

原因是需要编译和安装KML的库和头文件

用的kml版本是1.3.0, 要放在/usr/local/satellive-core-svn/core/libkml-1.3.0下面,编译和安装,mkdir build && cd build && cmake .. && make install

问题19:

core/src/../query_image/../http_server/satellive_mq_factory.h:13:10: fatal error: rocketmq/CProducer.h: No such file or directory

原因是需要编译和安装rocketmq的库和头文件

在/usr/local/satellive-core-svn/core/rocketmq-client-cpp目录中进行编译mkdir build && cd build && cmake .. && make install

问题20:

/usr/local/include/s2/base/log_severity.h:36:20: error: ‘constexpr const bool google::DEBUG_MODE’ redeclared as different kind of symbol

constexpr bool DEBUG_MODE = true;

修改/usr/local/include/s2/base/log_severity.h

将其注释掉

//constexpr bool DEBUG_MODE = true

问题21:

query.cpp:14:10: fatal error: msgpack.hpp: No such file or directory

原因是需要编译和安装msgpack的库和头文件

/usr/local/satellive-core-svn/core/msgpack-c/build

运行:

cmake -DMSGPACK_CXX[11]=ON .. make && make install

/usr/include/c++/7/bits/c++0x_warning.h:32:2: error: #error This file requires compiler and library support for the ISO C++ 2011 standard. This support must be enabled with the -std=c++11 or -std=gnu++11 compiler options.

#error This file requires compiler and library support , 可能是gtest的原因

排除这个原因,可以直接删除对test的目录的编译过程,具体修改

/usr/local/satellive-core-svn/core/msgpack-c的CMakefile.txt文件,将以下内容注释掉:

#IF (MSGPACK_BUILD_TESTS)

# ENABLE_TESTING ()

# MEMORYCHECK_COMMAND_OPTIONS needs to place prior to CTEST_MEMORYCHECK_COMMAND

# SET (MEMORYCHECK_COMMAND_OPTIONS "--leak-check=full --show-leak-kinds=definite,possible --error-exitcode=1")

# FIND_PROGRAM(CTEST_MEMORYCHECK_COMMAND NAMES valgrind)

# INCLUDE(Dart)

# ADD_SUBDIRECTORY (test)

#ENDIF ()

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值