From patchwork Fri Sep 2 02:32:39 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Denis 'GNUtoo' Carikli X-Patchwork-Id: 42137 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 21B4D27BBEA; Fri, 2 Sep 2022 03:33:18 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.9 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI, SPF_HELO_PASS autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 89A9F27BBE9 for ; Fri, 2 Sep 2022 03:33:17 +0100 (BST) Received: from localhost ([::1]:48524 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oTwUe-0008Ae-K3 for patchwork@mira.cbaines.net; Thu, 01 Sep 2022 22:33:16 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:36962) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oTwUR-0008AS-Se for guix-patches@gnu.org; Thu, 01 Sep 2022 22:33:04 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:54790) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oTwUQ-0004mN-J1 for guix-patches@gnu.org; Thu, 01 Sep 2022 22:33:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oTwUQ-0000kb-GH for guix-patches@gnu.org; Thu, 01 Sep 2022 22:33:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#57537] [PATCH v2] gnu: Add ec References: <20220902020049.15420-1-GNUtoo@cyberdimension.org> In-Reply-To: <20220902020049.15420-1-GNUtoo@cyberdimension.org> Resent-From: Denis 'GNUtoo' Carikli Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Fri, 02 Sep 2022 02:33:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 57537 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 57537@debbugs.gnu.org Cc: Denis 'GNUtoo' Carikli Received: via spool by 57537-submit@debbugs.gnu.org id=B57537.16620859712868 (code B ref 57537); Fri, 02 Sep 2022 02:33:02 +0000 Received: (at 57537) by debbugs.gnu.org; 2 Sep 2022 02:32:51 +0000 Received: from localhost ([127.0.0.1]:44539 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oTwUF-0000kC-7s for submit@debbugs.gnu.org; Thu, 01 Sep 2022 22:32:51 -0400 Received: from cyberdimension.org ([80.67.179.20]:55628 helo=gnutoo.cyberdimension.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oTwUC-0000k2-Qc for 57537@debbugs.gnu.org; Thu, 01 Sep 2022 22:32:49 -0400 Received: from gnutoo.cyberdimension.org (localhost [127.0.0.1]) by cyberdimension.org (OpenSMTPD) with ESMTP id ed2616e6; Fri, 2 Sep 2022 02:31:51 +0000 (UTC) Received: from localhost.localdomain (localhost [::1]) by gnutoo.cyberdimension.org (OpenSMTPD) with ESMTP id e75f9335; Fri, 2 Sep 2022 02:31:51 +0000 (UTC) From: Denis 'GNUtoo' Carikli Date: Fri, 2 Sep 2022 04:32:39 +0200 Message-Id: <20220902023239.26540-1-GNUtoo@cyberdimension.org> X-Mailer: git-send-email 2.35.1 MIME-Version: 1.0 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+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches * gnu/packages/linux.scm (ec): New variable. --- gnu/packages/linux.scm | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) base-commit: 4d361a6b5147e3f91573e9d3c8c540a233e7e142 diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 5254b20dc4..dd91ca60fc 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -1375,6 +1375,45 @@ (define-public librem-ec-acpi-linux-module and the notification, WiFi, and Bluetooth LED.") (license license:gpl2))) +(define-public ec + (package + (name "ec") + (version (package-version linux-libre)) + (source (package-source linux-libre)) + (build-system gnu-build-system) + (native-inputs (list coreutils)) + (arguments + '(#:make-flags (list (string-append "DESTDIR=" + (assoc-ref %outputs "out")) + "sbindir=/sbin") + #:phases (modify-phases %standard-phases + (delete 'configure) ;no configure script + (add-after 'unpack 'patch-Makefile + (lambda _ + (substitute* "tools/power/acpi/Makefile.config" + (("/bin/true") + (which "true"))) + (substitute* "tools/power/acpi/Makefile.config" + (("/usr/bin/install") + (which "install"))) #t)) + (add-after 'patch-Makefile 'enter-subdirectory + (lambda _ + (chdir "tools/power/acpi/tools/ec") #t))) + #:tests? #f)) ;no tests + (home-page (package-home-page linux-libre)) + (synopsis + "Low level utility for reading or writing Embedded Controller registers") + (description + "This utility can read or write specific registers or all the +available registers of the Embedded Controllers supported by the Linux +kernel. To work it needs to run as root, to have the ec_sys driver +loaded, and to have the debugfs filesystem mounted at +/sys/kernel/debug/. To make write support work, the ec_sys module +needs to be loaded with the write_support=1 parameter. Write support +can also be enabled after loading the module with +the 'echo 1 > /sys/module/ec_sys/parameters/write_support' command.") + (license license:gpl2))) + (define-public lkrg (package (name "lkrg")