steamdog said:
but what does that mean exactly, what does it do, and how do I know if it's something I should use?
You wrote a nice program and want to allow others to use it too.
In some way, they must arrive with a built executable from your sources. If it's all plain C++ from the ground up using only functions defined in the standard C++ libraries, that is not too difficult.
However, you may want to use a widget library to have a GUI front-end, or display graphics in a game-like way with eg SDL2, or something else outside standard C++. They must then also grab those libraries and install them.
They may however pick a different spot for putting them on their system, or eg get them pre-compiled from another source that also has different ideas about where to put the result.
For more fun, if you not only want to support Windows VS, but also different C++ compilers, or different OSes like Mac or Linux or … , then your configuration of how to compile is not going to work anymore.
CMake addresses these kinds of changes in a project. It knows about many OSes, it knows how to find installed libraries, it knows what scripts to generate for a different compiler, it knows where to install the result, etc etc.
In other words, CMake hides all those differences. Your users can run CMake on your code (including some CMake information what to combine and compile, etc), and it will handle all the install details for the above-like cases. After running CMake, it produces a script that will coimpile & install the built code. Your users can run that script, and it will make your program available at their system.