检测到 Conan 配置文件设置与 CMake 之间的编译器版本不匹配

Detected a mismatch for the compiler version between your conan profile settings and CMake

本文关键字:之间 编译器 版本 不匹配 CMake Conan 配置文件 设置 检测      更新时间:2023-10-16

我遇到了CMake的问题,他们没有检测到CMake编译器的正确版本。

我的 CMake 正在使用命令行,但不是在 CLion 中。

这里是 CLion 中 CMake 工具的输出日志:

CMake Error at build/conanbuildinfo.cmake:1344 (message): Detected a mismatch for the compiler version between your conan profile settings and CMake: Compiler version specified in your conan profile: 9 Compiler version detected in CMake: 8.3 Please check your conan profile settings (conan profile show [default|your_profile_name])

此问题的解决方案是更改编译的两条路径:

CTRL + ALT + S打开参数

转到Build, Execution, Deployment>Toolchain

C Compiler切换到/usr/bin/gcc,将C++ Compiler切换到/usr/bin/g++

相关文章: