From mboxrd@z Thu Jan 1 00:00:00 1970 From: Danny Milosavljevic Subject: Re: the importance of rust-build-system [Fwd: [tor-dev] Tor in a safer language: Network team update from Amsterdam] Date: Mon, 3 Apr 2017 00:35:24 +0200 Message-ID: <20170403003524.63b96e32@scratchpost.org> References: <20170401075841.242czleuqvibqmjf@abyayala> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:38547) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cuo5z-00062T-HN for guix-devel@gnu.org; Sun, 02 Apr 2017 18:35:40 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cuo5w-0000qU-6n for guix-devel@gnu.org; Sun, 02 Apr 2017 18:35:39 -0400 Received: from dd1012.kasserver.com ([85.13.128.8]:39782) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1cuo5v-0000pl-UG for guix-devel@gnu.org; Sun, 02 Apr 2017 18:35:36 -0400 In-Reply-To: <20170401075841.242czleuqvibqmjf@abyayala> List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: ng0 Cc: guix-devel@gnu.org Hi ng0, On Sat, 1 Apr 2017 07:58:41 +0000 ng0 wrote: > Danny, could you list what's left for completion? Is it just circular > dependencies? Very little is missing: - Rustc and cargo should be disentangled. Right now they have to be updated in lockstep. - Rust has a new optional maker (instead of makefiles) called rustbuild; for some reason I didn't get it to work. Future versions will drop the makefiles, so we have to get it to work eventually. - Eventually we could try to bootstrap a Rust compiler from the original ocaml sources. I'm trying to do that now but it's still broken. It would be fine to make it memory-safe by just not freeing anything ever - since it would only be used to compile the Rust compiler. - Earlier we had an heuristic in that if there's a Cargo.lock file present we assume that it's an application, and if there isn't one we assume that it's a library. Not sure how safe that heuristic is. What's the official way to find out what it is? - There's a design limitation in that our rust build system doesn't API support version ranges but cargo does. If multiple libraries depend on the same library with differing API version ranges, cargo uses an version range intersection algorithm in order to find out which implementation version to use. We don't do that - although we do use cargo, so it will fail in that case (and not do something invalid silently). Note that Rust itself makes a distinction between stable features that are guaranteed to stay and stay the same in the future and unstable features that don't. Many Rust crates use unstable features, among them very basic crates. That makes us unable to use them, and rightfully so. Other than that I've got a big number of (unpolished) Rust packages that do work. > days. I hope you don't mind if I list you as a go-to person for getting > involved in upstream (Guix) to fix up the rust-build-system. Okay.