本人尝试编译指定commit版本的MRPT库,报错以下,git
CMake Error at cmakemodules/script_detect_gcc.cmake:16 (LIST): list GET given empty list Call Stack (most recent call first): CMakeLists.txt:83 (include) CMake Error at cmakemodules/script_detect_gcc.cmake:17 (LIST): list GET given empty list Call Stack (most recent call first): CMakeLists.txt:83 (include)
注:本机gcc版本7.4.0,cmake版本3.5.1。github
错误排查流程:spa
1. 排查出报错的位置。在 ./cmakemodules/script_detect_gcc.cmake 文件的16-17行。code
2. 尝试描述该问题,即弄清楚问题是什么——“cmake detect gcc version, get error 'list get given empty list' ”blog
3. 搜索该问题,一击必中。ip
https://answers.opencv.org/question/65548/cmake-error-at-cmakeopencvdetectcxxcompilercmake/get