gnu: colobot: Improve package style.
* gnu/packages/games.scm (colobot)[arguments]: Use G-expressions. <#:phases>: Remove trailing #T. [native-inputs, inputs]: Remove labels.master
parent
b24ec42686
commit
85f934ccff
|
@ -7768,21 +7768,25 @@ Github or Gitlab.")
|
||||||
(base32 "0bpy5nzkvq5nfr0w8jf7bl7zs8yz2cpzp87pnkdlgwl3adcn9nsw"))))
|
(base32 "0bpy5nzkvq5nfr0w8jf7bl7zs8yz2cpzp87pnkdlgwl3adcn9nsw"))))
|
||||||
(build-system cmake-build-system)
|
(build-system cmake-build-system)
|
||||||
(arguments
|
(arguments
|
||||||
`(#:tests? #f ;no test
|
(list
|
||||||
|
#:tests? #f ;no test
|
||||||
|
#:modules '((guix build cmake-build-system)
|
||||||
|
(guix build utils)
|
||||||
|
(srfi srfi-1)
|
||||||
|
(ice-9 match)
|
||||||
|
(ice-9 regex))
|
||||||
#:phases
|
#:phases
|
||||||
(modify-phases %standard-phases
|
#~(modify-phases %standard-phases
|
||||||
(add-after 'unpack 'make-git-checkout-writable
|
(add-after 'unpack 'make-git-checkout-writable
|
||||||
(lambda _
|
(lambda _
|
||||||
(for-each make-file-writable (find-files "."))
|
(for-each make-file-writable (find-files "."))))
|
||||||
#t))
|
|
||||||
(add-after 'unpack 'fix-directories
|
(add-after 'unpack 'fix-directories
|
||||||
(lambda _
|
(lambda _
|
||||||
(substitute* "CMakeLists.txt"
|
(substitute* "CMakeLists.txt"
|
||||||
(("(\\$\\{CMAKE_INSTALL_PREFIX\\})/games" _ prefix)
|
(("(\\$\\{CMAKE_INSTALL_PREFIX\\})/games" _ prefix)
|
||||||
(string-append prefix "/bin"))
|
(string-append prefix "/bin"))
|
||||||
(("(\\$\\{CMAKE_INSTALL_PREFIX\\}/share)/games/colobot" _ prefix)
|
(("(\\$\\{CMAKE_INSTALL_PREFIX\\}/share)/games/colobot" _ prefix)
|
||||||
(string-append prefix "/colobot")))
|
(string-append prefix "/colobot")))))
|
||||||
#t))
|
|
||||||
(add-after 'fix-directories 'install-music
|
(add-after 'fix-directories 'install-music
|
||||||
;; Retrieve and install music files.
|
;; Retrieve and install music files.
|
||||||
(lambda* (#:key inputs #:allow-other-keys)
|
(lambda* (#:key inputs #:allow-other-keys)
|
||||||
|
@ -7792,32 +7796,35 @@ Github or Gitlab.")
|
||||||
(substitute* "data/music/CMakeLists.txt"
|
(substitute* "data/music/CMakeLists.txt"
|
||||||
(("find_program\\(WGET wget\\)") ""))
|
(("find_program\\(WGET wget\\)") ""))
|
||||||
;; Populate "music/" directory.
|
;; Populate "music/" directory.
|
||||||
(let ((data (assoc-ref inputs "colobot-music")))
|
(let ((data
|
||||||
(invoke "tar" "-xvf" data "-Cdata/music"))
|
(any
|
||||||
#t)))))
|
(match-lambda ((_ . input)
|
||||||
|
(and (string-match "colobot-music" input)
|
||||||
|
input)))
|
||||||
|
inputs)))
|
||||||
|
(invoke "tar" "-xvf" data "-Cdata/music")))))))
|
||||||
(native-inputs
|
(native-inputs
|
||||||
`(("colobot-music"
|
(list (origin
|
||||||
,(origin
|
|
||||||
(method url-fetch)
|
(method url-fetch)
|
||||||
(uri (string-append "https://colobot.info/files/music/"
|
(uri (string-append "https://colobot.info/files/music/"
|
||||||
"colobot-music_ogg_" version ".tar.gz"))
|
"colobot-music_ogg_" version ".tar.gz"))
|
||||||
(sha256
|
(sha256
|
||||||
(base32
|
(base32
|
||||||
"1s86cd36rwkff329mb1ay1wi5qqyi35564ppgr3f4qqz9wj9vs2m"))))
|
"1s86cd36rwkff329mb1ay1wi5qqyi35564ppgr3f4qqz9wj9vs2m")))
|
||||||
("gettext" ,gettext-minimal)
|
gettext-minimal
|
||||||
("librsvg" ,(librsvg-for-system))
|
(librsvg-for-system)
|
||||||
("po4a" ,po4a)
|
po4a
|
||||||
("python" ,python-wrapper)))
|
python-wrapper))
|
||||||
(inputs
|
(inputs
|
||||||
`(("boost" ,boost)
|
(list boost
|
||||||
("glew" ,glew)
|
glew
|
||||||
("libogg" ,libogg)
|
libogg
|
||||||
("libpng" ,libpng)
|
libpng
|
||||||
("libsndfile" ,libsndfile)
|
libsndfile
|
||||||
("libvorbis" ,libvorbis)
|
libvorbis
|
||||||
("openal" ,openal)
|
openal
|
||||||
("physfs" ,physfs)
|
physfs
|
||||||
("sdl" ,(sdl-union (list sdl2 sdl2-image sdl2-ttf)))))
|
(sdl-union (list sdl2 sdl2-image sdl2-ttf))))
|
||||||
(synopsis "Educational programming strategy game")
|
(synopsis "Educational programming strategy game")
|
||||||
(description "Colobot: Gold Edition is a real-time strategy game, where
|
(description "Colobot: Gold Edition is a real-time strategy game, where
|
||||||
you can program your units (bots) in a language called CBOT, which is similar
|
you can program your units (bots) in a language called CBOT, which is similar
|
||||||
|
|
Reference in New Issue