Examples of Muduo network library
0) src - source file
1) bazel - build with Bazel
2) cmake-submodule - build with CMake, checking out muduo as a git submodule
3) cmake - build with CMake
2) makefile - build with Makefile
1) build with bazel
cd bazel
bazel build -c opt :all
2) build with CMake with git submodule
git submodule update --init
mkdir build
cd build
cmake ../cmake-submodule
Assuming Muduo is installed in $HOME/build/debug-install
3) build with CMake
mkdir build
cd build
cmake ../cmake
# echo binary is in ./bin/
4) build with GNU make
cd makefile
# echo binary is in ./
上面4种方法中,我所熟悉的是第三种和第四种,这里我以cmake第三种为例:
注意:不论使用make还是cmake也好,注意:muduo库的路径需要根据自己编译后的路径为准。
最近编译evpp过程中cmake失败,报错如下:
CMake Error at /usr/share/cmake/Modules/FindBoost.cmake:1138 (message):
Unable to find the requested Boost libraries.
Unable to find the Boost header files. Please set BOOST_...
cmake是项目管理工具:简化编译构建过程和编译过程。Cmake的工具链非常简单:cmake+make。
在Linux平台下使用CMake生成Makefile并编译的流程如下:A、编写CMake配置文件CMakeLists.txtB、执行命令cmakePATH生成Makefile,PATH是CMakeLists.txt所在的目录。C、使用make命令进行编译。
其中,A既是下文注释的文件,...
# ------------------------------------------------------------------------
# Begin finding boost libraries
# ------------------------------------------------------------------------
FindBoost.cmak
cmake查看debug信息辅助cmake配置
以boost错误为例:
在(cmake-gui中)配置了变量:Boost_INCLUDE_DIR=Z:/BASE_ENV/forOpenMVS/boost_1_74_0后依然出错
CMake Error at Z:/BASE_ENV/CMake/share/cmake-3.18/Modules/FindPackageHandleStandardArgs.cmake:165 (message):
Could NOT find Boost (missing:
此文章对初次或不经常接触linux的人比较重要,linux开发经验丰富的请飘过!一个人良好的习惯就是不断的学习、不断的做笔记,然后吸收为己用. 与此同时为他人做点贡献,学到东西,然后贡献东西,这就是进步的良性互动!
我一直从事windows开发多年,一直很忙也很少接触linux系统,但是关于跨平台的项目做的很少,而实际上夸平台的项目大多是与服务器相关的,随着对boost的熟练使用和有关服务器经验
这个问题困扰我一下午了,关于boost库的问题,最近在做人体动态三维重建的时候,到了最后编译的时候出现问题:就是上面的这个问题,参考了很多中解决方案,一遍一遍的改错,最终还是成功类:编译成功
在这个过程在学会了一些关于cmake的编写手法,对于今后的SLAM的代码研究时非常有帮助的:
对于上面的问题解决:https://stackoverrun.com/cn/q/11313677
在今后的开发中希...