3 ms·
Your problems are not with C the language but with the chosen build tools. Have you tried using a more modern tool like Meson? It is more comparable to Cargo.
by colonwqbang 3y ago
Your problems are not with C the language but with the chosen build tools. Have you tried using a more modern tool like Meson? It is more comparable to Cargo.
To start a new project today using plain GNU Make like the author of the article recommends, is not a good idea unless you enjoy fiddling with the build.
- flykespice 3y ago> Have you tried using a more modern tool like Meson? It is more comparable to Cargo. Not comparable at all. The difference is Cargo is the official standard package manager of the Rust language. Meson is one among the sea of incompatible build systems for the C language.
- binary132 3y agoThat's why we need a new build system / package manager for C. /s (but not really)
- funnyflywheel 3y agohttps://xkcd.com/927 https://xkcd.com/927 comes to mind.
- tialaramex 3y agoRight, crucially cargo is in the box with your Rust compiler, you have to go out of your way to have just the actual Rust compiler but not cargo. As with the lesson gofmt taught, you must supply the basic feature in the box. Humans are lazy, so if it doesn't come in the box only people who know they can't live without it will even bother, put it in the box and only people who can't live with it will remove it.
- humanrebar 3y agoBut C ships to all sorts of places, so why would C limit its options by limiting its support to its own package manager?
- kerkeslager 3y agoHow would having a builtin build system (I'm not even asking for a package manager) limit where C can ship to?
- jjgreen 3y agoWith make, you don't have to install anything, it's POSIX
- yjftsjthsd-h 3y agoBeing POSIX doesn't mean it's included by default; for example, you can start with the default installation of debian, install a compiler, and still not have make installed
- kerkeslager 3y agoThis technically isn't true, but I'll give you the point because I don't see `sudo apt install build-essentials` as a significant barrier to entry. But being able to print "make: ** No targets specified and no makefile found. Stop." to stderr isn't particularly useful, and having to write a Makefile is a significant barrier.
- kerkeslager 3y ago> Your problems are not with C the language but with the chosen build tools. That's not a distinction I care about. The tooling around a language should be a part of discussing the merits of a language. Your language can be the most ergonomic language in the world, but if all your development gains are lost fiddling with build tools, you haven't gained anything. > Have you tried using a more modern tool like Meson? I haven't, but now that I know about it, I'll give it a try. Thanks for the info! It looks promising. > To start a new project today using plain GNU Make like the author of the article recommends, is not a good idea unless you enjoy fiddling with the build. Maybe, but that just brings up the problem that there isn't really a clear second-tier system outside the standard library for tools. Certain tools (i.e. Valgrind) are well-known, but there are a million different ways to install a million different tools and for most things it's ultimately more common to just roll your own.