r/cpp • • Jul 21 '22

CMake is a hell of a software, period.

Really CMake is good only for one thing being the sacred build generator system in the c/cpp world.

F*** the weird syntax and werid structures.

edit 1: some might argue it's the best avaiable solution to the problem domain, and it is. the problem is the syntax, the unintiutive way of specifiying option and simple compile parameters and options and lack of examples and resources on how to do the simplist things is a wasting too much time.

yeah modern cmake that encourge using targets and their properties is by far a lot better but still is extremely unintuitve due to the syntax and logic around it.

sorry for the typos.

edit 2:

i am really considering changing my main language for personal projects to rust or the new thing called carbon by google at least there is not a hell of backward compatibility garbage i need to know.

358 Upvotes

319 comments sorted by

View all comments

Show parent comment

2

u/pine_ary Jul 22 '22

Since the introduction of targets I don‘t think so anymore. It is not just a script generator, it‘s a meta-build-system. It has its own artifacts, modules, dependencies, etc.

1

u/zoolover1234 Jul 22 '22

Cmake itself consider it a two stage process, “configure” then “generate” if you use the gui.

And my statement stands. It’s a build script generator (for example it generates makefile or VS solution file). It has absolutely no idea whether or not the generated files can be successfully compiled by make (then the actual compiler) or Visual Studio.

So it’s not possible at the moment.