From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:41134) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1esHKr-0000Yl-TX for guix-patches@gnu.org; Sat, 03 Mar 2018 19:17:07 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1esHKo-0001PE-LT for guix-patches@gnu.org; Sat, 03 Mar 2018 19:17:05 -0500 Received: from debbugs.gnu.org ([208.118.235.43]:35437) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1esHKo-0001PA-GI for guix-patches@gnu.org; Sat, 03 Mar 2018 19:17:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1esHKo-0001Qj-BR for guix-patches@gnu.org; Sat, 03 Mar 2018 19:17:02 -0500 Subject: [bug#30693] Xonotic Resent-Message-ID: Received: from eggs.gnu.org ([2001:4830:134:3::10]:40821) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1esHJh-0008By-4G for guix-patches@gnu.org; Sat, 03 Mar 2018 19:15:54 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1esHJd-00018B-Rt for guix-patches@gnu.org; Sat, 03 Mar 2018 19:15:53 -0500 Received: from aibo.runbox.com ([91.220.196.211]:46086) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1esHJd-00017A-5t for guix-patches@gnu.org; Sat, 03 Mar 2018 19:15:49 -0500 Received: from [10.9.9.211] (helo=mailfront11.runbox.com) by mailtransmit02.runbox with esmtp (Exim 4.86_2) (envelope-from ) id 1esGfV-0004TE-7U for guix-patches@gnu.org; Sun, 04 Mar 2018 00:34:21 +0100 Received: from dslb-092-073-177-252.092.073.pools.vodafone-ip.de ([92.73.177.252] helo=localhost) by mailfront11.runbox.com with esmtpsa (uid:892961 ) (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) id 1esGfP-0006dk-Ts for guix-patches@gnu.org; Sun, 04 Mar 2018 00:34:16 +0100 Date: Sat, 3 Mar 2018 23:34:27 +0000 From: ng0 Message-ID: <20180303233427.olbz5visu3c5urms@abyayala> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="6hc5c2vi2qqtkvjj" Content-Disposition: inline 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: 30693@debbugs.gnu.org --6hc5c2vi2qqtkvjj Content-Type: multipart/mixed; boundary="uvcrhebaczablzp5" Content-Disposition: inline --uvcrhebaczablzp5 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable This adds xonotic. I'm not sure about the "x11" license part. In general it works. --=20 A88C8ADD129828D7EAC02E52E22F9BBFEE348588 https://n0.is/~ng0 --uvcrhebaczablzp5 Content-Type: text/plain; charset=utf-8 Content-Disposition: attachment; filename="0001-gnu-Add-xonotic.patch" Content-Transfer-Encoding: quoted-printable =46rom 8b3cbb663b9c59ceec99cdef9c16e13edeae86aa Mon Sep 17 00:00:00 2001 =46rom: ng0 Date: Sat, 3 Mar 2018 23:27:13 +0000 Subject: [PATCH] gnu: Add xonotic. * gnu/packages/games.scm (xonotic, xonotic-data): New variables. --- gnu/packages/games.scm | 242 +++++++++++++++++++++++++++++++++++++++++++++= ++++ 1 file changed, 242 insertions(+) diff --git a/gnu/packages/games.scm b/gnu/packages/games.scm index 5917bbd69..992bae83a 100644 --- a/gnu/packages/games.scm +++ b/gnu/packages/games.scm @@ -90,6 +90,7 @@ #:use-module (gnu packages haskell) #:use-module (gnu packages mp3) #:use-module (gnu packages music) + #:use-module (gnu packages multiprecision) #:use-module (gnu packages icu4c) #:use-module (gnu packages image) #:use-module (gnu packages ncurses) @@ -4846,3 +4847,244 @@ Strife, Chex Quest, and fan-created games like Harm= ony, Hacx and Freedoom.") (license:non-copyleft ; modified dumb "file://dumb/licence.txt" "Dumb license, explicitly GPL compatible."))))) + +(define xonotic-data + (package + (name "xonotic-data") + (version "0.8.2") + (source + (origin + (method url-fetch) + (uri (string-append "http://dl.xonotic.org/xonotic-" + version ".zip")) + (file-name (string-append name "-" version ".zip")) + (sha256 + (base32 + "1mcs6l4clvn7ibfq3q69k2p0z6ww75rxvnngamdq5ic6yhq74bx2")))) + (build-system trivial-build-system) + (native-inputs + `(("unzip" ,unzip))) + (arguments + `(#:modules ((guix build utils)) + #:builder + (begin + (use-modules (guix build utils)) + (let* ((out (assoc-ref %outputs "out")) + (xonotic (string-append out "/share/xonotic")) + (source (assoc-ref %build-inputs "source")) + (unzip (string-append (assoc-ref %build-inputs "unzip") "/= bin/unzip"))) + (copy-file source (string-append ,name "-" ,version ".zip")) + (zero? (system* unzip (string-append ,name "-" ,version ".zip")= )) + (mkdir-p out) + (mkdir-p xonotic) + (chdir "Xonotic") + (copy-recursively "data" + (string-append xonotic "/data")) + (copy-recursively "server" + (string-append xonotic "/server")) + (install-file "key_0.d0pk" xonotic))))) + (home-page "http://xonotic.org") + (synopsis "Data files for Xonotic") + (description + "Xonotic-data provides the data files required by the game Xonotic.") + (license (list license:gpl2+ + license:x11)))) ; server/rcon.pl + +(define-public xonotic + (package + (name "xonotic") + (version "0.8.2") + (source + (origin + (method url-fetch) + (uri (string-append "http://dl.xonotic.org/xonotic-" + version "-source.zip")) + (file-name (string-append name "-" version ".zip")) + (sha256 + (base32 + "0axxw04fyz6jlfqd0kp7hdrqa0li31sx1pbipf2j5qp9wvqicsay")))) + (build-system gnu-build-system) + (arguments + `(#:configure-flags (list (string-append "--prefix=3D" + (assoc-ref %outputs "out")) + "--disable-rijndael") + #:phases + (modify-phases %standard-phases + (add-before 'configure 'make-darkplaces + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (sharedir (string-append out "/share/xonotic/"))) + (invoke "make" "-C" "source/darkplaces" + (string-append "DP_FS_BASEDIR=3D" + sharedir) + "DP_LINK_TO_LIBJPEG=3D1" + "DP_SOUND_API=3DALSA" + "CC=3Dgcc" + "-f" "makefile" + "cl-release") + (invoke "make" "-C" "source/darkplaces" + (string-append "DP_FS_BASEDIR=3D" + sharedir) + "DP_LINK_TO_LIBJPEG=3D1" + "DP_SOUND_API=3DALSA" + "CC=3Dgcc" + "-f" "makefile" + "sdl-release") + (invoke "make" "-C" "source/darkplaces" + (string-append "DP_FS_BASEDIR=3D" + sharedir) + "DP_LINK_TO_LIBJPEG=3D1" + "DP_SOUND_API=3DALSA" + "CC=3Dgcc" + "-f" "makefile" + "sv-release")))) + (add-before 'configure 'bootstrap + (lambda _ + (chdir "source/d0_blind_id") + (invoke "sh" "autogen.sh"))) + (add-after 'build 'install-desktop-entry + (lambda* (#:key outputs #:allow-other-keys) + ;; Add .desktop files for the 2 variants and the symlink + (let* ((output (assoc-ref outputs "out")) + (apps (string-append output "/share/applications"))) + (mkdir-p apps) + (with-output-to-file + (string-append apps "/xonotic-glx.desktop") + (lambda _ + (format #t + "[Desktop Entry]~@ + Name=3Dxonotic-glx~@ + Comment=3DXonotic glx~@ + Exec=3D~a/bin/xonotic-glx~@ + TryExec=3D~@*~a/bin/xonotic-glx~@ + Icon=3D~@ + Type=3DApplication~%" + output))) + (with-output-to-file + (string-append apps "/xonotic-sdl.desktop") + (lambda _ + (format #t + "[Desktop Entry]~@ + Name=3Dxonotic-sdl~@ + Comment=3DXonotic sdl~@ + Exec=3D~a/bin/xonotic-sdl~@ + TryExec=3D~@*~a/bin/xonotic-sdl~@ + Icon=3D~@ + Type=3DApplication~%" + output))) + (with-output-to-file + (string-append apps "/xonotic.desktop") + (lambda _ + (format #t + "[Desktop Entry]~@ + Name=3Dxonotic~@ + Comment=3DXonotic~@ + Exec=3D~a/bin/xonotic-glx~@ + TryExec=3D~@*~a/bin/xonotic~@ + Icon=3D~@ + Type=3DApplication~%" + output))) + #t))) + (add-after 'install-desktop-entry 'install-icons + (lambda* (#:key outputs #:allow-other-keys) + (let ((out (assoc-ref outputs "out"))) + (with-directory-excursion "../../misc/logos/icons_png/" + (for-each + (lambda (file) + (let* ((size (string-filter char-numeric? file)) + (icons (string-append out "/share/icons/hicolor= /" + size "x" size "/apps"))) + (mkdir-p icons) + (copy-file file (string-append icons "/xonotic.png")= ))) + '("xonotic_16.png" "xonotic_22.png" "xonotic_24.png" + "xonotic_32.png" "xonotic_48.png" "xonotic_64.png" + "xonotic_128.png" "xonotic_256.png" "xonotic_512.png")= ))))) + (add-after 'install-icons 'install-binaries + (lambda* (#:key outputs #:allow-other-keys) + (let ((out (assoc-ref outputs "out"))) + (define (install src dst) + (let ((dst (string-append out dst))) + (mkdir-p (dirname dst)) + (copy-file src dst))) + (mkdir-p (string-append out "/bin")) + (install "../darkplaces/darkplaces-dedicated" + "/bin/xonotic-dedicated") + (install "../darkplaces/darkplaces-glx" + "/bin/xonotic-glx") + (install "../darkplaces/darkplaces-sdl" + "/bin/xonotic-sdl") + ;; Provide a default xonotic executable, defaulting to SDL. + (symlink (string-append out "/bin/xonotic-sdl") + (string-append out "/bin/xonotic")) + #t))) + (add-after 'install-binaries 'install-data + (lambda* (#:key outputs inputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (data (assoc-ref inputs "xonotic-data"))) + (copy-recursively (string-append data "/share/xonotic") + (string-append out "/share/xonotic")) + #t))) + (add-after 'install-binaries 'wrap-binaries + (lambda* (#:key outputs inputs #:allow-other-keys) + ;; Curl and libvorbis need to be wrapped so that we get + ;; sound and networking. + (let* ((out (assoc-ref outputs "out")) + (bin (string-append out "/bin/xonotic")) + (bin-sdl (string-append out "/bin/xonotic-sdl")) + (bin-glx (string-append out "/bin/xonotic-glx")) + (bin-dedicated (string-append out "/bin/xonotic-dedica= ted")) + (curl (assoc-ref inputs "curl")) + (vorbis (assoc-ref inputs "libvorbis"))) + (wrap-program bin + `("LD_LIBRARY_PATH" ":" prefix + (,(string-append curl "/lib:" vorbis "/lib")))) + (wrap-program bin-sdl + `("LD_LIBRARY_PATH" ":" prefix + (,(string-append curl "/lib:" vorbis "/lib")))) + (wrap-program bin-glx + `("LD_LIBRARY_PATH" ":" prefix + (,(string-append curl "/lib:" vorbis "/lib")))) + (wrap-program bin-dedicated + `("LD_LIBRARY_PATH" ":" prefix + (,(string-append curl "/lib:" vorbis "/lib")))) + #t)))))) + (inputs + `(("xonotic-data" ,xonotic-data) + ("alsa-lib" ,alsa-lib) + ("curl" ,curl) + ("libjpeg" ,libjpeg) + ("libmodplug" ,libmodplug) + ("libvorbis" ,libvorbis) + ("libogg" ,libogg) + ("libxpm" ,libxpm) + ("libxxf86dga" ,libxxf86dga) + ("libxxf86vm" ,libxxf86vm) + ("libx11" ,libx11) + ("libxext" ,libxext) + ("libxau" ,libxau) + ("libxdmcp" ,libxdmcp) + ("mesa" ,mesa) + ("glu" ,glu) + ("freetype" ,freetype) + ("sdl2" ,sdl2) + ("libpng" ,libpng) + ("hicolor-icon-theme" ,hicolor-icon-theme))) + (native-inputs + `(("unzip" ,unzip) + ("autoconf" ,autoconf) + ("automake" ,automake) + ("pkg-config" ,pkg-config) + ("libtool" ,libtool) + ("gmp" ,gmp))) + (home-page "http://xonotic.org") + (synopsis "Fast-paced first-person shooter game") + (description + "Xonotic is a free, fast-paced first-person shooter. +The project is geared towards providing addictive arena shooter +gameplay which is all spawned and driven by the community itself. +Xonotic is a direct successor of the Nexuiz project with years of +development between them, and it aims to become the best possible +open-source FPS of its kind.") + (license (list license:gpl2+ + license:bsd-3 ; /source/d0_blind_id folder and others + license:x11)))) --=20 2.16.2 --uvcrhebaczablzp5-- --6hc5c2vi2qqtkvjj Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEqIyK3RKYKNfqwC5S4i+bv+40hYgFAlqbMQIACgkQ4i+bv+40 hYjypRAAi986l+hGWC5qY1RitNwbmyL4dRyi4ofoUTMJrBkbndZWd6Xp/mtG8Bt3 AB/lOg3GbwOWf8f7ziXzjErUVkxnuuRYzFYxpVV0vb+u6r8QK9iW6AsIGzVW7E8Z wkZzz88bfEW+UT5rQkRm+PGsaBp1X3wstbhBd/W7xoBNUdt05VJj8ZZOVidC600c qRGWab4e0HXwKKYa+4Koe8ovDnnhEsnFa7c4irM+wBDQhJpUafJuceUOB+0a16jo /4Y/0im7ErrWh16n0Kk5Aru8eBnUKYxSOVLllLWJtVRVPdjLxK66GbX0gHviI8Wq BkQXocTYZWfJUBKz+33tNDfJlJB0JLMTdFm2ulaseNrW3xWbGy/n7AcS2yCGWSvM kLfRH7i9Fj71Zy/+pgZzVsubgVXyetM2plz5yryLswl0hPtVqK0vKOZAIyXnqf9O s1KcGGPw5Mr72ZOLi8uaMY+YuxrjOx4eDeXsVaqCoVjPnwc0s7Skk+jbc+trtaw0 WuqC5WL1JpkhCInmlMlh2lwVg76UULvyVTBiOENP2JII46Z0uTYad50wfP4JePJC Pqsiswm3W19n5Rtaakpu9dOb9s9FVwBaBDFFzFgQZzWkplp8C1YuKoDdX+tS0Wla W2+VgK3iNa00rd6h7yUIDLeH6jHUbUP7pd7tQKdDgImKrQR/Q1U= =vWGm -----END PGP SIGNATURE----- --6hc5c2vi2qqtkvjj--