From 08d341003e6903a2869754586bf33da196f668b2 Mon Sep 17 00:00:00 2001 From: Pierre Neidhardt Date: Tue, 18 Feb 2020 15:26:49 +0100 Subject: gnu: Add gnome-arcade. * gnu/packages/emulators.scm (gnome-arcade): New variable. --- gnu/packages/emulators.scm | 63 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 63 insertions(+) diff --git a/gnu/packages/emulators.scm b/gnu/packages/emulators.scm index b9c854ca25..b7f29a6f5b 100644 --- a/gnu/packages/emulators.scm +++ b/gnu/packages/emulators.scm @@ -1463,6 +1463,69 @@ functions. The source code to MAME serves as this documentation.") ;; keymaps, languages and samples are under CC0. (license (list license:gpl2+ license:expat license:cc0)))) +(define-public gnome-arcade + (package + (name "gnome-arcade") + (version "0.218.2") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/strippato/gnome-arcade") + (commit (string-append "v." version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1qc01a62p65qb6mwjfmxqsd6n3rglsfwrjhsp25nr7q54107n55l")))) + (build-system cmake-build-system) + (arguments + `(#:tests? #f ; No tests. + #:configure-flags (list + (string-append "-DMAME_BIN=\"" + (assoc-ref %build-inputs "mame") + "/bin/mame\"") + (string-append "-DAPP_RES=\"" + (assoc-ref %outputs "out") + "/share/gnome-arcade/\"")) + #:phases + (modify-phases %standard-phases + (add-before 'build 'fix-paths + (lambda* (#:key outputs #:allow-other-keys) + (let ((out (assoc-ref outputs "out"))) + (pk 'cwd (getcwd)) + (substitute* "../source/src/config.c" + (("/usr/share") (string-append out "/share")))) + #t)) + (replace 'install + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (bin (string-append out "/bin")) + (rom (string-append out "/share/gnome-arcade/data/rom")) + (tile (string-append out "/share/gnome-arcade/data/tile"))) + (mkdir-p bin) + (install-file "../gnome-arcade" bin) + (copy-recursively "../source/res" + (string-append out "/share/gnome-arcade/res")) + (mkdir-p rom) + (install-file "../source/data/rom/ROM.TXT" rom) + (mkdir-p tile) + (install-file "../source/data/tile/TILE.TXT" tile)) + #t))))) + (native-inputs + `(("pkg-config" ,pkg-config))) + (inputs + `(("mame" ,mame) + ("gtk" ,gtk+) + ("libevdev" ,libevdev) + ("libvlc" ,vlc) + ("libarchive" ,libarchive))) + (home-page "https://github.com/strippato/gnome-arcade") + (synopsis "Minimal MAME frontend") + (description + "A minimal GTK+ frontend for MAME, the multi-purpose arcade and console +emulator.") + (license license:gpl3+))) + (define-public pcsxr ;; No release since 2017. (let ((commit "6484236cb0281e8040ff6c8078c87899a3407534")) -- cgit v1.2.3