当我在 Windows 上编译 ESP-IDF 的 hello world 示例时。我收到此错误:
Compiler supported targets:
-- Configuring incomplete, errors occurred!
CMake Error at C:/Espressif/frameworks/esp-idf-v5.1.2/components/xtensa/project_include.cmake:17 (if):
See also "C:/Espressif/frameworks/esp-idf-v5.1.2/workspace/hello_world/build/CMakeFiles/CMakeOutput.log".
if given arguments:
"NOT" "(" "Generic" "STREQUAL" "Generic" "AND" "MATCHES" "xtensa" ")"
Unknown arguments specified
Call Stack (most recent call first):
C:/Espressif/frameworks/esp-idf-v5.1.2/tools/cmake/build.cmake:398 (include)
C:/Espressif/frameworks/esp-idf-v5.1.2/tools/cmake/build.cmake:620 (__build_process_project_includes)
C:/Espressif/frameworks/esp-idf-v5.1.2/tools/cmake/project.cmake:547 (idf_build_process)
CMakeLists.txt:6 (project)
我尝试卸载环境并重新安装,检查是否有缺少配置,但结果相同。
这是我看到的一个常见错误。不确定是什么原因导致的,但删除 build/ 文件夹并再次构建通常似乎可以修复它。