Archived
1
0
Fork 0

gnu: godot: Use scons-build-system.

* gnu/packages/game-development.scm (godot): Switch to scons-build-system.
This commit is contained in:
Arun Isaac 2017-11-17 14:47:46 +05:30
parent 9364a520ce
commit 92b51d127f
No known key found for this signature in database
GPG key ID: 2E25EE8B61802BB3

View file

@ -37,6 +37,7 @@
#:use-module (guix build-system cmake) #:use-module (guix build-system cmake)
#:use-module (guix build-system gnu) #:use-module (guix build-system gnu)
#:use-module (guix build-system python) #:use-module (guix build-system python)
#:use-module (guix build-system scons)
#:use-module (gnu packages) #:use-module (gnu packages)
#:use-module (gnu packages autotools) #:use-module (gnu packages autotools)
#:use-module (gnu packages boost) #:use-module (gnu packages boost)
@ -1063,12 +1064,26 @@ games.")
(file-name (string-append name "-" version)) (file-name (string-append name "-" version))
(sha256 (sha256
(base32 "1mz89nafc1m7srbqvy7iagxrxmqvf5hbqi7i0lwaapkx6q0kpkq7")))) (base32 "1mz89nafc1m7srbqvy7iagxrxmqvf5hbqi7i0lwaapkx6q0kpkq7"))))
(build-system gnu-build-system) (build-system scons-build-system)
(arguments (arguments
`(#:tests? #f ; There are no tests `(#:scons ,scons-python2
#:scons-flags (list "platform=x11"
;; Avoid using many of the bundled libs.
;; Note: These options can be found in the SConstruct file.
"builtin_freetype=no"
"builtin_glew=no"
"builtin_libmpdec=no"
"builtin_libogg=no"
"builtin_libpng=no"
"builtin_libtheora=no"
"builtin_libvorbis=no"
"builtin_libwebp=no"
"builtin_openssl=no"
"builtin_opus=no"
"builtin_zlib=no")
#:tests? #f ; There are no tests
#:phases #:phases
(modify-phases %standard-phases (modify-phases %standard-phases
(delete 'configure)
(add-after 'unpack 'scons-use-env (add-after 'unpack 'scons-use-env
(lambda _ (lambda _
;; Scons does not use the environment variables by default, ;; Scons does not use the environment variables by default,
@ -1079,24 +1094,6 @@ games.")
"env_base = Environment(tools=custom_tools)\n" "env_base = Environment(tools=custom_tools)\n"
"env_base = Environment(ENV=os.environ)"))) "env_base = Environment(ENV=os.environ)")))
#t)) #t))
(replace 'build
(lambda _
(zero? (system*
"scons"
"platform=x11"
;; Avoid using many of the bundled libs.
;; Note: These options can be found in the SConstruct file.
"builtin_freetype=no"
"builtin_glew=no"
"builtin_libmpdec=no"
"builtin_libogg=no"
"builtin_libpng=no"
"builtin_libtheora=no"
"builtin_libvorbis=no"
"builtin_libwebp=no"
"builtin_openssl=no"
"builtin_opus=no"
"builtin_zlib=no"))))
(replace 'install (replace 'install
(lambda* (#:key outputs #:allow-other-keys) (lambda* (#:key outputs #:allow-other-keys)
(let* ((out (assoc-ref outputs "out")) (let* ((out (assoc-ref outputs "out"))
@ -1128,8 +1125,7 @@ games.")
Type=Application~%" Type=Application~%"
out))) out)))
#t)))))) #t))))))
(native-inputs `(("pkg-config" ,pkg-config) (native-inputs `(("pkg-config" ,pkg-config)))
("scons" ,scons)))
(inputs `(("alsa-lib" ,alsa-lib) (inputs `(("alsa-lib" ,alsa-lib)
("freetype" ,freetype) ("freetype" ,freetype)
("glew" ,glew) ("glew" ,glew)
@ -1144,8 +1140,7 @@ games.")
("mesa" ,mesa) ("mesa" ,mesa)
("openssl" ,openssl) ("openssl" ,openssl)
("opusfile" ,opusfile) ("opusfile" ,opusfile)
("pulseaudio" ,pulseaudio) ("pulseaudio" ,pulseaudio)))
("python2" ,python-2)))
(home-page "https://godotengine.org/") (home-page "https://godotengine.org/")
(synopsis "Advanced 2D and 3D game engine") (synopsis "Advanced 2D and 3D game engine")
(description (description