gnu: python-efl: Update to 1.26.1.

* gnu/packages/enlightenment.scm (python-efl): Update to 1.26.1.
[build-system]: Switch to pyproject-build-system.
[arguments]<#:test-flags>: Ignore failing tests.
<#:phases>: Improve readability.
[native-inputs]: Add python-pytest, python-setuptools.

Change-Id: I0f06150d89fd6f0703ad31d1ba6589c41bc9d1ae
Signed-off-by: Sharlatan Hellseher <sharlatanus@gmail.com>
This commit is contained in:
Nicolas Graves 2025-12-21 23:51:27 +01:00 committed by Sharlatan Hellseher
parent bf6d52423e
commit 45684d45b4
No known key found for this signature in database
GPG key ID: 76D727BFF62CD2B5

View file

@ -392,50 +392,56 @@ embedded systems.")
(define-public python-efl
(package
(name "python-efl")
(version "1.26.0")
(version "1.26.1")
(source
(origin
(method url-fetch)
(uri (string-append "https://download.enlightenment.org/rel/bindings/"
"python/python-efl-" version ".tar.xz"))
(sha256
(base32
"0dj6f24n33hkpy0bkdclnzpxhvs8vpaxqaf7hkw0di19pjwrq25h"))
(modules '((guix build utils)))
;; Remove files generated by Cython
(snippet
'(begin
(for-each (lambda (file)
(let ((generated-file
(string-append (string-drop-right file 3) "c")))
(when (file-exists? generated-file)
(delete-file generated-file))))
(find-files "efl" "\\.pyx$"))
(delete-file "efl/eo/efl.eo_api.h")))))
(build-system python-build-system)
(origin
(method url-fetch)
(uri (string-append "https://download.enlightenment.org/rel/bindings/"
"python/python-efl-" version ".tar.xz"))
(sha256
(base32 "1mr80vgbcs03rs5lbmg8pxj8hifkrzrwdrw01plik2h729z3knyw"))
(modules '((guix build utils)))
;; Remove files generated by Cython
(snippet
'(begin
(for-each (lambda (file)
(let ((generated-file
(string-append (string-drop-right file 3) "c")))
(when (file-exists? generated-file)
(delete-file generated-file))))
(find-files "efl" "\\.pyx$"))
(delete-file "efl/eo/efl.eo_api.h")))))
(build-system pyproject-build-system)
(arguments
'(#:phases
(modify-phases %standard-phases
(replace 'build
(lambda _
(setenv "ENABLE_CYTHON" "1")
(invoke "python" "setup.py" "build")))
(add-before 'build 'set-flags
(lambda _
(setenv "CFLAGS"
(string-append "-I" (assoc-ref %build-inputs "python-dbus")
"/include/dbus-1.0"))))
(add-before 'check 'set-environment
(lambda _
;; Some tests require write access to HOME.
(setenv "HOME" "/tmp")
;; These tests try to connect to the internet.
(delete-file "tests/ecore/test_09_file_download.py")
(delete-file "tests/ecore/test_11_con.py"))))))
(list
#:test-flags
#~(list "tests"
;; These tests try to connect to the internet.
"--ignore=tests/ecore/test_09_file_download.py"
"--ignore=tests/ecore/test_11_con.py"
;; The above test ignorance probably breaks this one.
"--deselect=tests/ecore/test_08_exe.py::TestExe::testInit"
;; This test requires access to a running Xorg server,
;; /var/lib/dbus and /etc.
"--ignore=tests/dbus/test_01_basics.py"
;; XXX: RuntimeWarning: Setting standard icon failed
"--ignore=tests/elementary/test_02_image_icon.py")
#:phases
#~(modify-phases %standard-phases
(add-before 'build 'set-flags
(lambda* (#:key inputs #:allow-other-keys)
(let ((include-dir (search-input-directory inputs
"include/dbus-1.0")))
(setenv "CFLAGS" (string-append "-I" include-dir)))))
(add-before 'check 'configure-tests
(lambda _
(setenv "HOME" "/tmp")))))) ;needed by tests
(native-inputs
(list pkg-config python-cython-0))
(inputs
(list efl python-dbus python-packaging))
(list pkg-config
python-cython-0
python-pytest
python-setuptools))
(inputs (list efl python-dbus python-packaging))
(home-page "https://www.enlightenment.org/")
(synopsis "Python bindings for EFL")
(description