Reputation: 2983
I did read the Wiki, and noticed how one is required to have dmd
installed to build dmd
... Which I find a bit confusing? But okay.
Is there actually a way to build the D language compiler without having a D compiler preinstalled (excluding downloading one)?
Upvotes: 1
Views: 124
Reputation: 25605
Yeah, you can, just it is a long process: you'd have to build one of the old versions of the D compiler that was written in C++, then use it to build the newer versions in D, and possibly repeat until you get up to the newest version.
You can also build the gdc compiler, which is still in C++, but it also isn't the newest version so you probably have a couple update loops there too.
This process is called "bootstrapping". It isn't unusual; every compiler needed to be compiled at some point and that needed a compiler.
Upvotes: 4