I guess you didn’t configure your project.
-
You first need to run
cmake .
at the project root to generate build files. You can also run it from an empty directory to separate source and build files. -
Then you can use
cmake --build ./
in the build dir.
Or, if you prefer code-only:
cd [root-directory-of-your-project]
cmake .
cmake --build ./