From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id AHQ5FhPcw18TawAA0tVLHw (envelope-from ) for ; Sun, 29 Nov 2020 17:36:19 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2 with LMTPS id MBANEhPcw1/4HQAAB5/wlQ (envelope-from ) for ; Sun, 29 Nov 2020 17:36:19 +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 E91AF940363 for ; Sun, 29 Nov 2020 17:36:18 +0000 (UTC) Received: from localhost ([::1]:42182 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kjQcT-0002GX-PM for larch@yhetil.org; Sun, 29 Nov 2020 12:36:17 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:48704) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kjQcG-0002Fv-Bn for guix-patches@gnu.org; Sun, 29 Nov 2020 12:36:04 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:40919) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kjQcG-0008EP-4x for guix-patches@gnu.org; Sun, 29 Nov 2020 12:36:04 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kjQcG-0003ml-23 for guix-patches@gnu.org; Sun, 29 Nov 2020 12:36:04 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#44926] [PATCH v2 05/15] gnu: dart.scm: Add helper function. Resent-From: nixo Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sun, 29 Nov 2020 17:36:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44926 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: To: 44926@debbugs.gnu.org Cc: nixo Received: via spool by 44926-submit@debbugs.gnu.org id=B44926.160667135414464 (code B ref 44926); Sun, 29 Nov 2020 17:36:03 +0000 Received: (at 44926) by debbugs.gnu.org; 29 Nov 2020 17:35:54 +0000 Received: from localhost ([127.0.0.1]:52450 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kjQc5-0003l8-Nk for submit@debbugs.gnu.org; Sun, 29 Nov 2020 12:35:53 -0500 Received: from mail-wr1-f47.google.com ([209.85.221.47]:43578) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kjQc2-0003kO-JZ for 44926@debbugs.gnu.org; Sun, 29 Nov 2020 12:35:50 -0500 Received: by mail-wr1-f47.google.com with SMTP id s8so12002554wrw.10 for <44926@debbugs.gnu.org>; Sun, 29 Nov 2020 09:35:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=RCVr64RNDK/9njg8ek25tmuv9brB4FmCCJqderdm6Ck=; b=hdjCG1ornRTRZG51cnoHbl6F9h4qMDsv+xbL8XaERXzfcu3jsDaK2XsD1xjPTHqyCe gTXi+3WPA+ZxaWbhLgq+Sn6CRNfHCApmZOjqhyfyICc8oTFqA22SGZ+KeFA+DN4yyvkv EEiWFTT3LacGNVGmkG5AUbgE/qRd7MH//jBVbNdH1dt7jskXECSNAFjLa156BeGZRHyF fK15dqHl2MkEum3KW9Dac2TDlM/u8ubsi6lNyxATCKWki0IQzLIQ2D7klTJ6J5Ra5jQd ySxjBg22L0QmntYI9xsl0q009b40TC+TteSx+HMJk0BucrHfIonBPbleNpDu2mw3VQdA PoTA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=RCVr64RNDK/9njg8ek25tmuv9brB4FmCCJqderdm6Ck=; b=XJUpJPpWObd0sOKJ1rnA0UsUrVWQJ/nC8xGVdCnXt5MvF42VhVIubxB0O70D8aquWe VeveqknJ6q8/Ec741OaX00wNGRtZ9uhBd/03mhbbY09P5pbHseJa2+vvYP/EKviUgKrk /4uh2RuSOhuM2vsA9z1SSImV1Jdprlvwc3qlhbHXO8z8zWswMBJKQ50cA3GMCrgs9/4A DPBIXNYZgpeIdE+Kx571GEPSARHkkHJlJzjPEVTcZQBFCYcL8xQJ9Fr7kk8zmcfVFsZy F0y1zHpINJZgN9txlD1W/mxxh/IM6rLT57t95EDSQG29ySv+FGCDGmbs7XG8QM1fzgVW X4MA== X-Gm-Message-State: AOAM531BLbqCZpyUr/XU8nYKFrOtKVIlNVpfo/5a5y8VO35lX8q+V65U tAZM0brjUhDA5AV+CWDeioqbO+FIHic= X-Google-Smtp-Source: ABdhPJwe26RE+O66U6YboFvSRGK3JCAdJkvsn4yY/1Dsaerq+q+dj0JgXfUNaOlJTm/GVjC0JsA9aQ== X-Received: by 2002:a5d:428b:: with SMTP id k11mr23682345wrq.166.1606671344870; Sun, 29 Nov 2020 09:35:44 -0800 (PST) Received: from localhost.localdomain (host-79-54-131-134.retail.telecomitalia.it. [79.54.131.134]) by smtp.gmail.com with ESMTPSA id c9sm22613231wrp.73.2020.11.29.09.35.44 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 29 Nov 2020 09:35:44 -0800 (PST) From: nixo X-Google-Original-From: nixo Date: Sun, 29 Nov 2020 18:34:04 +0100 Message-Id: <20201129173414.8984-5-nicolo@nixo.xyz> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20201129173414.8984-1-nicolo@nixo.xyz> References: <20201129173414.8984-1-nicolo@nixo.xyz> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-Spam-Score: -1.0 (-) 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" X-Migadu-Flow: FLOW_IN X-Migadu-Spam-Score: 2.82 X-Scanner: ns3122888.ip-94-23-21.eu Authentication-Results: aspmx1.migadu.com; dkim=fail (headers rsa verify failed) header.d=gmail.com header.s=20161025 header.b=hdjCG1or; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-TUID: edpMDc6sjvSI * gnu/packages/dart.scm (replace-inputs): New function. --- gnu/packages/dart.scm | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/gnu/packages/dart.scm b/gnu/packages/dart.scm index c2463a676c..20da998b49 100644 --- a/gnu/packages/dart.scm +++ b/gnu/packages/dart.scm @@ -22,6 +22,9 @@ #:use-module (guix git-download) #:use-module (guix packages) #:use-module (guix utils) + #:use-module (ice-9 match) + #:use-module (srfi srfi-1) + #:use-module ((guix build utils) #:select (alist-replace)) #:use-module (gnu packages) #:use-module (gnu packages build-tools) #:use-module (gnu packages gcc) @@ -487,3 +490,12 @@ (native-inputs (cons `("dart" ,dart-2.0.0-dev.8.0) (package-native-inputs dart-2.0.0-dev.8.0))))) + +(define (replace-inputs pkg inputs) + "Replace multiple inputs at once. `PKG' is the source package and +`INPUTS' the list of replacements." + (fold (lambda (pkg inputs) + (match-let (((name pkg) pkg)) + (alist-replace name (list pkg) inputs))) + (package-inputs pkg) + inputs)) -- 2.29.2