From mboxrd@z Thu Jan 1 00:00:00 1970 From: Albin Subject: [PATCH] gnu: Add openttd Date: Tue, 12 Apr 2016 00:41:58 +0200 Message-ID: <570C2836.7030100@fripost.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="dr3WjASoEJx8wE3KVgSB53NuKhp2gTQ0S" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:33993) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1apkXA-00018x-7k for guix-devel@gnu.org; Mon, 11 Apr 2016 18:42:17 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1apkX6-0003WS-Va for guix-devel@gnu.org; Mon, 11 Apr 2016 18:42:16 -0400 Received: from giraff.fripost.org ([178.16.208.44]:52822 helo=outgoing.fripost.org) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1apkX6-0003TT-Gq for guix-devel@gnu.org; Mon, 11 Apr 2016 18:42:12 -0400 Received: from localhost (localhost [127.0.0.1]) by outgoing.fripost.org (Postfix) with ESMTP id 7B4454E4A64 for ; Tue, 12 Apr 2016 00:42:06 +0200 (CEST) Received: from outgoing.fripost.org ([127.0.0.1]) by localhost (giraff.fripost.org [127.0.0.1]) (amavisd-new, port 10040) with LMTP id GHjeXVsbgl6P for ; Tue, 12 Apr 2016 00:42:06 +0200 (CEST) Received: from smtp.fripost.org (mistral.fripost.org [178.16.208.43]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mistral.fripost.org", Issuer "mistral.fripost.org" (not verified)) by outgoing.fripost.org (Postfix) with ESMTPS id 3EBE14E4A5C for ; Tue, 12 Apr 2016 00:42:06 +0200 (CEST) Received: from [127.0.0.1] (localhost [127.0.0.1]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) by smtp.fripost.org (Postfix) with ESMTPSA id 13AAF12E7907 for ; Tue, 12 Apr 2016 00:42:04 +0200 (CEST) List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: guix-devel@gnu.org This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --dr3WjASoEJx8wE3KVgSB53NuKhp2gTQ0S Content-Type: multipart/mixed; boundary="nEbbBtFPlONf8j1BsiS77SNFLLEkwu2nU" From: Albin To: guix-devel@gnu.org Message-ID: <570C2836.7030100@fripost.org> Subject: [PATCH] gnu: Add openttd --nEbbBtFPlONf8j1BsiS77SNFLLEkwu2nU Content-Type: multipart/mixed; boundary="------------070608040603010800020105" This is a multi-part message in MIME format. --------------070608040603010800020105 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable Hi! This is my first package for the Guix project. I've done my best to follow all the guidelines. As you can see, I had to make use of quite few tricks to make it work. To the people in #guix: thanks a lot for your help! Albin --------------070608040603010800020105 Content-Type: text/x-patch; name="0001-gnu-Add-openttd.patch" Content-Transfer-Encoding: quoted-printable Content-Disposition: attachment; filename="0001-gnu-Add-openttd.patch" =46rom 061be49f0b39370541320984fc9eb53c2f2076c2 Mon Sep 17 00:00:00 2001 From: =3D?UTF-8?q?Albin=3D20S=3DC3=3DB6derqvist?=3D Date: Tue, 12 Apr 2016 00:13:08 +0200 Subject: [PATCH] gnu: Add openttd. --- gnu/packages/games.scm | 69 ++++++++++++++++++++++++++++++++++++++++++++= ++++++ 1 file changed, 69 insertions(+) diff --git a/gnu/packages/games.scm b/gnu/packages/games.scm index 653e0c7..8ae59c7 100644 --- a/gnu/packages/games.scm +++ b/gnu/packages/games.scm @@ -17,6 +17,7 @@ ;;; Copyright =C2=A9 2016 Rodger Fox ;;; Copyright =C2=A9 2016 Manolis Fragkiskos Ragkousis ;;; Copyright =C2=A9 2016 Nils Gillmann +;;; Copyright =C2=A9 2016 Albin S=C3=B6derqvist ;;; ;;; This file is part of GNU Guix. ;;; @@ -61,6 +62,7 @@ #:use-module (gnu packages libunwind) #:use-module (gnu packages haskell) #:use-module (gnu packages mp3) + #:use-module (gnu packages icu4c) #:use-module (gnu packages image) #:use-module (gnu packages ncurses) #:use-module (gnu packages python) @@ -1859,6 +1861,73 @@ and a game metadata scraper.") (home-page "http://www.emulationstation.org") (license license:expat))) =20 +(define-public openttd + (package + (name "openttd") + (version "1.6.0") + (source + (origin (method url-fetch) + ;; The official download URL is + ;; http://binaries.openttd.org/releases/1.6.0/openttd-1.6.0= -source.tar.xz + ;; but it doesn't work with `guix download`. However, it + ;; redirects to the one below (and the SHA sums match). + (uri (string-append "http://ftp.snt.utwente.nl/pub/games" + "/openttd/binaries/releases/" version + "/openttd-" version "-source.tar.xz")) + (sha256 + (base32 + "1cjf9gz7d0sn7893wv9d00q724sxv3d81bgb0c5f5ppz2ssyc4jc")) + (modules '((guix build utils))) + (snippet + '(begin + ;; The DOS port contains proprietary software, thus: + (delete-file-recursively "os/dos") + ;; GNU's not Unix so let's modify the exit dialog. + (substitute* (find-files "src/lang/" "\\.txt") + ((":Unix") ":GNU")))))) + (build-system gnu-build-system) + (arguments + `(#:tests? #f ;; no "check" target. + #:phases + (modify-phases %standard-phases + (replace 'configure + (lambda* (#:key outputs #:allow-other-keys) + ;; The build scripts don't understand the option + ;; `--enable-fast-install'. + (let ((out (assoc-ref outputs "out"))) + (zero? + (system* "./configure" + ;; At the moment, `lzo' must be disabled + ;; because the `config.lib' script cannot + ;; find it. It is only necessary for loading + ;; saved games generated by early versions of + ;; OpenTTD. + (string-append "--prefix=3D" out) + "--without-liblzo2" + ;; Put the binary in `bin' instead of `games' + "--binary-dir=3Dbin")))))))) + (native-inputs `(("pkg-config" ,pkg-config))) + (inputs + `(("allegro" ,allegro-4) + ("fontconfig" ,fontconfig) + ("freetype" ,freetype) + ("icu4c" ,icu4c) + ("libpng" ,libpng) + ;; ("lzo" ,lzo) disabled for the time being (see above). + ("sdl" ,sdl) + ("xz" ,xz) + ("zlib" ,zlib))) + (synopsis "Transportation economics simulator") + (description "OpenTTD is a game in which you transport goods and +passengers by land, water and air. It is a free implementation of +Transport Tycoon Deluxe but with many enhancements including +multiplayer mode, internationalization support, conditional orders and +the ability to clone, autoreplace and autoupdate vehicles.") + (home-page "http://openttd.org/") + ;; The software contains an in-game downloader from which the user + ;; may find non-functional data licensed under different terms. + (license license:gpl2))) + (define-public pinball (package (name "pinball") --=20 2.6.3 --------------070608040603010800020105-- --nEbbBtFPlONf8j1BsiS77SNFLLEkwu2nU-- --dr3WjASoEJx8wE3KVgSB53NuKhp2gTQ0S Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQEcBAEBCAAGBQJXDCg8AAoJEJ9oLhm3wRsiZG4IAJvKkAIBH+UCYShHLSEOl8BB pN6zotNuXG6kC1CfmDu7BacRYIekfs9XFHlEhrjP2Z8zuqVWmVRFtYP5u1Xfoibe jStdaDyd/CvdOYy2PZjuVhXfU6GmL29z7nhY1lKD6m5uJhUHaoMrL0fQUCY7Xiz0 ocQ2EWLH/rRJ452N2sIQiW69blWKZ2+c0etkW7P4/Esl/TRqLqBlw7NVq29eK6Xd dnnrdybh4bOY10ENJOGI5jqs8EKqiJU2zkB1fBsornn0CcOpLxxFOjVdV8ReBAom KjCTEkpgCUAS8IUxx6IqXV+EUiIf/tAy/ilYsf117cJn089keqUr+UFbyqfxACw= =oqFj -----END PGP SIGNATURE----- --dr3WjASoEJx8wE3KVgSB53NuKhp2gTQ0S--