From patchwork Thu May 9 22:53:10 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Nicolas Graves X-Patchwork-Id: 64263 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 06FF027BBF2; Thu, 9 May 2024 23:59:15 +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,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 8C1B327BBE2 for ; Thu, 9 May 2024 23:59:07 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1s5Chp-0006Cj-DP; Thu, 09 May 2024 18:57:41 -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 1s5ChJ-0005rK-JQ for guix-patches@gnu.org; Thu, 09 May 2024 18:57:09 -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 1s5ChJ-0006Qz-Bo for guix-patches@gnu.org; Thu, 09 May 2024 18:57:09 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1s5ChH-0002f3-MR for guix-patches@gnu.org; Thu, 09 May 2024 18:57:07 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#70855] [PATCH 15/92] gnu: python-xcffib: Move to (gnu packages xorg). Resent-From: Nicolas Graves Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Thu, 09 May 2024 22:57:07 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 70855 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 70855@debbugs.gnu.org Cc: ngraves@ngraves.fr Received: via spool by 70855-submit@debbugs.gnu.org id=B70855.17152953959877 (code B ref 70855); Thu, 09 May 2024 22:57:07 +0000 Received: (at 70855) by debbugs.gnu.org; 9 May 2024 22:56:35 +0000 Received: from localhost ([127.0.0.1]:41068 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1s5Cgk-0002ZF-TZ for submit@debbugs.gnu.org; Thu, 09 May 2024 18:56:35 -0400 Received: from 1.mo576.mail-out.ovh.net ([178.33.251.173]:41187) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1s5Cgh-0002Yk-PL for 70855@debbugs.gnu.org; Thu, 09 May 2024 18:56:33 -0400 Received: from director7.ghost.mail-out.ovh.net (unknown [10.108.2.235]) by mo576.mail-out.ovh.net (Postfix) with ESMTP id 4Vb6nq6Nfvz1hx4 for <70855@debbugs.gnu.org>; Thu, 9 May 2024 22:56:31 +0000 (UTC) Received: from ghost-submission-6684bf9d7b-6dhzz (unknown [10.110.178.196]) by director7.ghost.mail-out.ovh.net (Postfix) with ESMTPS id 481E01FDB0; Thu, 9 May 2024 22:56:31 +0000 (UTC) Received: from ngraves.fr ([37.59.142.109]) by ghost-submission-6684bf9d7b-6dhzz with ESMTPSA id G5qbDZ9UPWZu9iAAXUNWsQ (envelope-from ); Thu, 09 May 2024 22:56:31 +0000 Authentication-Results: garm.ovh; auth=pass (GARM-109S0037d3471d7-d968-4aae-8674-927191f3017c, E63BAB6C0A71DD4DA934779D5D345DF804807214) smtp.auth=ngraves@ngraves.fr X-OVh-ClientIp: 81.67.146.208 Date: Fri, 10 May 2024 00:53:10 +0200 Message-ID: <20240509225530.24649-15-ngraves@ngraves.fr> X-Mailer: git-send-email 2.41.0 In-Reply-To: <20240509225530.24649-1-ngraves@ngraves.fr> References: <20240509225530.24649-1-ngraves@ngraves.fr> MIME-Version: 1.0 X-Ovh-Tracer-Id: 6097592420658111202 X-VR-SPAMSTATE: OK X-VR-SPAMSCORE: 0 X-VR-SPAMCAUSE: gggruggvucftvghtrhhoucdtuddrgedvledrvdeffedgudeiucetufdoteggodetrfdotffvucfrrhhofhhilhgvmecuqfggjfdpvefjgfevmfevgfenuceurghilhhouhhtmecuhedttdenucenucfjughrpefhvfevufffkffojghfgggtgfesthekredtredtjeenucfhrhhomheppfhitgholhgrshcuifhrrghvvghsuceonhhgrhgrvhgvshesnhhgrhgrvhgvshdrfhhrqeenucggtffrrghtthgvrhhnpedvffehgeekhfekgffgleehffetiefggeeitdduteekfffhkeehveejfeejledtieenucffohhmrghinhepghhithhhuhgsrdgtohhmnecukfhppeduvdejrddtrddtrddupdekuddrieejrddugeeirddvtdekpdefjedrheelrddugedvrddutdelnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehinhgvthepuddvjedrtddrtddruddpmhgrihhlfhhrohhmpehnghhrrghvvghssehnghhrrghvvghsrdhfrhdpnhgspghrtghpthhtohepuddprhgtphhtthhopeejtdekheehseguvggssghughhsrdhgnhhurdhorhhgpdfovfetjfhoshhtpehmohehjeeipdhmohguvgepshhmthhpohhuth 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: Nicolas Graves X-ACL-Warn: , Nicolas Graves via Guix-patches X-Patchwork-Original-From: Nicolas Graves via Guix-patches via From: Nicolas Graves 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/python-xyz.scm (python-xcffib): Move from here… * gnu/packages/xorg.scm (python-xcffib): …to here. The package's build is fully rewritten and updated to version 1.5.0. Change-Id: Ia77b9fc2160dacd77c3eaf4199278046a52515d7 --- gnu/packages/python-xyz.scm | 44 ------------------------------------- gnu/packages/xorg.scm | 41 ++++++++++++++++++++++++++++++++++ 2 files changed, 41 insertions(+), 44 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index e1e8ef7caa0..b34af56a1db 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -11139,50 +11139,6 @@ (define-public python-manimpango ManimPango is internally used in Manim to render (non-LaTeX) text.") (license license:expat))) -(define-public python-xcffib - (package - (name "python-xcffib") - (version "0.11.1") - (source - (origin - (method url-fetch) - (uri (pypi-uri "xcffib" version)) - (sha256 - (base32 - "0nkglsm9nbhv238iagmmsjcz6lf1yfdvp5kmspphdj385vz9r50j")))) - (build-system python-build-system) - (inputs - (list libxcb)) - (propagated-inputs - (list python-cffi ; used at run time - python-six)) - (arguments - `(;; FIXME: Tests need more work. See ".travis.yml" in the repository. - #:tests? #f - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'fix-libxcb-path - (lambda* (#:key inputs #:allow-other-keys) - (let ((libxcb (assoc-ref inputs "libxcb"))) - (substitute* '("xcffib/__init__.py") - (("soname = ctypes.util.find_library.*xcb.*") - (string-append "soname = \"" libxcb "/lib/libxcb.so\"\n"))) - #t))) - (add-after 'install 'install-doc - (lambda* (#:key outputs #:allow-other-keys) - (let ((doc (string-append (assoc-ref outputs "out") "/share" - "/doc/" ,name "-" ,version))) - (mkdir-p doc) - (copy-file "README.md" - (string-append doc "/README.md")) - #t)))))) - (home-page "https://github.com/tych0/xcffib") - (synopsis "XCB Python bindings") - (description - "Xcffib is a replacement for xpyb, an XCB Python bindings. It adds -support for Python 3 and PyPy. It is based on cffi.") - (license license:expat))) - (define-public python-cairocffi (package (name "python-cairocffi") diff --git a/gnu/packages/xorg.scm b/gnu/packages/xorg.scm index fbe6375818f..2bc6946599c 100644 --- a/gnu/packages/xorg.scm +++ b/gnu/packages/xorg.scm @@ -65,6 +65,7 @@ (define-module (gnu packages xorg) #:use-module (guix build-system meson) #:use-module (guix build-system perl) #:use-module (guix build-system python) + #:use-module (guix build-system pyproject) #:use-module (guix utils) #:use-module (gnu packages) #:use-module (gnu packages aidc) @@ -92,6 +93,7 @@ (define-module (gnu packages xorg) #:use-module (gnu packages image) #:use-module (gnu packages imagemagick) #:use-module (gnu packages libedit) + #:use-module (gnu packages libffi) #:use-module (gnu packages linux) #:use-module (gnu packages llvm) #:use-module (gnu packages m4) @@ -1706,6 +1708,45 @@ (define xcffibgen generate code for the @code{python-xcbffib} package.") (license license:expat))) +(define-public python-xcffib + (package + (name "python-xcffib") + (version "1.5.0") + (source (package-source xcffibgen)) + (build-system pyproject-build-system) + (native-inputs + (list pkg-config which xcb-proto xcffibgen)) + (inputs + (list libxcb)) + (propagated-inputs + (list python-cffi ; used at run time + python-six)) + (arguments + (list + ;; Tests seem to require version 3.12 of Python. + #:tests? #f + #:phases + #~(modify-phases %standard-phases + (add-before 'build 'generate-bindings + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "Makefile" + (("^GEN=.*") + (format #f "GEN=~a~%" + (search-input-file inputs "/bin/xcffibgen")))) + (invoke "make" "xcffib"))) + (add-before 'build 'fix-libxcb-path + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "xcffib/__init__.py" + (("ctypes\\.util\\.find_library\\(\"xcb\"\\)") + (format #f "~s" + (search-input-file inputs "/lib/libxcb.so.1"))))))))) + (home-page "https://github.com/tych0/xcffib") + (synopsis "XCB Python bindings") + (description + "Xcffib is a replacement for xpyb, an XCB Python bindings. It adds +support for Python 3 and PyPy. It is based on cffi.") + (license license:expat))) + (define-public randrproto (package (name "randrproto")