From patchwork Tue Apr 11 12:53:55 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nicolas Goaziou X-Patchwork-Id: 49098 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 4668417494; Tue, 11 Apr 2023 14:33:22 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-3.9 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_MSPIKE_H2,SPF_HELO_PASS autolearn=ham autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 7AC421747C for ; Tue, 11 Apr 2023 14:33:21 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pmDWc-0006rN-Ee; Tue, 11 Apr 2023 08:55:06 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pmDWa-0006qD-5b for guix-patches@gnu.org; Tue, 11 Apr 2023 08:55:04 -0400 Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pmDWZ-0005i7-Kp for guix-patches@gnu.org; Tue, 11 Apr 2023 08:55:03 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1pmDWZ-0004N8-AA for guix-patches@gnu.org; Tue, 11 Apr 2023 08:55:03 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#62724] [PATCH v2] gnu: mame: Update to 0.253. References: <20230408101422.781587-1-mail@nicolasgoaziou.fr> In-Reply-To: <20230408101422.781587-1-mail@nicolasgoaziou.fr> Resent-From: Nicolas Goaziou Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 11 Apr 2023 12:55:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 62724 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 62724@debbugs.gnu.org Received: via spool by 62724-submit@debbugs.gnu.org id=B62724.168121765016503 (code B ref 62724); Tue, 11 Apr 2023 12:55:03 +0000 Received: (at 62724) by debbugs.gnu.org; 11 Apr 2023 12:54:10 +0000 Received: from localhost ([127.0.0.1]:36876 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pmDVh-0004I6-T8 for submit@debbugs.gnu.org; Tue, 11 Apr 2023 08:54:10 -0400 Received: from relay6-d.mail.gandi.net ([217.70.183.198]:48999) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pmDVf-0004Hq-Pp for 62724@debbugs.gnu.org; Tue, 11 Apr 2023 08:54:08 -0400 Received: (Authenticated sender: admin@nicolasgoaziou.fr) by mail.gandi.net (Postfix) with ESMTPSA id 47F62C0002 for <62724@debbugs.gnu.org>; Tue, 11 Apr 2023 12:54:01 +0000 (UTC) From: Nicolas Goaziou Date: Tue, 11 Apr 2023 14:53:55 +0200 Message-Id: <20230411125355.919934-1-mail@nicolasgoaziou.fr> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches * gnu/packages/emulators.scm (mame): Update to 0.253. [source]: Add modules for CUT and SCANDIR. Preserve the minimum set of third-party libraries. [arguments]<#:make-flags>: Remove unnecessary flags. <#:phases>: Add a phase to use all possible system libraries instead of listing them piece wise. [native-inputs]: Add NASM. --- v2: Do not list every third-party to remove. Try to find a minimal set instead. gnu/packages/emulators.scm | 46 ++++++++++++++++++++++++-------------- 1 file changed, 29 insertions(+), 17 deletions(-) base-commit: a4e9842a70775a54bbe1369881b739e7ea9a6432 diff --git a/gnu/packages/emulators.scm b/gnu/packages/emulators.scm index 7e73b217ea..882778bd21 100644 --- a/gnu/packages/emulators.scm +++ b/gnu/packages/emulators.scm @@ -1759,7 +1759,7 @@ (define-public libticalcs2 (define-public mame (package (name "mame") - (version "0.252") + (version "0.253") (source (origin (method git-fetch) @@ -1768,33 +1768,44 @@ (define-public mame (commit (apply string-append "mame" (string-split version #\.))))) (file-name (git-file-name name version)) (sha256 - (base32 "07qhcm1v47sy2wj30nx3cbhvcbgki0cl83gabr0miiw60fhgyn6j")) - (modules '((guix build utils))) + (base32 "0mk6clpvw7y567qis1g1rxabwz7qxik6c1ywjdqr5075a2kw44jm")) + (modules '((ice-9 ftw) + (srfi srfi-26) + (guix build utils))) (snippet - ;; Remove bundled libraries. - '(begin - (with-directory-excursion "3rdparty" - (for-each delete-file-recursively - '("asio" "expat" "glm" "libflac" "libjpeg" "lua" - "portaudio" "portmidi" "pugixml" "rapidjson" "SDL2" - "SDL2-override" "sqlite3" "utf8proc" "zlib"))))))) + ;; Remove most bundled libraries. Some of the kept libraries below + ;; are provided by Guix, but difficult to un-bundle. + #~(with-directory-excursion "3rdparty" + (let ((keep (list "." ".." + "asmjit" + "bgfx" + "bimg" + "bx" + "genie" + "lzma" + "softfloat" + "softfloat3" + "sol2" + "ymfm"))) + (for-each delete-file-recursively + (scandir "." (negate (cut member <> keep))))))))) (build-system gnu-build-system) (arguments (list #:make-flags - #~(cons* + #~(list ;; A 'strict-overflow' error pops up on i686 so disable '-Werror'. "NOWERROR=1" (string-append "QT_HOME=" #$(this-package-input "qtbase")) - (string-append "SDL_INI_PATH=" #$output "/share/mame/ini") - (map (lambda (lib) - (string-append "USE_SYSTEM_LIB_" (string-upcase lib) "=1")) - '("asio" "expat" "flac" "glm" "jpeg" "lua" "portaudio" "portmidi" - "pugixml" "rapidjson" "sqlite3" "utf8proc" "zlib"))) + (string-append "SDL_INI_PATH=" #$output "/share/mame/ini")) #:tests? #f ;no test in regular release #:phases #~(modify-phases %standard-phases (delete 'configure) + (add-before 'build 'use-system-libraries + (lambda _ + (substitute* "makefile" + (("# +(USE_SYSTEM_LIB)" _ option) option)))) (add-after 'build 'build-documentation (lambda _ (invoke "make" "-C" "docs" "man" "info"))) (replace 'install @@ -1897,7 +1908,8 @@ (define-public mame Keywords=Game;Emulator;Arcade;~%" executable))))))))) (native-inputs - (list pkg-config + (list nasm + pkg-config python-sphinx python-sphinxcontrib-svg2pdfconverter texinfo))