From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:50332) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dMeH1-00054K-Ta for guix-patches@gnu.org; Sun, 18 Jun 2017 13:46:08 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dMeGy-0007QZ-Lx for guix-patches@gnu.org; Sun, 18 Jun 2017 13:46:07 -0400 Received: from debbugs.gnu.org ([208.118.235.43]:52631) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dMeGy-0007QS-Hw for guix-patches@gnu.org; Sun, 18 Jun 2017 13:46:04 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1dMeGy-0002BQ-CN for guix-patches@gnu.org; Sun, 18 Jun 2017 13:46:04 -0400 Subject: [bug#27421] [PATCH 5/5] gnu: openttd-engine: Add 'install-data' phase. Resent-Message-ID: From: Kei Kebreau Date: Sun, 18 Jun 2017 13:45:19 -0400 Message-Id: <20170618174519.32747-4-kei@openmailbox.org> In-Reply-To: <20170618174519.32747-1-kei@openmailbox.org> References: <20170618174519.32747-1-kei@openmailbox.org> List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+kyle=kyleam.com@gnu.org Sender: "Guix-patches" To: 27421@debbugs.gnu.org Cc: Kei Kebreau * gnu/packages/games.scm (openttd-engine): Rename package to openttd. [arguments]: Add it. [native-inputs]: Add openttd-opengfx. --- gnu/packages/games.scm | 28 +++++++++++++++++----------- 1 file changed, 17 insertions(+), 11 deletions(-) diff --git a/gnu/packages/games.scm b/gnu/packages/games.scm index 4214a2f75..112e1c3db 100644 --- a/gnu/packages/games.scm +++ b/gnu/packages/games.scm @@ -2236,9 +2236,9 @@ and a game metadata scraper.") (home-page "http://www.emulationstation.org") (license license:expat)))) -(define openttd-engine +(define-public openttd (package - (name "openttd-engine") + (name "openttd") (version "1.7.1") (source (origin (method url-fetch) @@ -2269,8 +2269,20 @@ and a game metadata scraper.") (string-append "--with-liblzo2=" lzo "/lib/liblzo2.a") ;; Put the binary in 'bin' instead of 'games'. - "--binary-dir=bin")))))))) - (native-inputs `(("pkg-config" ,pkg-config))) + "--binary-dir=bin"))))) + (add-after 'install 'install-data + (lambda* (#:key inputs outputs #:allow-other-keys) + (let* + ((opengfx (assoc-ref inputs "opengfx")) + (out (assoc-ref outputs "out")) + (gfx-dir + (string-append out "/share/games/openttd/baseset/opengfx"))) + (mkdir-p gfx-dir) + (copy-recursively opengfx gfx-dir)) + #t))))) + (native-inputs + `(("opengfx" ,openttd-opengfx) + ("pkg-config" ,pkg-config))) (inputs `(("allegro" ,allegro-4) ("fontconfig" ,fontconfig) @@ -2316,8 +2328,7 @@ engine. When you start it you will be prompted to download a graphics set.") (arguments '(#:make-flags (list "CC=gcc" (string-append "INSTALL_DIR=" - (assoc-ref %outputs "out") - "/share/openttd/baseset")) + (assoc-ref %outputs "out"))) #:phases (modify-phases %standard-phases (replace 'configure @@ -2349,11 +2360,6 @@ OpenTTD can be shipped finally fully functional without the need for additional downloads.") (license license:gpl2))) -(define-public openttd - (package - (inherit openttd-engine) - (name "openttd"))) - (define-public pinball (package (name "pinball") -- 2.13.0