this post was submitted on 29 Aug 2024
204 points (99.5% liked)

Linux

48338 readers
475 users here now

From Wikipedia, the free encyclopedia

Linux is a family of open source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991 by Linus Torvalds. Linux is typically packaged in a Linux distribution (or distro for short).

Distributions include the Linux kernel and supporting system software and libraries, many of which are provided by the GNU Project. Many Linux distributions use the word "Linux" in their name, but the Free Software Foundation uses the name GNU/Linux to emphasize the importance of GNU software, causing some controversy.

Rules

Related Communities

Community icon by Alpár-Etele Méder, licensed under CC BY 3.0

founded 5 years ago
MODERATORS
 

Even before the Bcachefs file-system driver was accepted into the mainline kernel, Debian for the past five years has offered a "bcachefs-tools" package to provide the user-space programs to this copy-on-write file-system. It was simple at first when it was simple C code but since the Bcachefs tools transitioned to Rust, it's become an unmaintainable mess for stable-minded distribution vendors. As such the bcachefs-tools package has now been orphaned by Debian.

From John Carter's blog, Orphaning bcachefs-tools in Debian:

"So, back in April the Rust dependencies for bcachefs-tools in Debian didn’t at all match the build requirements. I got some help from the Rust team who says that the common practice is to relax the dependencies of Rust software so that it builds in Debian. So errno, which needed the exact version 0.2, was relaxed so that it could build with version 0.4 in Debian, udev 0.7 was relaxed for 0.8 in Debian, memoffset from 0.8.5 to 0.6.5, paste from 1.0.11 to 1.08 and bindgen from 0.69.9 to 0.66.

I found this a bit disturbing, but it seems that some Rust people have lots of confidence that if something builds, it will run fine. And at least it did build, and the resulting binaries did work, although I’m personally still not very comfortable or confident about this approach (perhaps that might change as I learn more about Rust).

With that in mind, at this point you may wonder how any distribution could sanely package this. The problem is that they can’t. Fedora and other distributions with stable releases take a similar approach to what we’ve done in Debian, while distributions with much more relaxed policies (like Arch) include all the dependencies as they are vendored upstream."

...

With this in mind (not even considering some hostile emails that I recently received from the upstream developer or his public rants on lkml and reddit), I decided to remove bcachefs-tools from Debian completely. Although after discussing this with another DD, I was convinced to orphan it instead, which I have now done.

you are viewing a single comment's thread
view the rest of the comments
[–] solrize@lemmy.world 15 points 2 months ago (17 children)

Oh man, that isn't a good luck for Rust. What do those tools do and how much code is there anyway? If they are userspace tools, what is the benefit of writing them in Rust?

[–] unknowing8343@discuss.tchncs.de 31 points 2 months ago* (last edited 2 months ago) (11 children)

Everything is better in Rust. Faster, safer... And also the developer experience is amazing with cargo.

The problem here is not Rust, it's the humans, it seems.

The dependencies are set manually, of course, and the dev was enforcing something too strict, it seems, and that is causing headaches.

But, as the debian dude has learned... Rust programs will 99.999 % work if they can be compiled.

[–] p03locke@lemmy.dbzer0.com 5 points 2 months ago (1 children)

But, as the debian dude has learned… Rust programs will 99.999 % work if they can be compiled.

That's a dumb statement. Every tool needs unit tests. All of them!

If grep complied, but always returned nothing for every file and filter, then it's still not "working". But, hey, it compiled!

[–] LeFantome@programming.dev 3 points 2 months ago

You are not wrong of course but it does not really refute what they are saying.

Many people have had the experience with Rust that, if it builds, the behaviour is probably correct. That does not prevent logic errors but those are not kinds of bugs that relate to dependencies.

These kinds of dependency shenanigans would be totally unsafe in C but Rust seems to handle them just fine.

load more comments (9 replies)
load more comments (14 replies)