From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp12.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id mP7HCpzbMWPySAAAbAwnHQ (envelope-from ) for ; Mon, 26 Sep 2022 19:04:28 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp12.migadu.com with LMTPS id aFnPCpzbMWMQeAAAauVa8A (envelope-from ) for ; Mon, 26 Sep 2022 19:04:28 +0200 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 CB5C83FB33 for ; Mon, 26 Sep 2022 19:04:27 +0200 (CEST) Received: from localhost ([::1]:38174 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ocrWs-0003J6-OM for larch@yhetil.org; Mon, 26 Sep 2022 13:04:26 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:38586) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ocrLi-0006cU-A8 for guix-devel@gnu.org; Mon, 26 Sep 2022 12:52:54 -0400 Received: from mail-wr1-x434.google.com ([2a00:1450:4864:20::434]:41948) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1ocrLg-0002RO-If for guix-devel@gnu.org; Mon, 26 Sep 2022 12:52:53 -0400 Received: by mail-wr1-x434.google.com with SMTP id t14so11145915wrx.8 for ; Mon, 26 Sep 2022 09:52:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:references :in-reply-to:subject:to:from:from:to:cc:subject:date; bh=wYR6lbbtGF2vRRnFIp5pV89rM5W0Fl81JqHBhf+NO/4=; b=C3WECsgXLY/fiq/ZT4OcfZKPFN9VXH6Z0X/vp9pdUjpwnGEb+sDL7z4nd8n5t/YlBF H7Y/7ubxdgFY0U/HkQiD+ZEed80PnPYv5KUHa81IH9ISPxr6Mr7zQj3/sqyA9SsfRyLc irYRUseKoFHlkySHei559QVfH5NdrYHYgDUR3JnDaAx358SZ9j91h3YoTJv/A00twB0v p7ScEESzHu6DRTRMR/sg2IJXIoJvH1dyl3CbbVlFFOvKbHdajb75bj/ANDMDxmHrFJaV AgirJUYjUtQfladREe2VL7UEXCuI/7cnOi+4XUJ+Vb3EQ4ha198Bty2UysbMSxFLOkJE INPg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:references :in-reply-to:subject:to:from:x-gm-message-state:from:to:cc:subject :date; bh=wYR6lbbtGF2vRRnFIp5pV89rM5W0Fl81JqHBhf+NO/4=; b=lESMdX8ewMSpqQ8MXebOm4ONCxjHoT+WuR4iTlB0OwKtzp5hvFqYseSFQgE7SJqmRD +TNDVhjkPrlWPrPYw7OjPeO6atmaAdBsE6Nw6Wn23VhLFcSV5TOlHhLwVfuA/xewJRSl WyzZZSxLrzoaMjii/k3RGZYC5I9sYDclG2KzaCDseAgUjWwTXMxIBkUkJVL5yEF3nEbD YbLoBm6KJg5d0+I72XygiY+sOmj5qKNCYGXE7bp3YixthV1/HRQOEeVk1GceKsvj+z14 N4F4UQ30HMSftD2qnIgleg6EWp3ffezGlLlBuLeb+hA5DG1YqFBio9YkiTShrQGy8lDX 5G9w== X-Gm-Message-State: ACrzQf1PihcdELNA0l4R4h08+7gPVwNhWssdaMtWHfNFAJnU72oMcsN2 GiH5ct3NrptfEOCsRfCqlMer7M1RCKg= X-Google-Smtp-Source: AMsMyM4xoD3g34utUX2LNMnDHvhz94/di47XvAjZKw0W6VNPInZ+PhLX23Wq475Z4hnViR0pUZjaCA== X-Received: by 2002:a5d:6708:0:b0:226:ea99:5bce with SMTP id o8-20020a5d6708000000b00226ea995bcemr14380638wru.37.1664211170294; Mon, 26 Sep 2022 09:52:50 -0700 (PDT) Received: from pfiuh07 ([193.48.40.241]) by smtp.gmail.com with ESMTPSA id r21-20020a05600c425500b003b49aa8083esm11105502wmm.42.2022.09.26.09.52.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 26 Sep 2022 09:52:49 -0700 (PDT) From: zimoun To: =?utf-8?B?TcOhamEgVG9tw6HFoWVr?= , guix-devel@gnu.org Subject: Re: Proposal: A new build-system API In-Reply-To: <87zgemfs1e.fsf@disroot.org> References: <87zgemfs1e.fsf@disroot.org> Date: Mon, 26 Sep 2022 12:49:02 +0200 Message-ID: <87h70ucswx.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Received-SPF: pass client-ip=2a00:1450:4864:20::434; envelope-from=zimon.toutoune@gmail.com; helo=mail-wr1-x434.google.com X-Spam_score_int: -5 X-Spam_score: -0.6 X-Spam_bar: / X-Spam_report: (-0.6 / 5.0 requ) BAYES_00=-1.9, DATE_IN_PAST_06_12=1.543, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: guix-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list 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+larch=yhetil.org@gnu.org Sender: "Guix-devel" X-Migadu-Flow: FLOW_IN X-Migadu-To: larch@yhetil.org X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1664211867; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to: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=wYR6lbbtGF2vRRnFIp5pV89rM5W0Fl81JqHBhf+NO/4=; b=lpgGayEqzh8KgPA0bvg5MwDfNpx/DLxHuCBlEVD2CPphQu6dxdrgoCuDVcIJxKKEhNwgx6 ApG3blv8jQcI+RIqRIIa6nmPun5kDthj2VfuuwX0wbOaEbzgh5ohLiCXudv9H7IjB61uQb YIYJFU3pfFdY9yPT1GZ2aCqRolwKBfh03GYgWaGlMBBHdlickgGm2uDfW1SlaYoqVeqgnN UEDNdm827x32j5d9tJ14Gfb3K6yUic+DX/QSpVg2HmrRnbG8QBxPV/6f5Yy0Cqcyf64uaI I3oUUEPODVG2oWxyBj5Ywx4w0pxwgBzV6v4G1E8NSSO8fRT+K7I5XvkJvEtJEA== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1664211867; a=rsa-sha256; cv=none; b=ne/auS3qcKvsu80B0Ly7qy8uLTuxkfA/8wjCkkfCKT+68iIlkinInhqFUQHcNi/xmuM5Bi zxglBjxqZ/XE/MbWX81AE4Sc8uZViOBmPpfEn2BZkrkzgco+pcFHGtxpLakmaVrxR88sMV kKEjytCodOPZepRUnVkZPMtPAFiay/Y+Sg1u7rFMcMp2JpM9qF8vIW+vIbKtFBVtvi7fu9 W1WQ7xjemxWQCMtNoPCuw4j/rTcU+HcgwX86ikkBcD+2VpPLfMrhyWbMHBX4bjMtZpz3Cc sWSKCHo33U4SGW3GtyuN1VIM2JwFBnGTEn9bVtuZzSHhKrI9uim814Kqy7bJWQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=C3WECsgX; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (aspmx1.migadu.com: domain of "guix-devel-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-devel-bounces+larch=yhetil.org@gnu.org" X-Migadu-Spam-Score: -2.35 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=C3WECsgX; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (aspmx1.migadu.com: domain of "guix-devel-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-devel-bounces+larch=yhetil.org@gnu.org" X-Migadu-Queue-Id: CB5C83FB33 X-Spam-Score: -2.35 X-Migadu-Scanner: scn1.migadu.com X-TUID: fyHPL46RqVpv Hi, Thanks for your comments. On lun., 26 sept. 2022 at 10:39, M=C3=A1ja Tom=C3=A1=C5=A1ek wrote: > (package > ... > (inputs list-of-inputs) > (build-system some-build-system) > (arguments (list-of-quoted #:key value)) > ... > ) [...] > (package > ... > (inputs list-of-inputs) > (build-system > (some-build-system > (phases new-list-of-phases) > (strip-binaries? #f))) > ... > ) Hum, from the surface, your proposal is to just move the arguments. Currently, =E2=80=99arguments=E2=80=99 are related to =E2=80=99build-system= =E2=80=99 =E2=80=93 therefore, I do not the difference between your proposal and the current situation. However, this=E2=80=A6 > (define-build-system some-build-system > (inherit gnu-build-system) > (name 'some) > (description "Some build system") > (phases %standard-phases) > (strip-binaries? #t) > ... > (builder (thunked) > (build-system->builder this-build-system)) > ) > > The build-system->builder method would generate the build, with > arguments properly adjusted, records translated into keyword arguments, > for a standard build system, the alternative, > would be to provide a (lambda (build-system) > some-code-that-returns-derivation). > > The current system is good, but when you need to write your own build > system, you needlessly need to write thins like ungexping arguments, > running gexp->derivation, which is really the system by which the guix > daemon operates, but which could really be abstracted away from the > build system developer. The code writing for a complete build system is r= epetetive > and complicated. =E2=80=A6is something different. Yeah, maybe some glue helpers could ease = the creation of new build-system. Nevertheless, please note that a build-system somehow needs some plumbing and I am not convinced that it would be doable to define a new build-system without diving in some G-exp here or there. I agree that the composition of existing bricks is not always straightforward and it could be improved, eventually. :-) Cheers, simon