Live data from Hacker News

Why Use Make

bost.ocks.org

51–60 of 248 posts

Re: Why Use Make

#51
post #16
post #8

Earlier quoted context omitted.

Have you tried Waf? http://code.google.com/p/waf/ Seems like it might be a good fit.

How does Waf compare to SCons? I'm a big fan of SCons, although it annoyingly does not have transitive dependency resolution for libraries. Waf has this functionality, correct?

I found it hard to make scons build outside my source directory (instead of polluting it). This is important for example when you don't want random files showing up in your git clone.

With waf, this is easy.

Subjectively, waf code looks more Pythonic than scons, though both are supposedly Python.

Re: Why Use Make

#53

If you use GNU Make it's worth using my GNU Make Standard Library: http://gmsl.sourceforge.net/ And also reading everything I wrote as Mr. Make: http://blog.jgc.org/2013/02/updated-list-of-my-gnu-make-arti... Or buy my book: http://www.lulu.com/shop/john-graham-cumming/gnu-make-unleas...

gmsl is a wonderful, well considered library. I had to buy the book after finding it.

Thanks!

Re: Why Use Make

#54

Absolutely do not use make for any new project. If you love make, it's a big, red, burning flag that you're not demanding enough of your tools and that you're not keeping up with changes in your ecosystem. There are many, many way better alternatives to make. Which one is better depends on the platform you're on. The majority of them throws in automatic dependency management for free. Yes, I know that the essence of…

Lots of "Don't do this" without suggesting alternatives doesn't do anyone much good. If you're on a *nix system, building C/C++ programs (or automating one-off builds like the example), what would you recommend in make's place?

Ninja.

Re: Why Use Make

#55

Everyone points at make and says, "use something better". They point at Rake, they point at Maven. However, Make has one feature that I really need, that I rely on to speed up builds: parallel dependency construction. The last time I checked, neither Maven nor Rake do this properly. Maven runs everything inside a single VM. Who wants to have to worry about multithreading in their unit tests? Rake requires thread supp…

Waf can also do parallel build with proper dependencies, and it's Python-based. Have you looked at it? The documentation is rather clear, but the initial learning curve is probably steeper than make.

Re: Why Use Make

#56
post #39

Earlier quoted context omitted.

"There are many, many way better alternatives to make" Can you give an example with the ubiquity of make and better expressiveness?

No, probably not. But I think the metrics you've chosen are irrelevant. Make was not only the best, it was the only player in the game until quite recently, so of course it's ubiquitous. As for expressiveness, yes, it certainly is expressive. It's also very hard to learn and very difficult to maintain. But build systems such as Gradle or SBT, are also incredibly expressive, by virtue of being configurable in actual p…

"But I think the metrics you've chosen are irrelevant."

Nothing is more frustrating than discovering that you need to install a new component or build system just to build a specific component. It gets worse when dealing with multiple external components in different build systems.

"It's also very hard to learn and very difficult to maintain"

I agree insofar as most people go into make without trying to learn it properly. There's a manpage and pretty good documentation for the GNU extensions. But in my experience, with custom build setups using stuff like Maven, a lot of time is spent fighting the build system when a simple Makefile would suffice.

"with the added benefit of not having to learn a new language."

You've shifted the burden from "learning a new but very simple language" to "learning a framework atop your language", which (based on my reading of gradle's docs) is not very concise.

Re: Why Use Make

#57
Everybody seems to be missing the fact that he's not talking about building a big software project. He's talking about scripting a simple workflow around a few files. Make is probably better than anything else for this, because under these circumstances it's so simple it's hard to get it wrong.

Something like Rake is obviously better when you need to really program your builds.

Re: Why Use Make

#58

Absolutely do not use make for any new project. If you love make, it's a big, red, burning flag that you're not demanding enough of your tools and that you're not keeping up with changes in your ecosystem. There are many, many way better alternatives to make. Which one is better depends on the platform you're on. The majority of them throws in automatic dependency management for free. Yes, I know that the essence of…

"Which one is better depends on the platform you're on" That works against a portable build. That still matters to some of us.

By 'platform' I meant programming language and execution environment (JVM/Ruby/Python), not OS.

Re: Why Use Make

#59
post #56

Earlier quoted context omitted.

No, probably not. But I think the metrics you've chosen are irrelevant. Make was not only the best, it was the only player in the game until quite recently, so of course it's ubiquitous. As for expressiveness, yes, it certainly is expressive. It's also very hard to learn and very difficult to maintain. But build systems such as Gradle or SBT, are also incredibly expressive, by virtue of being configurable in actual p…

"But I think the metrics you've chosen are irrelevant." Nothing is more frustrating than discovering that you need to install a new component or build system just to build a specific component. It gets worse when dealing with multiple external components in different build systems. "It's also very hard to learn and very difficult to maintain" I agree insofar as most people go into make without trying to learn it prop…

Indeed, mseebach's answer is really saying that those metrics are irrelevant to him.

Re: Why Use Make

#60
post #54

Earlier quoted context omitted.

Lots of "Don't do this" without suggesting alternatives doesn't do anyone much good. If you're on a *nix system, building C/C++ programs (or automating one-off builds like the example), what would you recommend in make's place?

Ninja.

You probably don't want to write ninja files yourself. CMake + Ninja is a nice combo.
Post reply on HN