From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id eEF8JNEGPWEIJgEAgWs5BA (envelope-from ) for ; Sat, 11 Sep 2021 21:43:13 +0200 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id iJn6H9EGPWG5MgAAbx9fmQ (envelope-from ) for ; Sat, 11 Sep 2021 19:43:13 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id A3EB62C69C for ; Sat, 11 Sep 2021 21:43:12 +0200 (CEST) Received: from localhost ([::1]:40338 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mP8u7-0005Gf-9Q for larch@yhetil.org; Sat, 11 Sep 2021 15:43:11 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:54212) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mP8ty-0005G3-Bz for guix-patches@gnu.org; Sat, 11 Sep 2021 15:43:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:58156) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mP8ty-0005aJ-5B for guix-patches@gnu.org; Sat, 11 Sep 2021 15:43:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mP8ty-0003Ej-3R for guix-patches@gnu.org; Sat, 11 Sep 2021 15:43:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#50505] [PATCH 03/12] gnu: Add python-glcontext. Resent-From: Xinglu Chen Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sat, 11 Sep 2021 19:43:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 50505 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 50505@debbugs.gnu.org Cc: Daniel =?UTF-8?Q?Mei=C3=9Fner?= X-Debbugs-Original-To: Daniel =?UTF-8?Q?Mei=C3=9Fner?= via Guix-patches via , 50505@debbugs.gnu.org Received: via spool by submit@debbugs.gnu.org id=B.163138936312410 (code B ref -1); Sat, 11 Sep 2021 19:43:02 +0000 Received: (at submit) by debbugs.gnu.org; 11 Sep 2021 19:42:43 +0000 Received: from localhost ([127.0.0.1]:41467 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mP8te-0003E6-Tj for submit@debbugs.gnu.org; Sat, 11 Sep 2021 15:42:43 -0400 Received: from lists.gnu.org ([209.51.188.17]:43744) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mP8td-0003Du-K6 for submit@debbugs.gnu.org; Sat, 11 Sep 2021 15:42:41 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:54202) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mP8td-0005FV-Cv for guix-patches@gnu.org; Sat, 11 Sep 2021 15:42:41 -0400 Received: from h87-96-130-155.cust.a3fiber.se ([87.96.130.155]:39422 helo=mail.yoctocell.xyz) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mP8tb-0005Ks-6G for guix-patches@gnu.org; Sat, 11 Sep 2021 15:42:41 -0400 From: Xinglu Chen DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=yoctocell.xyz; s=mail; t=1631389353; bh=kRz8Ez4se36gJ/PMHbPjBo8HLbFw3cuGPvs7lMbSwwI=; h=From:To:Cc:Subject:In-Reply-To:References:Date; b=d7DTsDvR84oRjdIV7FXUj8HaEgirhPfel5IcgLw/ywE4BuIJ23WxzZX8/5+lJ13kY B00oDLwQtfOm+mHsJSXMMkErGV98lMlh0PYK98fy0OfteCxOtXDqs1KWF8WDdJvnya 5DUvfzIOZ5iJfpx+tN8G216+wByA8woTgJFEuUkk= In-Reply-To: <20210910112502.6466-3-daniel.meissner-i4k@ruhr-uni-bochum.de> References: <20210910112231.6411-1-daniel.meissner-i4k@ruhr-uni-bochum.de> <20210910112502.6466-1-daniel.meissner-i4k@ruhr-uni-bochum.de> <20210910112502.6466-3-daniel.meissner-i4k@ruhr-uni-bochum.de> Date: Sat, 11 Sep 2021 21:42:32 +0200 Message-ID: <87wnnmucev.fsf@yoctocell.xyz> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" Received-SPF: pass client-ip=87.96.130.155; envelope-from=public@yoctocell.xyz; helo=mail.yoctocell.xyz X-Spam_score_int: 14 X-Spam_score: 1.4 X-Spam_bar: + X-Spam_report: (1.4 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FROM_SUSPICIOUS_NTLD=0.498, PDS_OTHER_BAD_TLD=1.997, RDNS_DYNAMIC=0.982, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no autolearn_force=no X-Spam_action: no action 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+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1631389392; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:resent-cc:resent-from:resent-sender: resent-message-id:in-reply-to:in-reply-to:references:references: list-id:list-help:list-unsubscribe:list-subscribe:list-post: dkim-signature; bh=9D1kx2newdzSy2teHgmrIzbeoPfT7YJS/jnRspLPjiA=; b=OkfAVNZTt2JMAPh71hqyEfFe0nyBAfMsGtrbmg1ZYhBF+WIW29sOMKUX6N5xQadJznrZG9 2XHdp2yvxa4Bm/Z237mmssfT6nLtLbjVZKzkTN68AKcDOLTRTj2RPFOVEgOASHtj0j2hB/ 8eKqax7+hSvVkGe96ujRHFJHlA0qWkS8OhRvp0TSiCIgDbT78s5SG9OH/CmUsrDlQDvRxb BwTCg1z4RZFjgyGZR+rmFRRRlbz658z9nHH4ok/FjsBKiBv18fMTweZVtkTSAmTKyMh9kv surzDtY+R5zp1nRq92WO/vJzsDnKvFiGJtVc/uJI3671IQqHz1NhA4jE2PI4LA== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1631389392; a=rsa-sha256; cv=none; b=ptcA9zsEEl5spOUUkn1Vh42IX+mJFp7xoDstEhIjpZNbJcED3iNfnCbFGTgw4A2bOvj8Rf Qjzu9xYnyLIpfOykvQNawaMT2xIuJs4aEzYGj8DsC1B7xtrNA4HoZXZWxgA+QRZ/ArJtYL g9Euke5ouWlzsOtam8dXNEhfAm1GvrnLbUxN+Lfu13Nlh2Yu4Zrz/FhjAd4BLw9u657OgV XItvw1OSbSiBDtc5nq0xgkGs7q2BRHjt1LUZHC12TB7UPSiYd/sM/bhA3KF2D7CEMkFXzZ 0G4EvZM5VCMLgJr2aaFVd+RtmOLWkOc6k0epglTxni/bW/OpHWvV9EGWiU4mGQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=yoctocell.xyz header.s=mail header.b=d7DTsDvR; spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Spam-Score: -3.41 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=yoctocell.xyz header.s=mail header.b=d7DTsDvR; dmarc=fail reason="SPF not aligned (relaxed)" header.from=yoctocell.xyz (policy=none); spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Queue-Id: A3EB62C69C X-Spam-Score: -3.41 X-Migadu-Scanner: scn0.migadu.com X-TUID: IOxkgVrxDUZy --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On Fri, Sep 10 2021, Daniel Mei=C3=9Fner via Guix-patches via wrote: > * gnu/packages/python-xyz.scm (python-glcontext): New variable. > --- > gnu/packages/python-xyz.scm | 46 +++++++++++++++++++++++++++++++++++++ > 1 file changed, 46 insertions(+) > > diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm > index 75646aec7f..251aad5b61 100644 > --- a/gnu/packages/python-xyz.scm > +++ b/gnu/packages/python-xyz.scm > @@ -18884,6 +18884,52 @@ library.") > (description > "This is the Cython-coded accelerator module for PyOpenGL."))) >=20=20 > +(define-public python-glcontext > + (package > + (name "python-glcontext") > + (version "2.3.4") > + (source > + (origin > + (method git-fetch) > + (uri (git-reference > + (url "https://github.com/moderngl/glcontext") > + (commit version))) > + (file-name (git-file-name name version)) > + (sha256 > + (base32 > + "1m2zkl696vqmgrd5k1c5kl0krk6qgjgsz88qhahwva0l40bswvhp")))) > + (build-system python-build-system) > + (arguments > + '(#:phases > + (modify-phases %standard-phases > + (add-before 'build 'fix-lib-paths > + (lambda* (#:key inputs outputs #:allow-other-keys) > + (substitute* '("glcontext/x11.cpp" "glcontext/egl.cpp") > + (("\"libGL.so\"") > + (string-append "\"" (assoc-ref inputs "mesa") "/lib/libGL= .so\"")) > + (("\"libEGL.so\"") > + (string-append "\"" (assoc-ref inputs "mesa") "/lib/libEG= L.so\"")) > + (("\"libX11.so\"") > + (string-append "\"" (assoc-ref inputs "libx11") "/lib/lib= X11.so\""))) Please keep lines =3D<80 columns wide. Also I would use a =E2=80=98let=E2= =80=99 form to avoid writing (assoc-ref inputs "mesa") twice. > + (substitute* '("glcontext/__init__.py") > + (("find_library\\('GL'\\)") > + (string-append "'" (assoc-ref inputs "mesa") "/lib/libGL.= so'")) > + (("find_library\\('EGL'\\)") > + (string-append "'" (assoc-ref inputs "mesa") "/lib/libEGL= .so'")) Likewise (=E2=80=98let=E2=80=99 form). > + (("find_library\\(\"X11\"\\)") > + (string-append "'" (assoc-ref inputs "libx11") "/lib/libX= 11.so'"))) > + #t)) Phases don=E2=80=99t need to return #t once the =E2=80=98core-updates-froze= n=E2=80=99 branch gets merged, which should happen soon=E2=84=A2. :-) > + ;; tests fail with: Exception: (standalone) XOpenDisplay: cannot= open display > + (delete 'check)))) > + (inputs > + `(("libx11" ,libx11) > + ("mesa" ,mesa))) > + (home-page "https://github.com/moderngl/glcontext") > + (synopsis "Portable OpenGL Context for ModernGL") > + (description "Python-glcontext is a library providing OpenGL implemen= tation > +for ModernGL on multiple platforms.") =E2=80=9Cproviding an OpenGL implementation=E2=80=9D (missing article). --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQJJBAEBCAAzFiEEAVhh4yyK5+SEykIzrPUJmaL7XHkFAmE9BqgVHHB1YmxpY0B5 b2N0b2NlbGwueHl6AAoJEKz1CZmi+1x5tqAP/REzAuTKUh1nza4/oXKVGqnUxm+x Q8yXr68WOqteSFxxOotYJJ2uuNq2cwjBMn8zW8Vng0ThIAXV2/rk4Htprh83jCOF luEMab0YE9qcQgZ4X5HhDm3RxHItgtEtKwlh7fLMfDqChLZg/+absRkNFVgV34/1 rkURFDL9RXLV3qzTvJwENl8kZiEY6w2i8lk+DVJscMByjZtFYPcG16jqpjctGRKq p3KKevB1qGZXyzOyVu4860/Pd5oLWVwrhAygRDfP4YqNishVIwpm2pbDt7nxZ4DE bxKbsDAV2jI6ZikkvcjseeA8MK1I6zQMqVy01XQcdjTPnx0zxGFzgdbvBjFm8D8R mJNfALnHj11ifvQYmPPcp5UYxJ/CWH18lH+d7PkI281Xr0uYSBTelLKlahX+Glwf u8pm1LdKvNLdDe84WnKM0n9ZklM7mbDDXxvpdKd2MmcrzGV/wrAALx/ybv4ty8be QrzWURDy7r65u8LQYbTEXXosbb+HBrlAfonrdJO3Ew7s3kFb88JfFD8RZSpQC8xo oNdIMPyKKgy/xhHZDpsr+HZwO6S1b+/9R3vtLADB28M2YBGKdLG8X1wyMb7ZB2oX NSOaZLa/8lmAMqVPRbKge9gHy3zA5tjCga/lHd7ADnxC5P7tiQufEMheVD0K50yu 53QwRv3xisLknSMn =MEhW -----END PGP SIGNATURE----- --=-=-=--