GNU bug report logs - #65911
[PATCH 0/4] gnu: Add liquidctl.

Previous Next

Package: guix-patches;

Reported by: Jean-Pierre De Jesus DIAZ <jean <at> foundationdevices.com>

Date: Wed, 13 Sep 2023 09:55:01 UTC

Severity: normal

Tags: patch

Done: Ludovic Courtès <ludo <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


Message #26 received at 65911 <at> debbugs.gnu.org (full text, mbox):

From: Jean-Pierre De Jesus DIAZ <jean <at> foundationdevices.com>
To: 65911 <at> debbugs.gnu.org
Cc: Jean-Pierre De Jesus DIAZ <jean <at> foundationdevices.com>
Subject: [PATCH v1 1/4] gnu: Add python-smbus.
Date: Wed, 20 Sep 2023 12:05:25 +0200
* gnu/packages/linux.scm (python-smbus): New variable.

Signed-off-by: Jean-Pierre De Jesus DIAZ <jean <at> foundationdevices.com>
---
 gnu/packages/linux.scm | 25 +++++++++++++++++++++++++
 1 file changed, 25 insertions(+)

diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm
index 85e3d9845d..6eb7fb43b8 100644
--- a/gnu/packages/linux.scm
+++ b/gnu/packages/linux.scm
@@ -75,6 +75,7 @@
 ;;; Copyright © 2023 Yovan Naumovski <yovan <at> gorski.stream>
 ;;; Copyright © 2023 Zheng Junjie <873216071 <at> qq.com>
 ;;; Copyright © 2023 dan <i <at> dan.games>
+;;; Copyright © 2023 Foundation Devices, Inc. <hello <at> foundationdevices.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -188,6 +189,7 @@ (define-module (gnu packages linux)
   #:use-module (guix build-system gnu)
   #:use-module (guix build-system go)
   #:use-module (guix build-system meson)
+  #:use-module (guix build-system pyproject)
   #:use-module (guix build-system python)
   #:use-module (guix build-system trivial)
   #:use-module (guix build-system linux-module)
@@ -4963,6 +4965,29 @@ (define-public i2c-tools-3
         #~(list (string-append "prefix=" #$output)
                 (string-append "CC=" #$(cc-for-target))))))))
 
+(define-public python-smbus
+  (package
+    (inherit i2c-tools)
+    (name "python-smbus")
+    (build-system pyproject-build-system)
+    (arguments
+     (list #:tests? #f ;; No test suite.
+           #:phases
+           #~(modify-phases %standard-phases
+               (add-after 'unpack 'change-directory
+                 (lambda _ (chdir "py-smbus")))
+               (add-after 'change-directory 'set-library-path
+                 (lambda _
+                   (substitute* "setup.py"
+                     (("-L\\.\\./lib")
+                      (string-append "-L" #$(this-package-input "i2c-tools")
+                                     "/lib"))))))))
+    (inputs (list i2c-tools))
+    (synopsis "I2C/SMBus access for Python")
+    (description "This package provides a Python library to access
+@acronym{I2C, Inter-Integrated Circuit} and @acronym{SMBus, System
+Management Bus} devices on Linux.")))
+
 (define-public xsensors
   (package
     (name "xsensors")

base-commit: 6bd17a0806ad32d1493ac51a7443276f719c4224
-- 
2.34.1





This bug report was last modified 1 year and 238 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.