From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id oDqtNAVTtmArfQAAgWs5BA (envelope-from ) for ; Tue, 01 Jun 2021 17:32:21 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id GGJMLwVTtmAZBgAA1q6Kng (envelope-from ) for ; Tue, 01 Jun 2021 15:32:21 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id ECDFB1BDE4 for ; Tue, 1 Jun 2021 17:32:20 +0200 (CEST) Received: from localhost ([::1]:49908 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lo6NP-0002N5-Bw for larch@yhetil.org; Tue, 01 Jun 2021 11:32:19 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:41960) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lo6Ds-0007Dc-5A for guix-devel@gnu.org; Tue, 01 Jun 2021 11:22:28 -0400 Received: from mailrelay.tugraz.at ([129.27.2.202]:7727) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lo6Dn-0007xM-Kw for guix-devel@gnu.org; Tue, 01 Jun 2021 11:22:27 -0400 Received: from nijino.local (62-116-34-49.adsl.highway.telekom.at [62.116.34.49]) by mailrelay.tugraz.at (Postfix) with ESMTPSA id 4FvbVx0Pq8z3x6y; Tue, 1 Jun 2021 17:22:16 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tugraz.at; s=mailrelay; t=1622560937; bh=tzh3zI/81bImgZWgLQ0zbpe8/14ne7X/GDXYRf+x1B8=; h=Subject:From:To:Cc:Date:In-Reply-To:References; b=SQsSZ2HwN7jHSrFbA8l7+l7OjyDxYTKAscXXA7T1/efsg4pobBRcd6tKHMI4DDQEP /cg5JD/BLwCUVhskdFzppY5/JOyxynZNWJYfrwXG11fCD2aTMUt9l7+9t7BwQ6vGgb R4dQf2k+N5FdU2fRCZuRg3J057ZBfL+8uUslgxzM= Message-ID: <0c426aa1977266992380948480b3fd9dddc7a44b.camel@student.tugraz.at> Subject: Re: Idea: a meta language for (language) build systems - npm, Racket, Rust cargo From: Leo Prikler To: randomlooser@riseup.net, Pjotr Prins Date: Tue, 01 Jun 2021 17:22:15 +0200 In-Reply-To: <603e88c833f7160b3010a1c5bedceff4fd25491c.camel@riseup.net> References: <20210530083847.o5ej63obqnzpwnbd@thebird.nl> <20210531174748.mhaelcqwmo7degfc@thebird.nl> <449a0cd683c9f4ebb5c60b4b25decb4536f5b1d8.camel@student.tugraz.at> <9c00c64507c3eec46bff9ef6de754c01666adbfa.camel@riseup.net> <2479e29942cf0420e2205c274fbf90942c9c72b8.camel@student.tugraz.at> <603e88c833f7160b3010a1c5bedceff4fd25491c.camel@riseup.net> Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.34.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-TUG-Backscatter-control: bt4lQm5Tva3SBgCuw0EnZw X-Spam-Scanner: SpamAssassin 3.003001 X-Spam-Score-relay: -1.9 X-Scanned-By: MIMEDefang 2.74 on 129.27.10.117 Received-SPF: pass client-ip=129.27.2.202; envelope-from=leo.prikler@student.tugraz.at; helo=mailrelay.tugraz.at X-Spam_score_int: -42 X-Spam_score: -4.3 X-Spam_bar: ---- X-Spam_report: (-4.3 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: guix-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: guix-devel Errors-To: guix-devel-bounces+larch=yhetil.org@gnu.org Sender: "Guix-devel" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1622561541; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=tzh3zI/81bImgZWgLQ0zbpe8/14ne7X/GDXYRf+x1B8=; b=kdaYobNcIMyj1i+CFxtRfKka4d8U3neech+cYuxnic9jkQigoOTwq43sstrfUVQqiK3a8n hjyla5h2nx8DxDk9st0dfUK5Qk/1fbQqDwyt5C7wGgVX1oLqL139bl2Id4uzEUO72jdkEL Q5v49gZGBBmOwqAwB6xFLw5a3rVep9EELikyd0wBQL20J76lCCfvcymNzYmuaGMdWm85hH ihui8Ozsyj0218Pfcc39iKYRkNmELpnGpe1lcs2IEze+c2Kxq8xtJWRwTqAw849m824m0F zRidGg5/tMXYY3iHYle791MJU0v8RwSgi9eHSZkpbYDMNA+68M8T9AEAk3waKQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1622561541; a=rsa-sha256; cv=none; b=WPb91bgTuTH6KdazvKtkpnvaoqs82zjaiV6E+LUrnNiKLPQFYfOf+SdTHI5W0NCadIA1BV MNVsCcqk3YA2LNFZX+ENT+G4FOCpZ279OYLDCjt+V4w62q9YZ3Q4KytjJQnt/XTNSZ7fFs 5+159t4Bm2vXjlUozjFZRA9eecph5cGVunXiaMq8oyWIjII669jhxVSji5qd4h0zMi6ISw QiJs5raVY4o9FJPJ17+eZuH6fngfpxqJzrY+J/kTgdnfQV0+zL/y6HvQ6MJvBox2ibZHd3 cxlHiAvn5KSicE7LH/MBaZpyxllPSx8cdCHoh0YO+Q4+o3Hym/u+Nk8UCq73uQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=tugraz.at header.s=mailrelay header.b=SQsSZ2Hw; dmarc=pass (policy=none) header.from=student.tugraz.at; spf=pass (aspmx1.migadu.com: domain of guix-devel-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-devel-bounces@gnu.org X-Migadu-Spam-Score: -3.13 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=tugraz.at header.s=mailrelay header.b=SQsSZ2Hw; dmarc=pass (policy=none) header.from=student.tugraz.at; spf=pass (aspmx1.migadu.com: domain of guix-devel-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-devel-bounces@gnu.org X-Migadu-Queue-Id: ECDFB1BDE4 X-Spam-Score: -3.13 X-Migadu-Scanner: scn1.migadu.com X-TUID: Hm4DDlsqfFeC Am Dienstag, den 01.06.2021, 13:28 +0200 schrieb Adriano Peluso: > Il giorno mar, 01/06/2021 alle 13.03 +0200, Leo Prikler ha scritto: > > Am Dienstag, den 01.06.2021, 12:52 +0200 schrieb Adriano Peluso: > > > Il giorno mar, 01/06/2021 alle 11.11 +0200, Leo Prikler ha > > > scritto: > > > > > [...] > > > Probably the Fractal package will depend on some others, so it's > > > gonna be a collection 🤷️ > > > > > > Doesn't that happen already for traditional tarballs ? > > We don't stuff tarball collections into packages. We stuff inputs > > into > > packages and one input equals one tarball. > > > > > > We already drop all > > > > vendored dependencies from tarballs, that aren't created by > > > > Rust > > > > et > > > > al., this does the exact opposite. > > > > > > I'm not sure I understand > > > > > > This does the opposite ? > > > > > > How so ? > > Let's assume we form this sexp-pack and use it as input to some > > package. What happens? > > we wouldn't use a sexp-pack as an input to a guix package in the same > way as, as you noticed, we don't feed tarballs as inputs to guix > packages > > A Guix package doesn't depend on some tarballs. It depends on some > other Guix packages That's only half-true. You can stuff origins into inputs and people do that. > In the same way, a Guix package wouldn't depend on a sexp-pack. > > You can think of sexp-pack as an alternative format to tarball > > With, maybe, some more metadata Tarball + metadata is a standard of package management.[1] > For example, a sexp-pack could contain a hash of itself and hashes of > other _sexp-packs_ it depends on > > Similarly to how, for example, python packages on pypi express > dependecies on other packages in pypi > > The difference is that, as far as I understand, python packages > (those in pypi, not those in Guix) express dependencies in a somewhat > loose way > > Guix packages are stricter > > sexp-packs could be stricter too, bringing part of the data > reconciliation outside of Guix I don't see the benefit here. At best, sexp-packs are actual packages, at worst they're closer to origins. When bringing "dependencies" into the mix, one might want to implement them as packages with near-empty build, that have propagated-inputs. I'm really struggling to see the use case here. Packages are useful abstractions to both developers and maintainers – the former need not really care about the build step if all they want is an environment. > A Guix importer could recursively import sexp-packs the same way the > python importer... You do know we can already import packages from JSON, right? > I'm assuming that a Rust package can be built in a sane way, with > dependencies properly sorted out. > > I know that's possible for javascript packages, I'm not sure about > Rust The mathematical term you're seeking is "conjecture". > Such a data/packages collection could be used by mainstream linux > distributions too, as far as I understand 🤷️ Guess what, distros already use it. Not the hypothetical data collection you want to establish, the ones that actually exist as published by pip, cpan, npm, cargo… Whatever fancy intermediate format you want to think up, the fact that this won't make anyone's lives easier follows from the data processing inequality. In other words, how you decide to lay out that data *does not matter* as long as it can somehow be parsed (and remember that your own tools will also need to parse it) and you don't omit anything – at best importing data from your layout will be as good as importing it from the original source. In order to improve this situation, you would either need to improve the tools in question (e.g. make it so that cargo actually produces shared libraries) or replace them with technologies, that have the properties we want (perhaps cargo by ninja). If you furthermore want a ubiquitous solution, guess what, that'd be Guix itself. So you're looking for something that's either similar to Guix or more accommodating to Guix, that will get accepted by some language community. Note, that you can't really sell that solution on the same grounds as Guix – as otherwise Guix would already be used instead – and you will also have to compete against whatever technology already exists, e.g. cargo or npm. W.r.t. npm, I think an npm importer would already be a great improvement. IIUC the biggest problem with npm is the sheer number of inputs. We might also try to deduplicate dependencies, but alas, let's not get ahead of ourselves. Regards, Leo [1] https://xkcd.com/927/