Things that work reliably well on my 32-bit machine.
GCC 13 works fine, but can't produce a working dynamically linked Python binary — probably has other issues so I've downgraded.
Rust up to 1.80 works, but segfaults when building certain crates, such as getrandom — probably related to newer versions of LLVM being horribly broken and LLVM12 probably works because it seems to ignore most optimisation flags.

Follow

And you can't build newer Rust using older tools — because it only supports last 3 releases of LLVM and they have cranked out quite a few of them in the past couple of years, but the worst part is those LLVM releases can only be built with GCC 13. This looks somewhat relevant: github.com/llvm/llvm-project/i
Why does everything have to depend on the latest versions and be so fucking broken? 😩

And yes, I've built too, but it fails to produce binaries even for the hello_world type of programs, I have no idea what the problem might be, but as it depends on LLVM (and even comes with LLVM 18 for bootstrapping), it could be literally anything.

Show thread

Good news is — it's possible to make work on a relatively up-to-date system, even though it's really dated: gccgo that comes with gcc 8.5.0 provides go 1.10.3… Yeah-yeah, but even this is one hell of an achievement, at least programs that only depend on the standard library work reliably.
Thanks to Adelie Linux maintainers and their set of patches: cgit.adelielinux.org/packages/

Show thread

I've also had to update libbacktrace to the one from gcc 10.5 — my system seems pro produce binaries with dwarf-5, but older libbacktrace does not support that and adding "-gdwarf-4" to CFLAGS somehow failed to fix that for me.
This go toolchain still fails to produce fully statically linked binaries as normal go toolchain does — this is probably related to libucontext in Void only exporting prefixed symbols. But that's a relatively minor problem, statically linking libgo works fine.

Show thread

@awilfox Thanks for all your patches and for keeping PowerPC alive!
Did you manage to advance any further in making newer Go work on 32-bit machines? I see that Adelie got updated with GCC 13 about 10 days ago? Does gccgo in that one get built properly? I think I've tried those patches when they were still in the experimental branch and it didn't work for me.

Show thread

@awilfox
There is also a branch with an attempt to port newer libgo to older gccgo in the Adelie tree — that one failed to build on my machine too, but my experimenting with it is somewhat hindered by the fact that complete rebuild of gcc on this MacMini takes forever😅 So I might've missed something.

Show thread

So, Zig indeed appears to be broken on Big Endian machines, even 0.12: github.com/ziglang/zig/issues/
The issue is rather old, but on the other hand, they don't have the resources of Google and even that of those who work on Rust, so hopefully there'd be a fix sooner or later.

Show thread
Oh I was talking to m0xee but wanted you included in the conversation because I like talking with you

@tyler
Turns out you can!
I'm still updating the thread: social.librem.one/@m0xee/11298
TL; DR it's REALLY old — backporting to that would take a significant effort, but it works! I've managed to get BloatFE running matively on the same PowerPC machine my Pelorma instance runs on. It has very few dependencies, but it still took me a couple of hours yesterday.
@pyrate

@pyrate
Why though? I've never used it for anything serious myself, but it looks like a nice language in its own way, not having the shortcomings of Go and not as complex as Rust — at the very least it appears to be easier to read, the code looks cleaner 😂
I don't like the reliance on LLVM and the fact that it's currently broken on PowerPC, but at least there is no Google-style "Haha, get new hardware" attitude here.

@romin
Ackshually yeah — correct! I had to deal with this older go yesterday and it appeared to be way less broken than it is today 😂
E.g. the way it handles the dependencies: just issuing "go build" and seeing it retrieve all the dependencies itself is fine and dandy, but having them saved in a particular directory locally and not depending on… 🤬 GOPROXY is preferable to me.

@romin
I've already forgotten that GOPROXY simply didn't exist then, you don't even have to do "go env -w GOPROXY=direct" — that might be related to "go env" simply not supporting the "-w" parameter in this version though 🤣

@romin
You can now! I'm not even sure when they have added it — this version doesn't support it either. A directory named "vendor" is handled in some special way, but it only seems to affect the namespace visibility and nothing else, it doesn't look for dependencies in this dir.
But you can always put everything under src/ and point GOROOT to the current directory — very straightforward!

@romin
Minor downside: you have to put local modules into src/ too — obviously (it's in the name) GO111MODULE didn't exist in this version either.

Sign in to participate in the conversation
Librem Social

Librem Social is an opt-in public network. Messages are shared under Creative Commons BY-SA 4.0 license terms. Policy.

Stay safe. Please abide by our code of conduct.

(Source code)

image/svg+xml Librem Chat image/svg+xml