I think it is kind of annoying that a lot of other programming languages support HaikuOS, but Rust doesn't. Also, it feels wrong that Rust supports a bunch of niche CPU architectures, but doesn't support things like HaikuOS! I have never made a compiler, but I think it shouldn't be too hard to get HaikuOS support, considering HaikuOS works like a lot of other UNIX-like operating systems.
HaikuOS is already a tier 3 target: Platform Support - The rustc book x86_64-unknown-haiku
and i686-unknown-haiku
The Haiku website has some blog posts ranging from 2015 to 2020 that shows that people have been working on running Rust on Haiku for quite some time (or at least one person, Niels Sascha Reedijk). Haiku-rs appears to be missing some APIs (see this), but development has stalled, and the last release was in 2020.
Rustup only supports tier 2 targets which makes Rust development on Haiku more difficult (it's a tier 3 target). I guess that this status quo can only improve if there's enough people putting in effort into maintaining the Haiku target. I can't find on whether rust-analyzer runs on Haiku, but if not, that's another hurdle to developing applications (my thinking is that Haiku developers may want to run Haiku on the machines they use for programming, and if the programming tools of a language don't support the OS they will look elsewhere)
I can't find many Rust applications written specifically for Haiku (maybe this one?), nor learning materials, or anything that offers an on-ramp for new programmers. Maybe the best way to help the story for Rust in Haiku is to help to build an ecosystem of crates and applications to support it.
I'm not familiar with HaikuOS, but it appears to me that they distribute Rust through their own package management system.
I'm not in a position to verify that it works, but their rust_bin
package definition claims to provide rust-analyzer
.
Oh, that's nice! I'm not familiar with Haiku also, so I'm just speaking generalities here.
Anyway I feel like rustup support is really important regardless. This package provides just a specific version of the compiler (1.69.0 at this time being - while the latest stable is 1.71.1) and depending on the project you're working on you may need the latest nightly or a pinned nightly.
Haiku's rust_bin
package, on the other hand, is likely good enough for compiling every other Rust program distributed by HaikuPorts itself, such as ripgrep. Generally speaking, that's how this is done on most Linux distros (and I guess on BSDs too): the distro-provided compiler is used mainly to compile distro packages, but it's more convenient to develop new software with rustup-provided compilers.
This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.