From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp10.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id cGdoJGxlj2P9QgAAbAwnHQ (envelope-from ) for ; Tue, 06 Dec 2022 16:53:16 +0100 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp10.migadu.com with LMTPS id AAW5I2xlj2PgEAAAG6o9tA (envelope-from ) for ; Tue, 06 Dec 2022 16:53:16 +0100 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 102DA2F483 for ; Tue, 6 Dec 2022 16:53:16 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1p2aFl-0004P0-Dl; Tue, 06 Dec 2022 10:53:06 -0500 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 1p2aFi-0004Oq-VD for guix-patches@gnu.org; Tue, 06 Dec 2022 10:53:02 -0500 Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1p2aFi-0005Wd-Fq for guix-patches@gnu.org; Tue, 06 Dec 2022 10:53:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1p2aFh-0005BG-T4 for guix-patches@gnu.org; Tue, 06 Dec 2022 10:53:01 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#59859] [PATCH] gnu: rasdaemon: Add missing inputs and rewrite using G-Exps. Resent-From: mirai@makinata.eu Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 06 Dec 2022 15:53:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 59859 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 59859@debbugs.gnu.org Cc: Bruno Victal X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.167034193819899 (code B ref -1); Tue, 06 Dec 2022 15:53:01 +0000 Received: (at submit) by debbugs.gnu.org; 6 Dec 2022 15:52:18 +0000 Received: from localhost ([127.0.0.1]:43664 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p2aF0-0005Ar-Au for submit@debbugs.gnu.org; Tue, 06 Dec 2022 10:52:18 -0500 Received: from lists.gnu.org ([209.51.188.17]:56572) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p2aEu-0005Ak-Nt for submit@debbugs.gnu.org; Tue, 06 Dec 2022 10:52:16 -0500 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 1p2aEu-00049a-8W for guix-patches@gnu.org; Tue, 06 Dec 2022 10:52:12 -0500 Received: from smtpmciv5.myservices.hosting ([185.26.107.241]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1p2aEp-0005PK-Mr for guix-patches@gnu.org; Tue, 06 Dec 2022 10:52:11 -0500 Received: from mail1.netim.hosting (unknown [185.26.106.172]) by smtpmciv5.myservices.hosting (Postfix) with ESMTP id A606520D03 for ; Tue, 6 Dec 2022 16:51:53 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by mail1.netim.hosting (Postfix) with ESMTP id 5810180096; Tue, 6 Dec 2022 16:51:53 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at mail1.netim.hosting Received: from mail1.netim.hosting ([127.0.0.1]) by localhost (mail1-1.netim.hosting [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id ScfkoB5gSmW9; Tue, 6 Dec 2022 16:51:50 +0100 (CET) Received: from guix-nuc.home.arpa (bl12-93-156.dsl.telepac.pt [85.245.93.156]) (Authenticated sender: lumen@makinata.eu) by mail1.netim.hosting (Postfix) with ESMTPSA id 095BF80093; Tue, 6 Dec 2022 16:51:49 +0100 (CET) From: mirai@makinata.eu Date: Tue, 6 Dec 2022 15:51:34 +0000 Message-Id: X-Mailer: git-send-email 2.38.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Received-SPF: pass client-ip=185.26.107.241; envelope-from=mirai@makinata.eu; helo=smtpmciv5.myservices.hosting X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action 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 ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1670341996; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding:resent-cc: resent-from:resent-sender:resent-message-id:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=BXFUzy/11o2IPyu62MQDUS3hpVfD7JETl+acxxMjPh4=; b=kt9zHVjBWZ6+FYJz8MYv1nilQvrgPn4zBwIzR4hUg8TAYJ3gd+79WiM7q/71zplsNu2liu 6OrmgyJMWRnlqCH0BfOm0bIHTl26o9eNa4YMB20PaUBSOIlGbRmsrLCBxuff7STpLmXkDU yzIML5Vi/pcvYiaNUbalMgkn3QSDXRWGIUGQMWylGXg6opzZS59fXYS96KqmpI0SuCsJI6 7VaUbT+PvcbxGaF+O+/6M3ZeYyt8heKgbE/IsTnhu1rqIf0sEcEFkGjL08uucGanLMMcXZ gdsJZS0zbAjWeUksjt0A6tYSFx/5xCYzCzgGMtj7yHeU/XbbDLYqdRFSWNvWLw== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1670341996; a=rsa-sha256; cv=none; b=epNZQWIIszl0dgtLdQQcmqDuH02RkBDJ8oGRhk3h7sB4+TMTr+GSZbXYLK8McyllBOf4ib GLXOadcjy5lpJEb522KLLj4XR7U5l/4il0JfnyC2wbkMVI+Jd+cmPL5jln+6Bdof4NeQ8P SeOFPxjrjBZ5wZHzprXCm86hSVyy8wLXR8rxEVvM7Ke2mkClHDHaOBAVbxZswKH8A61788 Sw3RT7K92FK3SGxXVOZvdFk8gSjdghBqOEHJ7Gxtgam9+usMh5lTsTTgYt5csuLhywxjZO wZ4WFYm6/msnVeD8gKVgIaq+vgSRlwys+d5dHmLpkqGvvGalOhIcn+pR0mMMlQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=none; dmarc=none; 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" X-Migadu-Spam-Score: -1.66 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=none; 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" X-Migadu-Queue-Id: 102DA2F483 X-Spam-Score: -1.66 X-Migadu-Scanner: scn1.migadu.com X-TUID: gvK/rCfA4A3Q From: Bruno Victal * gnu/packages/linux.scm (rasdaemon)[arguments]: Rewrite using G-Expressions and add missing inputs. --- gnu/packages/linux.scm | 50 +++++++++++++++++++++++++----------------- 1 file changed, 30 insertions(+), 20 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 49e90a9ba6..2d3d50c5e1 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -9472,27 +9472,37 @@ (define-public rasdaemon (sha256 (base32 "0r0339mg4rc12p63iiq2kwdqn1zjakyiv014i2a2l9s8v5rjik41")))) (native-inputs (list autoconf automake libtool)) - (inputs (list perl sqlite)) + (inputs (list perl perl-dbd-sqlite sqlite dmidecode kmod)) (arguments - `(#:configure-flags - (list "--enable-all" - ;; Don't install unused /etc/sysconfig/rasdaemon environment file. - "--with-sysconfdefdir=." - "--localstatedir=/var") - #:phases - (modify-phases %standard-phases - (add-before 'configure 'munge-autotools - (lambda _ - ;; For some reason upstream forces sysconfdir=/etc. This results - ;; in EPERM during the install phase. Removing the offending - ;; line lets sysconfdir correctly pick up DESTDIR. - (substitute* "configure.ac" - (("^test .* sysconfdir=/etc\n$") "")) - ;; Upstream tries to create /var/lib/rasdaemon at install time. - ;; This results in EPERM on guix. Instead, the service should - ;; create this at activation time. - (substitute* "Makefile.am" - (("^\\s*\\$\\(install_sh\\) -d .*@RASSTATEDIR@.*$") ""))))))) + (list + #:configure-flags + #~(list "--enable-all" + ;; Don't install unused /etc/sysconfig/rasdaemon environment file. + "--with-sysconfdefdir=." + "--localstatedir=/var") + #:phases + #~(modify-phases %standard-phases + (add-before 'configure 'munge-autotools + (lambda _ + ;; For some reason upstream forces sysconfdir=/etc. This results + ;; in EPERM during the install phase. Removing the offending + ;; line lets sysconfdir correctly pick up DESTDIR. + (substitute* "configure.ac" + (("^test .* sysconfdir=/etc\n$") "")) + ;; Upstream tries to create /var/lib/rasdaemon at install time. + ;; This results in EPERM on guix. Instead, the service should + ;; create this at activation time. + (substitute* "Makefile.am" + (("^\\s*\\$\\(install_sh\\) -d .*@RASSTATEDIR@.*$") "")))) + (add-after 'install 'fix-dmidecode-and-modprobe + (lambda _ + (substitute* (string-append #$output "/sbin/ras-mc-ctl") + (("find_prog \\(\"dmidecode\"\\).*$") (format #f "~s;~%" (string-append #$dmidecode "/sbin/dmidecode"))) + (("find_prog \\(\"modprobe\"\\).*$") (format #f "~s;~%" (string-append #$kmod "/bin/modprobe")))))) + (add-after 'wrap 'wrap-rasdaemon + (lambda _ + (wrap-program (string-append #$output "/sbin/ras-mc-ctl") + `("PERL5LIB" ":" prefix ,(string-split (getenv "PERL5LIB") #\:)))))))) (build-system gnu-build-system) (home-page "https://github.com/mchehab/rasdaemon") (synopsis "Platform Reliability, Availability, and Serviceability tools") base-commit: b94724e8b2102be0fe9d19e9dfe44d6f7101bd4b -- 2.38.1