Yes, CMake is crazy. And ugly. And inconvenient
How many years has it been since you last used CMake?
CMake suffers from some of the same perception issues as C++. A lot of the criticism usually boils down to the designers prioritizing backwards compatibility, a thing even critics would agree is a good thing. As an example, the OP shows a CMake and Meson snippet. The CMake one is 3 lines, the Meson one is 2. The extra line in the CMake sample is a version declaration for backwards compatibility, but the rest are identical.
If you look past your preconceived notions, you'll find that CMake is a good build system and very easy to use. It's also one of the few that fully supports C++20 modules today.
It's by no means a silver bullet, and the generator-based design isn't always the best choice, but its undoubtedly the best choice for the vast majority of C or C++ projects.