一、报错内容
--- stderr: iceoryx_posh
Cloning into 'src'...
Note: switching to 'v0.1.1'.
You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by switching back to a branch.
If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -c with the switch command. Example:
git switch -c <new-branch-name>
Or undo this operation with:
git switch -
Turn off this advice by setting config variable advice.detachedHead to false
HEAD is now at fededad one-char typo
Submodule 'deps/meta-cmake' (https://github.com/meta-toolkit/meta-cmake.git) registered for path 'deps/meta-cmake'
Cloning into '/home/EPRobot/ros2_galactic/build/iceoryx_posh/dependencies/cpptoml/src/deps/meta-cmake'...
fatal: unable to access 'https://github.com/meta-toolkit/meta-cmake.git/': Failed to connect to github.com port 443: Connection timed out
fatal: clone of 'https://github.com/meta-toolkit/meta-cmake.git' into submodule path '/home/EPRobot/ros2_galactic/build/iceoryx_posh/dependencies/cpptoml/src/deps/meta-cmake' failed
Failed to clone 'deps/meta-cmake'. Retry scheduled
Cloning into '/home/EPRobot/ros2_galactic/build/iceoryx_posh/dependencies/cpptoml/src/deps/meta-cmake'...
fatal: unable to access 'https://github.com/meta-toolkit/meta-cmake.git/': GnuTLS recv error (-110): The TLS connection was non-properly terminated.
fatal: clone of 'https://github.com/meta-toolkit/meta-cmake.git' into submodule path '/home/EPRobot/ros2_galactic/build/iceoryx_posh/dependencies/cpptoml/src/deps/meta-cmake' failed
Failed to clone 'deps/meta-cmake' a second time, aborting
CMake Error at download/ext_cpptoml-prefix/tmp/ext_cpptoml-gitclone.cmake:52 (message):
Failed to update submodules in:
'/home/EPRobot/ros2_galactic/build/iceoryx_posh/dependencies/cpptoml/src'
make[2]: *** [CMakeFiles/ext_cpptoml.dir/build.make:92: ext_cpptoml-prefix/src/ext_cpptoml-stamp/ext_cpptoml-download] Error 1
make[1]: *** [CMakeFiles/Makefile2:76: CMakeFiles/ext_cpptoml.dir/all] Error 2
make: *** [Makefile:84: all] Error 2
CMake Error at cmake/cpptoml/CMakeLists.txt:56 (message):
Build step [download] for cpptoml failed: 2
---
Failed <<< iceoryx_posh [4min 21s, exited with code 1]
Aborted <<< foonathan_memory_vendor [6min 30s]
Aborted <<< yaml_cpp_vendor [6min 12s]
Aborted <<< google_benchmark_vendor [6min 45s]
Summary: 68 packages finished [11min 26s]
1 package failed: iceoryx_posh
3 packages aborted: foonathan_memory_vendor google_benchmark_vendor yaml_cpp_vendor
4 packages had stderr output: foonathan_memory_vendor google_benchmark_vendor iceoryx_posh rti_connext_dds_cmake_module
二、解决办法
找到文件:/home/EPRobot/ros2_galactic/build/iceoryx_posh/dependencies/cpptoml/src/.gitmodules
(EPRobot是用户名,根据自己设置情况需要修改)
修改加入代理:
加入 https://phroxy.com/
三、结果
build成功
四、报错原因
国内的网络访问github,网络不通畅。