Re: [dev] getting rid of cmake builds

From: NRK <nrk_AT_disroot.org>
Date: Fri, 22 Sep 2023 21:03:06 +0600

On Fri, Sep 22, 2023 at 04:07:15PM +0200, Roberto E. Vargas Caballero wrote:
> can you explain me how you solve the problem of duplicated static
> symbols?

It's not as big of a problem you're making it out to be. Neither dwm or
st for example has duplicated static symbols.

And it's easily solvable by having a slightly more descriptive name
(avoiding unnecessary global variables also reduces chances of
collision).

> Can you explain me where is the complexity?

I've already given a list of things on my initial post.

But if I need to repeat one of them: Dependency tracking is easily the
biggest problem that incremental builds introduce. Which is something that:

a) your tiny example makefile did not tackle
b) dwm makefile gets wrong as it does not track drw.h nor util.h
  (dmenu also fails to track util.h as well).

Aside from that, unity-build only requires a compiler. A Makefile
additionally requires (i) a Make implementation (ii) (usually) a posix
compliant shell.

Also this conversation feels like it's going in circles with me having
to constantly repeat things I've already said, so I'll say this:

If you're already convinced that a makefile is better than a unity
build, then that's fine. I'm not interested in forcing you to use
something else. Nor am I interested in fighting some
editor^W build-system war.

But I've tried out both makefiles (both simple and "complex" ones) and
unity-build and *my* conclusion is that the latter is significantly
simpler and superior for small projects - and I've given a list of
reason on my initial post.

If someone thinks those are valid reasons, then try it out. If not, then
don't.

- NRK
Received on Fri Sep 22 2023 - 17:03:06 CEST

This archive was generated by hypermail 2.3.0 : Fri Sep 22 2023 - 17:12:08 CEST