Problem compiling android game

I have a project made in cocos2dx with c++.

When i try to compile it i get the following error: CMake 3.12 or higher is required. You are running version 3.10.2

When i uninstall CMake 3.10, then i get: Cannot run program “D:\Dev\Android\sdk\cmake\\bin\cmake”: CreateProcess error=2, System can not find the specified file.

I tried changing in CMakeLists.txt cmake_minimum_required(VERSION 3.12) to cmake_minimum_required(VERSION 3.10) but it leads to another error:
CMake Error at D:\Projs\myproj\gamelib\cocos2d\cocos\CMakeLists.txt:123 (add_subdirectory):
The source directory


does not contain a CMakeLists.txt file.

What am i doing wrong?