all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* [bug#57537] [PATCH] gnu: Add ec
@ 2022-09-02  2:00 Denis 'GNUtoo' Carikli
  2022-09-02  2:14 ` Denis 'GNUtoo' Carikli
                   ` (2 more replies)
  0 siblings, 3 replies; 8+ messages in thread
From: Denis 'GNUtoo' Carikli @ 2022-09-02  2:00 UTC (permalink / raw)
  To: 57537; +Cc: Denis 'GNUtoo' Carikli

* gnu/packages/linux.scm (ec): New variable.

Signed-off-by: Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>
---
 gnu/packages/linux.scm | 38 ++++++++++++++++++++++++++++++++++++++
 1 file changed, 38 insertions(+)

diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm
index 5254b20dc4..bf71dad722 100644
--- a/gnu/packages/linux.scm
+++ b/gnu/packages/linux.scm
@@ -1375,6 +1375,44 @@ (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")))
+       #: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")

base-commit: 4d361a6b5147e3f91573e9d3c8c540a233e7e142
-- 
2.37.2





^ permalink raw reply related	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2022-09-26 20:43 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-09-02  2:00 [bug#57537] [PATCH] gnu: Add ec Denis 'GNUtoo' Carikli
2022-09-02  2:14 ` Denis 'GNUtoo' Carikli
2022-09-02  2:32 ` [bug#57537] [PATCH v2] " Denis 'GNUtoo' Carikli
2022-09-02  4:47   ` Tobias Geerinckx-Rice via Guix-patches via
2022-09-03 20:32     ` Maxime Devos
2022-09-06  4:29     ` Denis 'GNUtoo' Carikli
2022-09-24 13:28 ` Denis 'GNUtoo' Carikli
2022-09-26 20:42   ` bug#57537: [PATCH] " Ludovic Courtès

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.