From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms1.migadu.com with LMTPS id WED8EHIwQmaxMQAAqHPOHw:P1 (envelope-from ) for ; Mon, 13 May 2024 17:23:30 +0200 Received: from aspmx1.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0.migadu.com with LMTPS id WED8EHIwQmaxMQAAqHPOHw (envelope-from ) for ; Mon, 13 May 2024 17:23:30 +0200 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gnu.org header.s=fencepost-gnu-org header.b=lVkeUXNx; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1715613810; 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:resent-cc: resent-from:resent-sender:resent-message-id:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=HQrLuf7teKoVJJm0lMTuMFJ8RZsRR+4dNY6faVz2HK0=; b=Sw7Acc1UZA4QI1GL/2rJ54TlvFFdRtcgwGxlVocRg4Wz4WF6Fdbn24u5dFaSDGXlwsIsWC LzjEo51LTSjVVVXUQdgAV/dF5RsB4Bp5hbpTBjrNGpjbkbIZsNwjQ9wDpr57SlTY1TYLeb BVi/YnSGogZgaM+JpBnRHTfUrdaJ6z2fiIk/8GBlHMk37wwr1yk1S8Ev+txflhQ5pxeZzE BY2y+j/pFsyg8Z+jVLiVc6RzoQSB54hCY+IqKkNv2t92eUqqftvYEZwRUWgJ0oK7ZERThh 6VnEnCoFz1ifCFSvwFyzIpZOtcFDV3/tC9pKFuDpQR1qsRXdFQpTZw2tIVqSQQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1715613810; a=rsa-sha256; cv=none; b=rbrtL1qU/w+rzC3St+N3dvkdwzJ/nQY1CF4McMYML+XVsNV/Sdh22SFxAScdJeaVy1+n3m wr3Yghbp9RUlUlztXuW6Bw/akCFtwIVYu57wepyCTKO3uOVpCLu1IstlJEoXXYCVmkSXhh iDdCN7uKL4h5L64AjjuOSP4yQA07D/6M22M9MNN4OC8LdaNw2gAJzEuz8wffVpaEPHUfyZ x0qjk1DvdckvEs2Z23V8q/2uMv7B9MbBsrMm8skv5ibwmHDPQQ7Cs5cIdGqmXmHqBudF9K g6AHX6MAAfQmas8pX3wI+zjomlw53IfwzKzzYBwXxhGXvMN4VRukRlntor3mVA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gnu.org header.s=fencepost-gnu-org header.b=lVkeUXNx; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" 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 216F0390E2 for ; Mon, 13 May 2024 17:23:30 +0200 (CEST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1s6XW3-0002mz-FQ; Mon, 13 May 2024 11:23:03 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1s6XW2-0002lh-8N for guix-patches@gnu.org; Mon, 13 May 2024 11:23:02 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1s6XW1-0004pj-Vp for guix-patches@gnu.org; Mon, 13 May 2024 11:23:01 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1s6XW2-0008O8-Ba for guix-patches@gnu.org; Mon, 13 May 2024 11:23:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#70494] [PATCH 05/23] store: build-derivations: New module. Resent-From: Ludovic =?UTF-8?Q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 13 May 2024 15:23:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 70494 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Christopher Baines Cc: Josselin Poiret , 70494@debbugs.gnu.org, Simon Tournier , Mathieu Othacehe , Tobias Geerinckx-Rice , Ricardo Wurmus , Christopher Baines Received: via spool by 70494-submit@debbugs.gnu.org id=B70494.171561376432235 (code B ref 70494); Mon, 13 May 2024 15:23:02 +0000 Received: (at 70494) by debbugs.gnu.org; 13 May 2024 15:22:44 +0000 Received: from localhost ([127.0.0.1]:33283 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1s6XVk-0008Nr-3w for submit@debbugs.gnu.org; Mon, 13 May 2024 11:22:44 -0400 Received: from eggs.gnu.org ([209.51.188.92]:55372) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1s6XVh-0008Nl-Qi for 70494@debbugs.gnu.org; Mon, 13 May 2024 11:22:42 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1s6XVa-0004kw-ED; Mon, 13 May 2024 11:22:34 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:Date:References:In-Reply-To:Subject:To: From; bh=HQrLuf7teKoVJJm0lMTuMFJ8RZsRR+4dNY6faVz2HK0=; b=lVkeUXNxOkXfN33Pbbti RzZWtFAhxFduXu/LZ9RBoD4Ho6XL2IFB+12jN/amBBwlIBqGT0HaDHYg3A6Zt1tQayOXelZ6mN5MU D/yUGZOhKhBsBAt8MrL37GSBIEU1uVHeDHZvUxngrGerqNt3kQ6Aosb+RhjpWLgEJplryReTxkDBD sy576Ai2AS0EPdFXmTKxJEsgrATbZm/RahJCZZu8DL5v1wHxQjIccibTLNBXJu/7jBKxOu6Ti9/om R6Nm4AhOjlx7cbgN++r/52ZKoT7f5Va4VvKgmHw3P8RRxoSgYBFU/A2swsMyBrinuxWmG3l9htUZf aD/cPsAeA42GgQ==; From: Ludovic =?UTF-8?Q?Court=C3=A8s?= In-Reply-To: <7fa2a7e78f0987f8794602ca3e8e2ed8dfd321e4.1713692561.git.mail@cbaines.net> (Christopher Baines's message of "Sun, 21 Apr 2024 10:42:23 +0100") References: <87bk632h36.fsf@cbaines.net> <7fa2a7e78f0987f8794602ca3e8e2ed8dfd321e4.1713692561.git.mail@cbaines.net> Date: Mon, 13 May 2024 17:22:29 +0200 Message-ID: <87h6f191oq.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: guix-patches-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US X-Migadu-Spam-Score: -2.77 X-Spam-Score: -2.77 X-Migadu-Queue-Id: 216F0390E2 X-Migadu-Scanner: mx11.migadu.com X-TUID: ClxzmiiQz7M9 Christopher Baines skribis: > From: Caleb Ristvedt > > * guix/store/build-derivations.scm (get-output-specs, builtin-download, > add-to-trie, make-search-trie, remove-from-trie!, scanning-wrapper-port, > scan-for-references, ensure-input-outputs-exist, build-derivation): New > procedures. > (builtins): New variable. > (): New record types. > * Makefile.am (STORE_MODULES): Add it. > > Co-authored-by: Christopher Baines > Change-Id: I904b75e3c58c5fb996c0c9d1ca19b2cb2beb90b6 I think you can add a copyright line for you. [...] > +(define-module (guix store build-derivations) Or just (guix store build)? > + #:use-module (guix derivations) As for (guix store), we=E2=80=99ll have to fix it eventually: daemon code s= hould not import client code. So I would move the record and low-level code to (guix store derivations). (guix derivations) would import that module. Anyway, we=E2=80=99ll discuss that separately. > + #:use-module (guix build store-copy) > + #:use-module (gnu system file-systems) It=E2=80=99s a good idea to #:autoload as much as possible, especially (gnu= =E2=80=A6) modules that may pull lots of other modules. It would be good to have tests here: maybe low-level unit tests for the reference scanner (it=E2=80=99s a fairly critical piece :-)), as well as integration tests that perform a build or something. Again maybe that can come later if it=E2=80=99s more convenient. Ludo=E2=80=99.