1

i am trying to build and run a flutter app on windows but i get the following error

Launching lib\main.dart on Windows in debug mode...
lib\main.dart:1
CMake Error at CMakeLists.txt:1 (cmake_minimum_required):
  CMake 3.15 or higher is required.  You are running version
  3.14.19060802-MSVC_2

but my current cmake version is cmake version 3.20.0-rc1 added a CMakeSettings jason file but did not solve the problem all help is appreciated

  • 1
    The version number indicates that you're configuring with CMake that is shipped as part of Visual Studio. CMake stores the full path to the executable used to configure the project in the CMake cache. Even if you later try to use a newer version of CMake to re-configure the project, the CMake executable stored in the cache will be used anyway, which is one possible explanation for what you're seeing. Deleting the build dir fixes this issue. If that doesn't help you need to figure out how to tell VS to use the system CMake, or update Visual Studio (the latest version comes with CMake 3.19) – Corristo Mar 08 '21 at 15:11
  • thanks for the help...i tried everything and i ended up updating VS but got a different error instead CMake Error at CMakeLists.txt:34 (target_compile_features): target_compile_features no known features for CXX compiler "MSVC" – user15353015 Mar 13 '21 at 10:36

0 Answers0