You are not logged in.

#1 2022-04-02 19:06:17

levi
Moderator
From: Yorkshire, UK
Registered: 2018-06-16
Posts: 1,197

Now you can build rustc using gcc!

I found this yesterday, linked from an LWN post

As you may have guessed from the title of this blog post, the GCC codegen has made enough progress to be able to compile rustc itself! That’s a huge milestone!

This sounds like it could be a very good thing for arch32 to get to grips with.


Architecture: pentium4, Testing repos: Yes, Hardware: EeePC 901+2GB RAM+OS half on the SD card.

Offline

#2 2022-04-03 14:25:41

abaumann
Administrator
From: Zurich
Registered: 2019-11-14
Posts: 985
Website

Re: Now you can build rustc using gcc!

Sounds good. Thanks for the link. :-)
But it's far from a second rust compiler. And to be fair, even standard rust can be cross-compiled to quite some architectures, I doubt gcc adds really important ones here.
The reason why we don't do it in Arch32 is lack of hands and knowhow.. :-)

Offline

#3 2022-04-03 15:50:17

levi
Moderator
From: Yorkshire, UK
Registered: 2018-06-16
Posts: 1,197

Re: Now you can build rustc using gcc!

I thought part of the problem with rust was that it needed to be built with a recent enough rust compiler to have all the features, and that was a constantly moving target.  Hence it was a problem of bootstrapping.  This way, as long as you bootstrap gcc first, you can now get rust..

But you say there are more rust compilers, so presumably as long as you can bootstrap one of them you can get to an environment to develop rust on.  Or as you say, you could cross compile rustc from x64, as long as you know how, bypassing bootstrapping altogether.

I may see if I can find the motivation to learn to build rustc myself.  Thus far my investigations into the language have not provided me with a desire to code in it myself, but if this is a way to get a more modern firefox on my system, it might be worth investigation.


Architecture: pentium4, Testing repos: Yes, Hardware: EeePC 901+2GB RAM+OS half on the SD card.

Offline

#4 2022-04-03 18:00:09

abaumann
Administrator
From: Zurich
Registered: 2019-11-14
Posts: 985
Website

Re: Now you can build rustc using gcc!

The problem is not so much rust itself, I wonder how the gcc version is dealing with all the cargo micro-dependencies.
mrustc was a valid bootstrapper for rust in C++ before.

Offline

Board footer

Powered by FluxBB