1
0
mirror of https://git.savannah.gnu.org/git/guix.git synced 2026-04-06 21:20:33 +02:00

gnu: python-pcpp: Switch to pyproject.

* gnu/packages/c.scm (python-pcpp):
[build-system]: Switch to pyproject-build-system.
[arguments]<#:test-backend, #:test-flags>: Set them.
[native-inputs]: Add python-setuptools.
[description]: Improve style.

Change-Id: Ib73ee56a32f3ad92adaff6127f3bfcb5e1d0a801
Signed-off-by: Sharlatan Hellseher <sharlatanus@gmail.com>
This commit is contained in:
Nicolas Graves
2025-12-22 18:03:58 +01:00
committed by Sharlatan Hellseher
parent 0b763df3a6
commit a881defc09

View File

@@ -51,6 +51,7 @@
#:use-module (guix build-system copy)
#:use-module (guix build-system gnu)
#:use-module (guix build-system meson)
#:use-module (guix build-system pyproject)
#:use-module (guix build-system python)
#:use-module (guix store)
#:use-module (gnu packages)
@@ -72,6 +73,7 @@
#:use-module (gnu packages ncurses)
#:use-module (gnu packages pcre)
#:use-module (gnu packages python)
#:use-module (gnu packages python-build)
#:use-module (gnu packages python-xyz)
#:use-module (gnu packages autotools)
#:use-module (gnu packages gettext)
@@ -466,23 +468,26 @@ language as input.")
(commit (string-append "v" version))))
(file-name (git-file-name name version))
(sha256
(base32
"1rihvlg11nzk70kfzz4i3gi5izcy46w05ismcx04p5j1hlim0brb"))))
(build-system python-build-system)
(base32 "1rihvlg11nzk70kfzz4i3gi5izcy46w05ismcx04p5j1hlim0brb"))))
(build-system pyproject-build-system)
(arguments
(list
#:phases #~(modify-phases %standard-phases
(add-after 'unpack 'unbundle-ply
(lambda _
(rmdir "pcpp/ply")
(substitute* "setup.py"
(("'pcpp/ply/ply'") "")))))))
(native-inputs (list python-pytest))
#:test-backend #~'unittest
#:test-flags #~(list "discover" "-s" "tests" "-p" "*.py")
#:phases
#~(modify-phases %standard-phases
(add-after 'unpack 'unbundle-ply
(lambda _
(rmdir "pcpp/ply")
(substitute* "setup.py"
(("'pcpp/ply/ply'")
"")))))))
(native-inputs (list python-setuptools))
(propagated-inputs (list python-ply))
(home-page "https://github.com/ned14/pcpp")
(synopsis "C99 preprocessor written in Python")
(description "This package provides a C99 preprocessor written in pure
Python.")
(description
"This package provides a C99 preprocessor written in pure Python.")
(license license:bsd-3)))
(define-public aml