News for hackers. Stuff that matters.
Re:Why you should, actually, rewrite some of it in Rust by steveklabnik on Wednesday July 12, 2017 @01:06PM (#14754283)
> As far as I can tell there's no major package manager accepting or even ready to accept programs written in Rust yet. Am I misinformed?

At least Debian, Fedora, Arch, and Gentoo have rustc and cargo in their repositories. Oh and Alpine, recently. FreeBSD (IIRC) has it in ports.

In the not-too-distant future, there's a pretty important package that will require Rust: Firefox. HEAD already does today.

Re:Why you should, actually, rewrite some of it in Rust by cyphar on Wednesday July 12, 2017 @04:46PM (#14756522)
But you do realise that pressuring distributions in that way (when there are still issues with integrating cargo and crates into our existing build systems) won't result in Rust being properly supported right? There will be some hack to get Rust to work "well enough" to build Firefox, and if someone wants to start packaging more Rust stuff then all of the work would either need to be redone or started from scratch.

I'm saying this as someone who has started writing their projects in Rust and has plans to ship said projects as part of openSUSE and eventually SLES. If you cannot satisfactorily maintain a Rust package inside OBS then it's a non-starter. I imagine that many other distributions feel this way. We were burned with Ruby (and continue to be burned by it) and I doubt that anyone is going to jump on the "just auto-generate an RPM for every version of every crate we need" solution.

It's great that Firefox will have Rust code, but I'm not convinced that will make the situation better for distributions. It'll just make the packagers more stressed out.

Re:Why you should, actually, rewrite some of it in Rust by steveklabnik on Wednesday July 12, 2017 @05:01PM (#14756645)
All I can really say is, we're interested, willing, and actively working with distro maintainers on fixing their issues. It's something we care about.

It is just one of many things on our plate, though.

Re:Why you should, actually, rewrite some of it in Rust by ZoFreX on Wednesday July 12, 2017 @01:13PM (#14754356)
For Debian at least, cargo isn't even in stable yet AFAIK.

And even then, having the compiler and package manager available is a step along the way, but insufficient. Anything non-trivial depends on libraries, which with C programs are typically also packages... which for my project means I need to create 73 Debian packages to distribute my software. That's a big hurdle.

Re:Why you should, actually, rewrite some of it in Rust by steveklabnik on Wednesday July 12, 2017 @01:21PM (#14754423)
I thought it made the cutoff. I could be wrong. I was more worried about 1.15, which did get missed, ugh.

Debian has made a tool, "debcargo", to automatically turn crates from crates.io into Debian packages, so it should be "just run this tool." I have not used it myself though.

Re:Why you should, actually, rewrite some of it in Rust by ZoFreX on Wednesday July 12, 2017 @01:22PM (#14754435)
I think it's fair to say that anyone releasing software written in Rust on Debian right now has extra work to do, and is likely to be treading new ground.
Re:Why you should, actually, rewrite some of it in Rust by marcosdumay on Wednesday July 12, 2017 @02:07PM (#14754954)
Is it really harder than making autotools work?

Anyone releasing software in C, Python, Haskell, Ruby, Lisp, or whatever language has extra work to do. I don't think there's any sizeable difference between any of them.

Re:Why you should, actually, rewrite some of it in Rust by cyphar on Wednesday July 12, 2017 @04:39PM (#14756448)
The biggest problem is that distributions have their own build systems and cargo just doesn't fit in a variety of different ways (not to mention projects that pin nightly compilers).

Distributions such as Fedora and openSUSE need to have a package for everything installed on the system (and everything required to build said packages). Now take into account the you can have multiple versions of the same library in a single rust project. While you could handle all of this on paper, automating it and putting it all into every distributon's build system is a very big task.

Ruby has similar problems, NodeJS is even worse than Ruby in this respect but I believe that Rust might make this the hardest for distributions. Personally I've never liked cargo that much as a user either, but as someone who works on openSUSE and was thinking about packaging rust packages I decided against it. It's just far too difficult and I'm not convinced it's worth the effort, since it feels like people have forgotten the reason why distributions exist in the first place (to provide a cohesive experience and provide you seamless management of your software). Having a shiny new package manager for every language just makes life difficult for everyone involved.

Re:Why you should, actually, rewrite some of it in Rust by steveklabnik on Wednesday July 12, 2017 @05:02PM (#14756655)
> The biggest problem is that distributions have their own build systems and cargo just doesn't fit in a variety of different ways

Fixing that is a big focus of this year https://github.com/rust-lang/rust-roadmap/issues/12

Re:Why you should, actually, rewrite some of it in Rust by steveklabnik on Wednesday July 12, 2017 @01:28PM (#14754500)
Totally! That's far different than "no major package manager accepting or even ready to accept programs written in Rust yet", though.

Oh, I thought of something better than just the compiler: https://github.com/burntsushi/ripgrep#installation

* homebrew

* chocolatey

* arch

* gentoo

* fedora

* RHEL/CentOS

* Nix

All have at least one Rust program packaged :)

Re:Why you should, actually, rewrite some of it in Rust by ZoFreX on Wednesday July 12, 2017 @01:44PM (#14754681)
For RHEL/Centos/Fedora (the only ones there I would call "major") you have to enable a separate repo, which isn't really the same as being in the official repos.
Re:Why you should, actually, rewrite some of it in Rust by cyphar on Wednesday July 12, 2017 @04:31PM (#14756373)
Also openSUSE and SLES. Yes, we're still around and doing interesting stuff.