[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
01/02: gnu: Fix OpenSFX build.
From: |
guix-commits |
Subject: |
01/02: gnu: Fix OpenSFX build. |
Date: |
Fri, 30 Jul 2021 09:25:08 -0400 (EDT) |
leoprikler pushed a commit to branch master
in repository guix.
commit 0a1df50e9f9a62f4c2df6cf69d5f05f74816ceb7
Author: Leo Prikler <leo.prikler@student.tugraz.at>
AuthorDate: Fri Jul 30 15:02:45 2021 +0200
gnu: Fix OpenSFX build.
OpenSFX 1.0.1 uses a different build system from the old one, which causes
weird errors.
* gnu/packages/games.scm (openttd-opensfx)[native-inputs]: Add tar.
[#:make-flags]: Drop INSTALL_DIR. Add DIR_NAME and TAR.
[#:tests?]: New argument.
[#:phases]: Add ‘prebuild’. Replace ‘install’ with a simple copy.
---
gnu/packages/games.scm | 20 ++++++++++++++++----
1 file changed, 16 insertions(+), 4 deletions(-)
diff --git a/gnu/packages/games.scm b/gnu/packages/games.scm
index a6be36d..1571208 100644
--- a/gnu/packages/games.scm
+++ b/gnu/packages/games.scm
@@ -4437,11 +4437,15 @@ OpenGFX provides you with...
(build-system gnu-build-system)
(native-inputs
`(("catcodec" ,catcodec)
- ("python" ,python-2)))
+ ("python" ,python-2)
+ ("tar" ,tar)))
(arguments
`(#:make-flags
- (list (string-append "INSTALL_DIR=" %output
- "/share/games/openttd/baseset/opensfx"))
+ (list (string-append "DIR_NAME=opensfx")
+ (string-append "TAR=" (assoc-ref %build-inputs "tar")
+ "/bin/tar"))
+ ;; The check phase only verifies md5sums, see openttd-opengfx.
+ #:tests? #f
#:phases
(modify-phases %standard-phases
(add-after 'unpack 'make-reproducible
@@ -4451,7 +4455,15 @@ OpenGFX provides you with...
(substitute* "scripts/Makefile.def"
(("-cf") " --mtime=@0 -cf"))
#t))
- (delete 'configure))))
+ (delete 'configure)
+ (add-before 'build 'prebuild
+ (lambda _ (invoke "make" "opensfx.cat")))
+ (replace 'install
+ (lambda* (#:key outputs #:allow-other-keys)
+ (copy-recursively "opensfx"
+ (string-append (assoc-ref outputs "out")
+ "/share/games/openttd/baseset"
+ "/opensfx")))))))
(home-page "http://dev.openttdcoop.org/projects/opensfx")
(synopsis "Base sounds for OpenTTD")
(description "OpenSFX is a set of free base sounds for OpenTTD which make