reggae v0.10.0 - The meta build system just got better

Andrey Zherikov andrey.zherikov at gmail.com
Thu Sep 21 13:38:30 UTC 2023


On Wednesday, 20 September 2023 at 21:19:22 UTC, Atila Neves 
wrote:
> Because we don't have one now. Using CMake for D is horrible,

I would say just using CMake is horrible :-D But there are a lot 
of people using it (even myself) and they all are trapped with 
the language.

> Hand-written Makefiles are a nightmare and will never get 
> dependencies right. dub isn't a build system, although it 
> includes a very limited one that can't be extended.

I agree that dub is not a build tool, it's more a package manager.

>> TBH I had the same thought - we should have "good" build tool 
>> for D that has D as a language. Since I have some experience 
>> with CMake and agree with a lot of people that it have 
>> horrible language, I thought it would be beneficial. But then 
>> I looked round and realized that it will be like this:
>
> In practice, this doesn't seem to happen with build systems. 
> Instead each language ecosystem ends up using its own: CMake, 
> Gradle, Rake, ...

IMHO this does not prove that D must have its own build system.

>> Have you looked as Meson, for example - it even has a [section 
>> about D](https://mesonbuild.com/D.html)?
>
> Yes, and even had to use it for D. I don't know what state it's 
> in now, but it was pretty much unusable if one had dub 
> dependencies which... is nearly always the case.

I believe this is applicable to all build systems atm - they 
don't know what dub is and how to deal with it.

> Then there's the language: I'd rather use D or Python. If 
> anything, Meson's use case could be questioned just as well by 
> "why another build language?".

TBH I thought Meson uses python but just found out it's not. My 
bad.
Just took a quick look at [known build 
tools](https://en.wikipedia.org/wiki/List_of_build_automation_software#Licensing_overview) and noticed that there are (at least) two build tools that have Python as a build language and support D: [SCons](https://en.wikipedia.org/wiki/SCons#Major_features) and [Waf](https://en.wikipedia.org/wiki/Waf_(build_system)#Features). Although I don't how well they support it.


My whole comment was about the reasoning why we need new build 
system and can't improve existing one. So I would expect more 
wide analysis and comparison 
[here](https://github.com/atilaneves/reggae#why), not just with 
CMake. My main concern is that if we create a brand new build 
tool, years later it might turn out that other existing tool got 
wide adoption for D so this project become abandoned and all 
efforts are thrown away.


More information about the Digitalmars-d-announce mailing list