gnu: pygame-sdl2-for-renpy: Drop generated sources in snippet.

* gnu/packages/game-development.scm (pygame-sdl2-for-renpy)[source]<modules>:
Add (guix build utils).
[#:phases]<drop-generated-files>: Move from here...
[source]<snippet>: ... to here.

Signed-off-by: Nicolas Goaziou <mail@nicolasgoaziou.fr>
This commit is contained in:
Leo Prikler 2020-12-10 20:03:11 +01:00 committed by Nicolas Goaziou
parent b828057ea4
commit 2a951e87c5
No known key found for this signature in database
GPG key ID: DA00B4F048E92F2D

View file

@ -1071,7 +1071,14 @@ (define-public python2-pygame-sdl2
(method url-fetch)
(uri (string-append "https://www.renpy.org/dl/" renpy-version
"/pygame_sdl2-" version ".tar.gz"))
(sha256 (base32 "1bmr7j9mlsc4czpgw70ld15ymyp4wxrk9hdsqad40wjwdxvvg2dr"))))
(sha256 (base32 "1bmr7j9mlsc4czpgw70ld15ymyp4wxrk9hdsqad40wjwdxvvg2dr"))
(modules '((guix build utils)))
(snippet
'(begin
;; drop generated sources
(delete-file-recursively "gen")
(delete-file-recursively "gen3")
#t))))
(build-system python-build-system)
(arguments
`(#:tests? #f ; tests require pygame to be installed first
@ -1090,11 +1097,6 @@ (define-public python2-pygame-sdl2
"/lib -Wl,-rpath,"
(assoc-ref inputs "sdl-union")
"/lib -Wl,--enable-new-dtags -lSDL2"))
#t))
(add-before 'build 'drop-generated-files
(lambda args
(delete-file-recursively "gen")
(delete-file-recursively "gen3")
#t)))))
(inputs
`(("sdl-union"