From 2774ef1b4a64b724d13bede0baaf1566287d63b2 Mon Sep 17 00:00:00 2001 From: Vinicius Monego Date: Sat, 28 Jun 2025 10:18:26 -0300 Subject: [PATCH] gnu: Add python-pygame-ce. * gnu/packages/game-development.scm (python-pygame-ce): New variable. Change-Id: I527c06f0c081702306247db5969a7f0b26890c81 --- gnu/packages/game-development.scm | 67 +++++++++++++++++++++++++++++++ 1 file changed, 67 insertions(+) diff --git a/gnu/packages/game-development.scm b/gnu/packages/game-development.scm index 61520575a8ba1f6f570411f31e0774c3a9a400d5..d1642fa59abf554c43209ef4488b2a804d2513b7 100644 --- a/gnu/packages/game-development.scm +++ b/gnu/packages/game-development.scm @@ -36,6 +36,7 @@ ;;; Copyright © 2025 Sharlatan Hellseher ;;; Copyright © 2025 宋文武 ;;; Copyright © 2025 Arnaud Lechevallier +;;; Copyright © 2025 Vinicius Monego ;;; ;;; This file is part of GNU Guix. ;;; @@ -1628,6 +1629,72 @@ While it aims to be used as a drop-in replacement, it appears to be developed mainly for Ren'py.") (license (list license:lgpl2.1 license:zlib))))) +(define-public python-pygame-ce + (package + (name "python-pygame-ce") + (version "2.5.5") + (source + (origin + (method url-fetch) + (uri (pypi-uri "pygame_ce" version)) + (sha256 + (base32 "0sxfchimdg606z65qychgvm66mq0aybs2isxsqb5zqy64g19gwm7")))) + (build-system pyproject-build-system) + (arguments + (list + #:test-flags + #~(list "-k" (string-join + ;; Ignore interactive tests first. + (list "not DisplayUpdateInteractiveTest" + "DisplayInteractiveTest" + "FullScreenToggleTestsInteractive" + "MessageBoxInteractiveTest" + "VisualTestsInteractive" + "TouchInteractiveTest" + ;; Pytest error reading from stdin + "test__get_count_interactive" + "test_get_count_interactive" + "test_set_source_location" + ;; Will not convert image with alpha channel to RGB + "testSavePNG24" + "testSavePNG8" + "testSavePaletteAsPNG8" + ;; Content could not be saved in clipboard + "test_get__owned_empty_type" + "test_init__reinit" + "test_put" + "test_put__bmp_image" + "test_put__text" + "test_issue_223" + ;; AssertionError + "test_palette_colorkey" + "test_palette_colorkey_fill" + "test_palette_colorkey_set_px" + "test_create_aliases" + ;; Possibly flaky tests + "test_multiple_timers" + "test_timer_common_reference") + " and not ")) + #:phases #~(modify-phases %standard-phases + (add-before 'check 'pre-check + (lambda _ + (setenv "HOME" "/tmp") + (setenv "SDL_VIDEODRIVER" "dummy") + (setenv "SDL_AUDIODRIVER" "disk")))))) + (native-inputs (list meson-python + pkg-config + python-cython-3 + python-numpy + python-pytest + python-setuptools)) + (inputs (list freetype portmidi sdl2 sdl2-image sdl2-mixer sdl2-ttf)) + (home-page "https://pyga.me/") + (synopsis "Python Game Development") + (description "Pygame-CE is a fork of the upstream pygame project by its +former core developers. It aims to offer more frequent releases, continuous +bugfixes and enhancements, and a new governance model.") + (license license:lgpl2.1+))) + (define-public python-renpy (package (name "python-renpy")