From e738804f00ffc31e937b9d47ddf4f32d05059383 Mon Sep 17 00:00:00 2001 From: Sisiutl Date: Mon, 14 Oct 2024 10:11:01 +0200 Subject: add python-pyopengl --- sigils/packages/python-xyz.scm | 272 ++++++++++++++++++++++++++++++++++++----- 1 file changed, 241 insertions(+), 31 deletions(-) (limited to 'sigils/packages/python-xyz.scm') diff --git a/sigils/packages/python-xyz.scm b/sigils/packages/python-xyz.scm index 0ff9099..7dff2c9 100644 --- a/sigils/packages/python-xyz.scm +++ b/sigils/packages/python-xyz.scm @@ -11,11 +11,59 @@ #:use-module (gnu packages python-build) #:use-module (gnu packages python-web) ;; chepy + #:use-module (gnu packages) + #:use-module (gnu packages bash) + #:use-module (gnu packages compression) #:use-module (gnu packages python-compression) #:use-module (gnu packages python-crypto) + #:use-module (gnu packages python-check) #:use-module (gnu packages python-xyz) #:use-module (gnu packages python-web) #:use-module (gnu packages xdisorg)) + ;; pyopengl + + +(define-public python-pyopengl + (package + (name "python-pyopengl") + (version "3.1.6") + (source + (origin + (method url-fetch) + (uri (pypi-uri "PyOpenGL" version)) + (sha256 + (base32 + "09syrsfrcknr1k2wmj05gfd5d0dyjfxzbipzbd0agv9775vwi9lf")))) + (build-system python-build-system) + (inputs + (list mesa freeglut glu)) + (arguments + `(#:phases + (modify-phases %standard-phases + (add-before 'build 'fix-paths + (lambda* (#:key inputs outputs #:allow-other-keys) + (substitute* '("OpenGL/platform/ctypesloader.py") + (("filenames_to_try = \\[\\]") "filenames_to_try = [name]")) + (substitute* '("OpenGL/platform/glx.py" + "OpenGL/platform/egl.py" + "OpenGL/platform/osmesa.py" + "OpenGL/platform/darwin.py" + "tests/check_glut_load.py") + (("'GLU'") + (string-append "'" (assoc-ref inputs "glu") "/lib/libGLU.so'")) + (("'glut',") + (string-append "'" (assoc-ref inputs "freeglut") "/lib/libglut.so',")) + (("'(GL|EGL|GLESv1_CM|GLESv2|OSMesa)'" all gl-library) + (string-append "'" (assoc-ref inputs "mesa") (string-append "/lib/lib" gl-library ".so'")))) + ;; Not providing libgle. It seems to be very old. + #t))))) + (home-page "https://pyopengl.sourceforge.net") + (synopsis "Standard OpenGL bindings for Python") + (description + "PyOpenGL is the most common cross platform Python binding to OpenGL and +related APIs. The binding is created using the standard @code{ctypes} +library.") + (license license:bsd-3))) ;;; Chepy @@ -47,6 +95,13 @@ (origin (method url-fetch) (uri (pypi-uri "chepy" version)) + (patches + (parameterize + ((%patch-path + (map (lambda (directory) + (string-append directory "/sigils/packages/patches")) + %load-path))) + (search-patches "chepy-recent-pyopenssl.patch"))) (sha256 (base32 "1f05psh1xbzppb9jdfc26i6bxw3dd7i0c0lqggh6wzmy4cpszybz")))) (build-system pyproject-build-system) @@ -54,36 +109,158 @@ (synopsis "Chepy is a python library equivalent of the CyberChef tool.") (description "Chepy is a python library with a CLI that is aimed to mirror some of the capabilities of CyberChef.") - (native-inputs (list python-base58 - python-colorama - python-crccheck - python-decorator - python-docstring-parser - python-emoji - ;; python-exrex - python-fire - ;; python-lazy-import - ;; python-hexdump - python-jsonpickle - python-jmespath - python-prompt-toolkit - ;; python-pycipher - python-pycryptodome - ;; python-pydash - python-pyjwt - python-pyopenssl - python-pyperclip - python-pyyaml - python-regex - python-typing-extensions - python-pretty-errors - python-lz4 - python-passlib - python-msgpack - python-parsel - python-setuptools)) + (inputs (list python-base58 + python-colorama + python-crccheck + python-decorator + python-docstring-parser + python-emoji + ;; python-exrex + python-fire + ;; python-lazy-import + python-hexdump + python-jsonpickle + python-jmespath + python-prompt-toolkit + python-pycipher + python-pycryptodome + python-pydash + python-pyjwt + python-pyopenssl + python-pyperclip + python-pyyaml + python-regex + python-typing-extensions + python-pretty-errors + python-lz4 + python-passlib + python-msgpack + python-parsel + python-setuptools)) (license license:gpl3))) +(define-public python-hexdump + (package + (name "python-hexdump") + (version "3.3") + (source + (origin + (method url-fetch) + (uri (pypi-uri "hexdump" version ".zip")) + (sha256 + (base32 "1nr0dy3m8grdmd2hp3ym6x8vv9yki8zfgbba6vwy7b0n1hxs90fp")))) + (build-system python-build-system) + (native-inputs (list unzip)) + (arguments '(#:tests? #f)) ;; No tests. + (home-page "https://bitbucket.org/techtonik/hexdump/") + (synopsis "dump binary data to hex format and restore from there") + (description "dump binary data to hex format and restore from there.") + (license #f))) + +(define-public python-pycipher + (package + (name "python-pycipher") + (version "0.5.2") + (source + (origin + (method url-fetch) + (uri (pypi-uri "pycipher" version ".zip")) + (sha256 + (base32 "06yp9kn8x653324b3rdfd038bpvmd94rqbv4w44xl126fgpv7cz5")))) + (build-system pyproject-build-system) + (native-inputs (list unzip python-tox)) + (arguments '(#:tests? #f)) ;; See you later, alligator. + (home-page "https://github.com/jameslyons/pycipher") + (synopsis "Several simple cipher algorithms") + (description "Several simple cipher algorithms.") + (license #f))) + +(define-public python-pydash + (package + (name "python-pydash") + (version "8.0.3") + (source + (origin + (method url-fetch) + (uri (pypi-uri "pydash" version)) + (sha256 + (base32 "1amrz28qs8hvzlgn6bj66rlpkbw2zlx54v3qzzjz0wjvl0yws9qv")))) + (build-system pyproject-build-system) + (inputs (list python-typing-extensions)) + ;; (native-inputs (list ;;python-build + ;; python-coverage + ;; ;; python-furo + ;; python-invoke + ;; python-mypy + ;; python-pytest + ;; python-pytest-cov + ;; python-pytest-mypy-testing + ;; ;; python-ruff + ;; ;; python-sphinx + ;; ;; python-sphinx-autodoc-typehints + ;; python-tox + ;; python-twine + ;; python-wheel)) + (arguments '(#:tests? #f)) ;; See you later, alligator. + (home-page "https://github.com/dgilland/pydash") + (synopsis "The kitchen sink of Python utility libraries for doing \"stuff\" in a functional way.") + (description + "The kitchen sink of Python utility libraries for doing \"stuff\" in a functional +way. Based on the Lo-Dash Javascript library.") + (license #f))) + +(define-public python-invoke + (package + (name "python-invoke") + (version "2.2.0") + (source + (origin + (method url-fetch) + (uri (pypi-uri "invoke" version)) + (sha256 + (base32 "1mbbixban0238bwkadgynw60n0jrq1ja5wl4zv3mka7i388bnv7f")))) + (build-system pyproject-build-system) + (arguments + ;; XXX: Tests require invocations, a package that requires... python-invoke. + `(#:tests? #f + #:phases + (modify-phases %standard-phases + (add-after 'unpack 'fix-bash-path + (lambda* (#:key inputs #:allow-other-keys) + (let ((bash (assoc-ref inputs "bash"))) + (substitute* "invoke/config.py" + (("shell = \"/bin/bash\"") + (string-append "shell = \"" bash "/bin/bash\""))))))))) + (inputs + `(("bash" ,bash-minimal))) + (home-page "https://pyinvoke.org") + (synopsis "Pythonic task execution") + (description + "Invoke is a Python task execution tool and library, drawing inspiration + from various sources to arrive at a powerful and clean feature set. It is + evolved from the Fabric project, but focuses on local and abstract concerns + instead of servers and network commands.") + (license license:bsd-3))) + +(define-public python-pytest-mypy-testing + (package + (name "python-pytest-mypy-testing") + (version "0.1.3") + (source + (origin + (method url-fetch) + (uri (pypi-uri "pytest-mypy-testing" version)) + (sha256 + (base32 "10g2r7n3y0pvy6m77qdl3v86k5p229b34d2sp1a6spsx5wil2k5d")))) + (build-system pyproject-build-system) + (inputs (list python-mypy)) + (native-inputs (list python-flit-core + python-pytest)) + (home-page "https://github.com/davidfritzsche/pytest-mypy-testing") + (synopsis "Pytest plugin to check mypy output.") + (description "Pytest plugin to check mypy output.") + (license license:expat))) + ;;; Discord.py-self (define-public python-discord-protos @@ -114,13 +291,15 @@ (sha256 (base32 "05xyd7d1mzn3xsw6crl2bp8y0k71dk07jfadvk9w4x880vk3nr4g")))) (build-system pyproject-build-system) - (inputs (list python-aiohttp python-discord-protos python-protobuf)) + (inputs (list python-aiohttp + python-protobuf + python-discord-protos + python-typing-extensions)) (native-inputs (list python-coverage python-pytest python-pytest-asyncio python-pytest-cov - python-pytest-mock - python-typing-extensions)) + python-pytest-mock)) (arguments '(#:tests? #f)) (home-page "https://github.com/dolfies/discord.py-self") @@ -128,3 +307,34 @@ (description "This package provides a Python wrapper for the Discord user API.") (license license:expat))) + +(define-public python-picamera2 + (package + (name "python-picamera2") + (version "0.3.22") + (source + (origin + (method url-fetch) + (uri (pypi-uri "picamera2" version)) + (sha256 + (base32 "0bc3sr3adahddzs3j9i1yndl962qc0dpmpmq9f3wpfs28f0nja49")))) + (build-system pyproject-build-system) + (propagated-inputs (list python-av + python-numpy + python-pidng + python-piexif + python-pillow + python-prctl + python-jsonschema + python-libarchive-c + python-tqdm)) + ;; python-simplejpeg + ;; python-v4l2-python3)) + (home-page "https://github.com/RaspberryPi/picamera2") + (synopsis + "libcamera-based Python interface to Raspberry Pi cameras") + (description + "The libcamera-based Python interface to Raspberry Pi cameras, based on +the original Picamera library.") + (license #f))) + -- cgit v1.2.3