4 ms·
After maybe three years of experience with cmake I must admit its scripting language is just disgusting. Makefile provided a nice, well thought out, simple DSL,
by piokuc 11y ago
After maybe three years of experience with cmake I must admit its scripting language is just disgusting. Makefile provided a nice, well thought out, simple DSL, with just three concepts: targets, dependencies and actions, and while it didn't provide enough support for handling multiple compiler toolchains, etc. I think replacing it with the cmake shell like 'scripting language', sporting one data structure (string; lists are really just semicolon separated strings...), is an example of very, very bad engineering.
- to3m 11y agoYes. If they had used something like Python, it would probably be heaps better. (Though to be honest I'm not really sure I trust the cmake developers' collective judgment. I'm sure they could manage to make it awful.) But, even though it's horrid, I do find it CMake easier to work with than make on a day to day basis. CMake's scripting language is at least straightforwardly imperative; CMake has at least some support for working around certain platform/toolchain differences (though this support is rather half-hearted in some key places); it has a couple of handy features that make working with C/C++ libraries quite easy; it has builtin support for test suites. All more convenient than doing it all by hand in GNU make, and you've got support for multiple backends too. Oh, and it supports Windows, too. Though I admit it only through gritted teeth, it provides value.