From patchwork Wed Sep 13 09:55:56 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Jean-Pierre De Jesus DIAZ X-Patchwork-Id: 53780 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 DBE1027BBE9; Wed, 13 Sep 2023 10:57:24 +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.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,SPF_HELO_PASS,URIBL_BLOCKED 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 21EDA27BBE2 for ; Wed, 13 Sep 2023 10:57:20 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qgMcE-000350-Qd; Wed, 13 Sep 2023 05:56:58 -0400 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 1qgMcD-00034I-JQ for guix-patches@gnu.org; Wed, 13 Sep 2023 05:56:57 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qgMcD-0002o1-Bq for guix-patches@gnu.org; Wed, 13 Sep 2023 05:56:57 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qgMcI-0008PE-Fh for guix-patches@gnu.org; Wed, 13 Sep 2023 05:57:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#65911] [PATCH 1/4] gnu: Add python-smbus. References: <20230913095341.12586-1-jean@foundationdevices.com> In-Reply-To: <20230913095341.12586-1-jean@foundationdevices.com> Resent-From: Jean-Pierre De Jesus DIAZ Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Wed, 13 Sep 2023 09:57:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65911 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 65911@debbugs.gnu.org Cc: Jean-Pierre De Jesus DIAZ Received: via spool by 65911-submit@debbugs.gnu.org id=B65911.169459897632221 (code B ref 65911); Wed, 13 Sep 2023 09:57:02 +0000 Received: (at 65911) by debbugs.gnu.org; 13 Sep 2023 09:56:16 +0000 Received: from localhost ([127.0.0.1]:60851 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qgMbY-0008Nd-1D for submit@debbugs.gnu.org; Wed, 13 Sep 2023 05:56:16 -0400 Received: from mail-wm1-x330.google.com ([2a00:1450:4864:20::330]:58810) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qgMbV-0008NM-NR for 65911@debbugs.gnu.org; Wed, 13 Sep 2023 05:56:14 -0400 Received: by mail-wm1-x330.google.com with SMTP id 5b1f17b1804b1-401b393df02so77073125e9.1 for <65911@debbugs.gnu.org>; Wed, 13 Sep 2023 02:56:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=foundationdevices.com; s=google; t=1694598962; x=1695203762; darn=debbugs.gnu.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=dbBgquOEIpysy3u1yAc0ZRp+5s+3U9NUC3uqUdyAfjs=; b=SG4leC0cnARDrYFg77sGCh5V5VPcMU7cx+CuaBtm/eDlweYvlBGPG2DE2chGD4rteW /YRgwMuWcGK7A68FVJJlsgHJssd81NaPllFMw04OE3KBSzWuk5UYqusucUYe7gV2zo+8 dS+sKJ2P/fQltYavtM7oseEoNY4JhNtE62v2cIjVH/HyslVxRmeOzvYOk34cE3P1PZn2 iO8iQ1/2jM7U053HgyCyc8u4Z7SxFcgmbTqqkxhxEI3maj1tvrPAKAkrA2nEtOzBJ/b8 qcCWbDeOM7GIBZy8xbi9E5znpAepMOCj3GZaur8Icsjwl/5OsKWDy0W6/bZjxSFHxN0K zNeQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1694598962; x=1695203762; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=dbBgquOEIpysy3u1yAc0ZRp+5s+3U9NUC3uqUdyAfjs=; b=NsG95TMAuyQVnWbqgvvkr1TPJpxwMh3zS93mGs+Qyu0gMLs1VjZpG+3QtVTQqZ9MgF VlMneOrPXtDGek/n1CAlBdHsAMPY+NYT2tbfRYomCH9I03XpNIYogAoSJ2bFWks/wwqP 9oDrwCTqmv52Xszx5AoijKTOz9L5MD81nflrFDsQq0Kzw65y0O38OIU/5rdP8kOnOmLx c2XLdCL2GxW60mzrHb9PgQA1m88s8reoGClxQKRyLqDaqBsGFUWetweivDNWoq+Mo829 UtMRGNLDb3MhdVrucXx8jt6mEvRfrpaQSxJX7Cj5ahlAfdhhxC2TGlpRSw2f/SitUiqM 32uA== X-Gm-Message-State: AOJu0YxwN7HOatrj28ksLx3F+8ZgIDnA0Aeqos090YRzz0N31dV1WA1u cB6oJU1nWf4NlUlfetFYVN2OZkF87D2c1EQNDzIYIg== X-Google-Smtp-Source: AGHT+IHQ3QDRkzWQBDFz5wO44bfwNjP7KtarJr0H9o+pI5Wb43IUPKba0RWTDcKqPam4ruL/SfYRiw== X-Received: by 2002:a05:600c:204d:b0:3fa:77ed:9894 with SMTP id p13-20020a05600c204d00b003fa77ed9894mr1683941wmg.7.1694598962336; Wed, 13 Sep 2023 02:56:02 -0700 (PDT) Received: from omen15.home ([89.131.29.87]) by smtp.gmail.com with ESMTPSA id x14-20020a1c7c0e000000b003fe2b081661sm1577675wmc.30.2023.09.13.02.56.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 13 Sep 2023 02:56:02 -0700 (PDT) Date: Wed, 13 Sep 2023 11:55:56 +0200 Message-Id: <20230913095559.12676-1-jean@foundationdevices.com> X-Mailer: git-send-email 2.34.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: , Reply-to: Jean-Pierre De Jesus DIAZ X-ACL-Warn: , Jean-Pierre De Jesus DIAZ via Guix-patches X-Patchwork-Original-From: Jean-Pierre De Jesus DIAZ via Guix-patches via From: Jean-Pierre De Jesus DIAZ Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches * gnu/packages/linux.scm (python-smbus): New variable. Signed-off-by: Jean-Pierre De Jesus DIAZ --- gnu/packages/linux.scm | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 36354b4d82..e57ab866c6 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -75,6 +75,7 @@ ;;; Copyright © 2023 Yovan Naumovski ;;; Copyright © 2023 Zheng Junjie <873216071@qq.com> ;;; Copyright © 2023 dan +;;; Copyright © 2023 Foundation Devices, Inc. ;;; ;;; 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) @@ -4921,6 +4923,28 @@ (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" #$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") From patchwork Wed Sep 13 09:55:57 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jean-Pierre De Jesus DIAZ X-Patchwork-Id: 53782 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 5923F27BBEC; Wed, 13 Sep 2023 10:57:29 +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.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,SPF_HELO_PASS,URIBL_BLOCKED autolearn=ham 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 78EB427BBE2 for ; Wed, 13 Sep 2023 10:57:28 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qgMcH-00035n-B3; Wed, 13 Sep 2023 05:57:01 -0400 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 1qgMcE-00034g-5d for guix-patches@gnu.org; Wed, 13 Sep 2023 05:56:58 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qgMcD-0002oB-TO for guix-patches@gnu.org; Wed, 13 Sep 2023 05:56:57 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qgMcI-0008PM-R3 for guix-patches@gnu.org; Wed, 13 Sep 2023 05:57:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#65911] [PATCH 2/4] gnu: python-pyusb: Use G-Expressions. Resent-From: Jean-Pierre De Jesus DIAZ Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Wed, 13 Sep 2023 09:57:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65911 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 65911@debbugs.gnu.org Cc: Jean-Pierre De Jesus DIAZ Received: via spool by 65911-submit@debbugs.gnu.org id=B65911.169459898232249 (code B ref 65911); Wed, 13 Sep 2023 09:57:02 +0000 Received: (at 65911) by debbugs.gnu.org; 13 Sep 2023 09:56:22 +0000 Received: from localhost ([127.0.0.1]:60855 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qgMbd-0008O4-Fs for submit@debbugs.gnu.org; Wed, 13 Sep 2023 05:56:21 -0400 Received: from mail-wm1-x336.google.com ([2a00:1450:4864:20::336]:53725) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qgMbW-0008NO-UF for 65911@debbugs.gnu.org; Wed, 13 Sep 2023 05:56:17 -0400 Received: by mail-wm1-x336.google.com with SMTP id 5b1f17b1804b1-401f68602a8so71748675e9.3 for <65911@debbugs.gnu.org>; Wed, 13 Sep 2023 02:56:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=foundationdevices.com; s=google; t=1694598964; x=1695203764; darn=debbugs.gnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=Z7vewyNrd3yvpvRhka3hG253wR9i1tRJ2xCbFm1TjOc=; b=LkRknlO5VeVJrmDW3wihyCuU+atQzyFEBGGLcDTk83E/Ton/c7llLYFYYeRsEJ8z/g oKNUKb85ArFm/APZRPj50aXH+Uev+3brP8mQvUAWCDZc5HmYhvdjYQXCRWEcIoZrtwAU TwbZhi1ugI651Rh80ipJupYBwcWI0buvZDva80hRDRYBWj+8ZGQWyg+9tFK98L322o46 F4fo97F0zXJ6I4h8sj1+ry7Ybh6kzcQvsP5C7Z/Enp1u6HVgZnq2BplwXSl4ymipaSlt /pDtrybSFnvwkLnNv4Vc+vo4HSgpko0Dx0VF046XpqKwiurcxeXZ5A6vwnJ6Z59a0gdO fNng== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1694598964; x=1695203764; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=Z7vewyNrd3yvpvRhka3hG253wR9i1tRJ2xCbFm1TjOc=; b=mIr8ZXJyYEHA0foOqnhJtM8mCwTqyF9OnOVSalza/QaEbCzL1I/FEbJhp2wcjALY6O hkxEQbGNg52vjl3KDYVnWYJsTw3Yz0PwiIn1kSWwN3Vn7vU6LbdYIaRp0tPIQT1vi4Oj vf+GVEEFRx6qp3ZPw7+51hL2Fl3e3jm8389ZnYZXCOkyL/VKeh6ltzNDqYSD+M4Is0um ZSaZHvwycwl/EaE6lIdDJuiw8wnQganIr+vd6j8popUC7nfEWO0c9q+KFfkljhDvJHc/ Lov+OJqqPwgY69TAeQdpRJqeD9nuH6J8P9svOUutR+pv3ecTLtDiB8p1jYN/cPQW0DE3 91/Q== X-Gm-Message-State: AOJu0YzN+507sbgMyhJKaV5ACilfqcA4/NBm9HR/T8+hrTkVVROBLy4k 2uoaIC2ZnJyuofhuSfBZHpk9QswasW6C20A8XYp6NQ== X-Google-Smtp-Source: AGHT+IEI7AzgC9wuUe5nRET3O7KwGdRWkimhh5/6T7mvbGiGmhFiPP3u5rsZT2k4igiINg7tZCLsHg== X-Received: by 2002:a7b:cc94:0:b0:401:bf89:b013 with SMTP id p20-20020a7bcc94000000b00401bf89b013mr1506128wma.19.1694598963925; Wed, 13 Sep 2023 02:56:03 -0700 (PDT) Received: from omen15.home ([89.131.29.87]) by smtp.gmail.com with ESMTPSA id x14-20020a1c7c0e000000b003fe2b081661sm1577675wmc.30.2023.09.13.02.56.03 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 13 Sep 2023 02:56:03 -0700 (PDT) Date: Wed, 13 Sep 2023 11:55:57 +0200 Message-Id: <20230913095559.12676-2-jean@foundationdevices.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230913095559.12676-1-jean@foundationdevices.com> References: <20230913095559.12676-1-jean@foundationdevices.com> 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: , Reply-to: Jean-Pierre De Jesus DIAZ X-ACL-Warn: , Jean-Pierre De Jesus DIAZ via Guix-patches X-Patchwork-Original-From: Jean-Pierre De Jesus DIAZ via Guix-patches via From: Jean-Pierre De Jesus DIAZ Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches * gnu/packages/usb.scm (python-pyusb) : Use G-Expressions style instead of quoting. Signed-off-by: Jean-Pierre De Jesus DIAZ --- gnu/packages/libusb.scm | 35 +++++++++++++++++------------------ 1 file changed, 17 insertions(+), 18 deletions(-) diff --git a/gnu/packages/libusb.scm b/gnu/packages/libusb.scm index e615b81ea3..469882e871 100644 --- a/gnu/packages/libusb.scm +++ b/gnu/packages/libusb.scm @@ -288,24 +288,23 @@ (define-public python-pyusb "1fg7knfzybzija2b01pzrzhzsj989scl12sb2ra4f503l8279k54")))) (build-system python-build-system) (arguments - `(#:tests? #f ; no tests - #:modules ((srfi srfi-1) - (srfi srfi-26) - (guix build utils) - (guix build python-build-system)) - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'fix-libusb-reference - (lambda* (#:key inputs #:allow-other-keys) - (substitute* "usb/libloader.py" - (("lib = locate_library\\(candidates, find_library\\)") - (string-append - "lib = \"" - (find (negate symbolic-link?) - (find-files (assoc-ref inputs "libusb") - "^libusb-.*\\.so\\..*")) - "\""))) - #t))))) + (list #:tests? #f ; no tests + #:modules '((srfi srfi-1) + (srfi srfi-26) + (guix build utils) + (guix build python-build-system)) + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'fix-libusb-reference + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "usb/libloader.py" + (("lib = locate_library\\(candidates, find_library\\)") + (string-append + "lib = \"" + (find (negate symbolic-link?) + (find-files (assoc-ref inputs "libusb") + "^libusb-.*\\.so\\..*")) + "\"")))))))) (native-inputs (list python-setuptools-scm)) From patchwork Wed Sep 13 09:55:58 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jean-Pierre De Jesus DIAZ X-Patchwork-Id: 53783 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 5C67E27BBE2; Wed, 13 Sep 2023 10:57:30 +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.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,SPF_HELO_PASS,URIBL_BLOCKED autolearn=ham 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 AC4F927BBEA for ; Wed, 13 Sep 2023 10:57:28 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qgMcH-00036i-JT; Wed, 13 Sep 2023 05:57:01 -0400 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 1qgMcE-00034p-Fb for guix-patches@gnu.org; Wed, 13 Sep 2023 05:56:58 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qgMcE-0002oM-61 for guix-patches@gnu.org; Wed, 13 Sep 2023 05:56:58 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qgMcJ-0008PT-9U for guix-patches@gnu.org; Wed, 13 Sep 2023 05:57:03 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#65911] [PATCH 3/4] gnu: python-pyusb: Add libusb-compat backend. Resent-From: Jean-Pierre De Jesus DIAZ Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Wed, 13 Sep 2023 09:57:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65911 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 65911@debbugs.gnu.org Cc: Jean-Pierre De Jesus DIAZ Received: via spool by 65911-submit@debbugs.gnu.org id=B65911.169459898232256 (code B ref 65911); Wed, 13 Sep 2023 09:57:03 +0000 Received: (at 65911) by debbugs.gnu.org; 13 Sep 2023 09:56:22 +0000 Received: from localhost ([127.0.0.1]:60857 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qgMbd-0008O6-TR for submit@debbugs.gnu.org; Wed, 13 Sep 2023 05:56:22 -0400 Received: from mail-wm1-x333.google.com ([2a00:1450:4864:20::333]:45239) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qgMbY-0008NQ-HC for 65911@debbugs.gnu.org; Wed, 13 Sep 2023 05:56:17 -0400 Received: by mail-wm1-x333.google.com with SMTP id 5b1f17b1804b1-401da71b83cso74480185e9.2 for <65911@debbugs.gnu.org>; Wed, 13 Sep 2023 02:56:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=foundationdevices.com; s=google; t=1694598965; x=1695203765; darn=debbugs.gnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=3WmwWDNs8CuejHUN7rlzKMqwPQNpS7WuhsiYmPQlJOo=; b=dovMy5zNeKBxja14bfFTsggjgPRXTA92bZMahNGEB/cYj/vpuGRqXiJ3OtEPli6xWR hJxd+a5xAgkdRn6cyP564zjCOdAD4D72bGQVAljCUKQ+Qes5JdIStzMyErqO+/rQa2oh usbiE24ZT8UcIzrWbcFxDFVUncnDpywrWrtP9U5jUs28P0Cb9NftIbry4mCKt7NWe+9G y2ki8jXd/y2hfdivskxugKk5wXNRqCAEiaNgCFX2Kd5oyuscDSdi94kyxtHCLaFvvyp6 Str8XJ054vKn1VVMBgRxqco1p0MKziAri9TvRK+fIAuXiwr5uwiEXKB9WomhPYQhQY/N Pq8g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1694598965; x=1695203765; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=3WmwWDNs8CuejHUN7rlzKMqwPQNpS7WuhsiYmPQlJOo=; b=AckvMhnvLS8tI9O5/mhkBCpOrOCC1KxwpguBXSANIZ/9DPs0YZ9MJroXPnFfJOYPbC Slof6b6ryCH8TIr21beZ7aLK+LJ21pwXWQ5WUurzJ0TIKH2IOlsoSbIdFpERZW/s6/Mh 6HP/X1I1HPFDAVm0DuYZ/YoJLxDlPc2yHf5Fov2DDC17RQiev2ukEa7H4D4RodfEXf2I w684X+5hIpiygPGs+iDxHfrAf7HSDQXVd65TNKlTLgBlIIvcyn+uIYqp73BguwLmxMJ0 Bchw1Y+ILhpXnRr9vPfUw46/6RvGlLX05Ld+CAVnRILSqDgsHH7xXNHwGQFHysJQeyGA G1dA== X-Gm-Message-State: AOJu0YydfD4hGT2siXejkrBb+weNevvL5tPOOFxvjEFglRVjw30Dl9zo Onv2yHi84yV3rn34oltQhCcGm7hCbbLPBEKVnjn4vA== X-Google-Smtp-Source: AGHT+IFLxKeMuDaEDN5kx7ISzMWmFYdEjndYuu2x5oii5xZkoTVqJ2en9TkpqDxrulqmoOVG0ZVvaQ== X-Received: by 2002:a1c:4c09:0:b0:401:bf87:9898 with SMTP id z9-20020a1c4c09000000b00401bf879898mr1840217wmf.25.1694598965389; Wed, 13 Sep 2023 02:56:05 -0700 (PDT) Received: from omen15.home ([89.131.29.87]) by smtp.gmail.com with ESMTPSA id x14-20020a1c7c0e000000b003fe2b081661sm1577675wmc.30.2023.09.13.02.56.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 13 Sep 2023 02:56:05 -0700 (PDT) Date: Wed, 13 Sep 2023 11:55:58 +0200 Message-Id: <20230913095559.12676-3-jean@foundationdevices.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230913095559.12676-1-jean@foundationdevices.com> References: <20230913095559.12676-1-jean@foundationdevices.com> 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: , Reply-to: Jean-Pierre De Jesus DIAZ X-ACL-Warn: , Jean-Pierre De Jesus DIAZ via Guix-patches X-Patchwork-Original-From: Jean-Pierre De Jesus DIAZ via Guix-patches via From: Jean-Pierre De Jesus DIAZ Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches * gnu/packages/libusb.scm (python-pyusb) : Do not hard-code libusb1 library for all back-ends, and allow to use libusb0 as a back-end. Also enabled tests as the package does have a test suite. * gnu/packages/libusb.scm (python-pyusb) : Add libusb-compat. Signed-off-by: Jean-Pierre De Jesus DIAZ --- gnu/packages/libusb.scm | 52 +++++++++++++++++++++++++++++++---------- 1 file changed, 40 insertions(+), 12 deletions(-) diff --git a/gnu/packages/libusb.scm b/gnu/packages/libusb.scm index 469882e871..d15e561668 100644 --- a/gnu/packages/libusb.scm +++ b/gnu/packages/libusb.scm @@ -288,28 +288,56 @@ (define-public python-pyusb "1fg7knfzybzija2b01pzrzhzsj989scl12sb2ra4f503l8279k54")))) (build-system python-build-system) (arguments - (list #:tests? #f ; no tests - #:modules '((srfi srfi-1) + (list #:modules '((srfi srfi-1) (srfi srfi-26) (guix build utils) (guix build python-build-system)) #:phases #~(modify-phases %standard-phases + ;; Repurpose the candidates parameter to be the path to the + ;; library, then on each backend we substitute the candidates + ;; with the full path to the .so library or with None if not + ;; supported. + ;; + ;; While most applications could use a single back-end this + ;; library allows to manually select the back-end so it is + ;; appropriate to provide as much back-ends as possible. (add-after 'unpack 'fix-libusb-reference (lambda* (#:key inputs #:allow-other-keys) - (substitute* "usb/libloader.py" - (("lib = locate_library\\(candidates, find_library\\)") - (string-append - "lib = \"" - (find (negate symbolic-link?) - (find-files (assoc-ref inputs "libusb") - "^libusb-.*\\.so\\..*")) - "\"")))))))) - + (let ((libusb0 (find + (negate symbolic-link?) + (find-files (assoc-ref inputs "libusb-compat") + "^libusb-.*\\.so\\..*"))) + (libusb1 (find + (negate symbolic-link?) + (find-files (assoc-ref inputs "libusb") + "^libusb-.*\\.so\\..*")))) + (substitute* "usb/libloader.py" + (("lib = locate_library\\(candidates, find_library\\)") + "lib = candidates")) + (substitute* "usb/backend/libusb0.py" + (("\\('usb-0\\.1', 'usb', 'libusb0'\\)") + (format #f "~s" libusb0))) + (substitute* "usb/backend/libusb1.py" + (("\\('usb-1\\.0', 'libusb-1\\.0', 'usb'\\)") + (format #f "~s" libusb1))) + ;; FIXME: OpenUSB is not packaged for GNU Guix. + (substitute* "usb/backend/openusb.py" + (("\\('openusb',\\)") "None"))))) + ;; Note: tests seems to succeed with libusb-compat as libusb + ;; fails because it doesn't have a usbfs present in the build + ;; environment. + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (with-directory-excursion "tests" + (setenv "PYUSB_DEBUG" "debug") + (setenv "LIBUSB_DEBUG" "4") + (invoke "python" "testall.py")))))))) (native-inputs (list python-setuptools-scm)) (inputs - (list libusb)) + (list libusb libusb-compat)) (home-page "https://pyusb.github.io/pyusb/") (synopsis "Python bindings to the libusb library") (description From patchwork Wed Sep 13 09:55:59 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Jean-Pierre De Jesus DIAZ X-Patchwork-Id: 53781 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 908E627BBEA; Wed, 13 Sep 2023 10:57:27 +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.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,SPF_HELO_PASS,URIBL_BLOCKED autolearn=ham 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 7410827BBE2 for ; Wed, 13 Sep 2023 10:57:26 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qgMcH-00036G-BU; Wed, 13 Sep 2023 05:57:01 -0400 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 1qgMcE-000356-Rz for guix-patches@gnu.org; Wed, 13 Sep 2023 05:56:58 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qgMcE-0002of-HH for guix-patches@gnu.org; Wed, 13 Sep 2023 05:56:58 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qgMcJ-0008Pa-L7 for guix-patches@gnu.org; Wed, 13 Sep 2023 05:57:03 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#65911] [PATCH 4/4] gnu: Add liquidctl. Resent-From: Jean-Pierre De Jesus DIAZ Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Wed, 13 Sep 2023 09:57:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65911 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 65911@debbugs.gnu.org Cc: Jean-Pierre De Jesus DIAZ Received: via spool by 65911-submit@debbugs.gnu.org id=B65911.169459898232263 (code B ref 65911); Wed, 13 Sep 2023 09:57:03 +0000 Received: (at 65911) by debbugs.gnu.org; 13 Sep 2023 09:56:22 +0000 Received: from localhost ([127.0.0.1]:60859 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qgMbe-0008OD-Di for submit@debbugs.gnu.org; Wed, 13 Sep 2023 05:56:22 -0400 Received: from mail-wm1-x32c.google.com ([2a00:1450:4864:20::32c]:52348) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qgMbZ-0008NT-So for 65911@debbugs.gnu.org; Wed, 13 Sep 2023 05:56:18 -0400 Received: by mail-wm1-x32c.google.com with SMTP id 5b1f17b1804b1-4018af1038cso71830635e9.0 for <65911@debbugs.gnu.org>; Wed, 13 Sep 2023 02:56:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=foundationdevices.com; s=google; t=1694598967; x=1695203767; darn=debbugs.gnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=bpxaVPpGNYjBDIY+1Y2RHHHK6OL7c/eQbRvY2k7k+dw=; b=MKoqz3zWWQgRMRPDLmoAw69GVbzEGg+b7rLNsBJmwezHgpx2Cg1MEsFdIVNziAZSuQ 6O4RgskN3BLMmMDED/YYMqpCe2iE9TPviMMsbWOMpulboX4rhQH/JEBOO7JHNNt2FChF hPpyrhqPowNyDNpvjArSUXIYg36QxjGF45nzOYKmAScmvwapI5jY+k8L91ffYPt7nyha CYTE3cEHe8Rk0XhI8dNXVyNFJbqvOdBMndUK3yxic3h0KxsHgdxP8WvR6sXHYTKDNnU7 A89bZGWclZXbCCBDgSKLcNXJDudel8PfHZmH/sgNW/SP29ArIv7BCibT3zLXqtwmF9FD kYmQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1694598967; x=1695203767; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=bpxaVPpGNYjBDIY+1Y2RHHHK6OL7c/eQbRvY2k7k+dw=; b=i/UaYkdf7W6IFDWhZUn4ZhBt/fBmdDDAmKU5h5BRdxYiPoz+X2dil/vfFakAVCoB2/ 7xN0bIoZ7XJbZRYul6yE4ivi+QCqx6VsNUKhmdi79z5J15pJnDtePi2s6FsLbbQNW2CL M34H03C/xIhh21SGHIv3NwP+1MhBZ/EnU98UDMCCP9a5LhUwTIdD2IqhhnZp7F4t7eBL ubYIFkwYaT9IiC9iWjxzpsubolRvoaOJhD+tUt6ted1ziqrb9CcvN0VIWPsG0jvVR3dA lemRnfPJb4cNzEdPtQGKFq/9dEULqgQOMxMo2lgu6Pbtc01AHh8hdwiKC9wOHhRNis0w xXFw== X-Gm-Message-State: AOJu0YzMH/Z3BErA4fgKiXBfK2Mc6B5tiIGrpKQNGlhEId/FCQ17BHhk RHNPtmyQv7+5sfYjEDS9I25bYOHW4N/NtlMFyCuaTg== X-Google-Smtp-Source: AGHT+IFmyVuV+qJo9+6lkeNgvGZhoP3JnozpNAy614rqfJpSWXEypkDYyxlmjZbOndN3GBPJ3CW6gQ== X-Received: by 2002:a1c:7212:0:b0:401:c636:8f4c with SMTP id n18-20020a1c7212000000b00401c6368f4cmr1674930wmc.3.1694598966802; Wed, 13 Sep 2023 02:56:06 -0700 (PDT) Received: from omen15.home ([89.131.29.87]) by smtp.gmail.com with ESMTPSA id x14-20020a1c7c0e000000b003fe2b081661sm1577675wmc.30.2023.09.13.02.56.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 13 Sep 2023 02:56:06 -0700 (PDT) Date: Wed, 13 Sep 2023 11:55:59 +0200 Message-Id: <20230913095559.12676-4-jean@foundationdevices.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230913095559.12676-1-jean@foundationdevices.com> References: <20230913095559.12676-1-jean@foundationdevices.com> 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: , Reply-to: Jean-Pierre De Jesus DIAZ X-ACL-Warn: , Jean-Pierre De Jesus DIAZ via Guix-patches X-Patchwork-Original-From: Jean-Pierre De Jesus DIAZ via Guix-patches via From: Jean-Pierre De Jesus DIAZ Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches * gnu/packages/hardware.scm (liquidctl): New variable. Signed-off-by: Jean-Pierre De Jesus DIAZ --- gnu/packages/hardware.scm | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) diff --git a/gnu/packages/hardware.scm b/gnu/packages/hardware.scm index 5188bb2910..3d8fa833a2 100644 --- a/gnu/packages/hardware.scm +++ b/gnu/packages/hardware.scm @@ -16,6 +16,7 @@ ;;; Copyright © 2022 Maxim Cournoyer ;;; Copyright © 2022 Efraim Flashner ;;; Copyright © 2023 Spencer Skylar Chan +;;; Copyright © 2023 Foundation Devices, Inc. ;;; ;;; This file is part of GNU Guix. ;;; @@ -80,6 +81,7 @@ (define-module (gnu packages hardware) #:use-module (gnu packages protobuf) #:use-module (gnu packages pulseaudio) #:use-module (gnu packages python) + #:use-module (gnu packages python-crypto) #:use-module (gnu packages python-web) #:use-module (gnu packages python-xyz) #:use-module (gnu packages qt) @@ -99,6 +101,7 @@ (define-module (gnu packages hardware) #:use-module (guix build-system gnu) #:use-module (guix build-system meson) #:use-module (guix build-system perl) + #:use-module (guix build-system pyproject) #:use-module (guix build-system python) #:use-module (guix download) #:use-module (guix gexp) @@ -798,6 +801,42 @@ (define-public libsmbios (license (list license:osl2.1 license:gpl2+ license:bsd-3 license:boost1.0)))) +(define-public liquidctl + (package + (name "liquidctl") + (version "1.13.0") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/liquidctl/liquidctl") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0hpxkrfxm9c4v5ld7bh6qs9fmq9imz8s5i9l0l78l47bcm12nkrd")))) + (build-system pyproject-build-system) + (arguments + (list #:phases + #~(modify-phases %standard-phases + (add-before 'check 'set-runtime-dir + (lambda _ + (setenv "XDG_RUNTIME_DIR" "/tmp")))))) + (native-inputs (list python-pytest)) + (propagated-inputs + (list python-colorlog + python-crcmod + python-docopt + python-hidapi + python-pillow + python-pyusb + python-smbus)) + (home-page "https://github.com/liquidctl/liquidctl") + (synopsis "Drivers and tools for liquid cooling equipment") + (description "Liquidctl is a package with tools, drivers and a Python +library to work with liquid cooling equipment such as @acronym{AIO, All-In-One} +coolers, fan controllers and other devices.") + (license license:gpl3+))) + ;; Distinct from memtest86, which is obsolete. (define-public memtest86+ (package