GNU bug report logs -
#75694
[PATCH v3 03/11] gnu: dolphin-emu: Build .bin binary files and preserve data ones.
Previous Next
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 75694 in the body.
You can then email your comments to 75694 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
adam.faiz <at> disroot.org, liliana.prikler <at> gmail.com, iyzsong <at> envs.net, guix-patches <at> gnu.org
:
bug#75694
; Package
guix-patches
.
(Mon, 20 Jan 2025 14:31:05 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
:
New bug report received and forwarded. Copy sent to
adam.faiz <at> disroot.org, liliana.prikler <at> gmail.com, iyzsong <at> envs.net, guix-patches <at> gnu.org
.
(Mon, 20 Jan 2025 14:31:05 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
These files are necessary to save games, enable cheat codes, etc.
* gnu/packages/emulators.scm (dolphin-emu) [source] <snippet>: Refine to avoid
deleting a few .bin which are not executable objects but rather configuration
files samples.
[phases]: Add build-codeloader.bin, build-dsp_rom.bin and build-dsp_coefs.bin
phases.
[arguments] <configure-flags>: Add -DDSPTOOL=ON.
[native-inputs]: Add a cross-compiler for powerpc. Add python-minimal and
python-numpy.
Change-Id: Ida8df1add940e1708c557223409d854aa995e8a5
---
gnu/packages/emulators.scm | 50 ++++++++++++++++++++++++++++++++++----
1 file changed, 45 insertions(+), 5 deletions(-)
diff --git a/gnu/packages/emulators.scm b/gnu/packages/emulators.scm
index ebe4601304..52c59b3965 100644
--- a/gnu/packages/emulators.scm
+++ b/gnu/packages/emulators.scm
@@ -98,6 +98,7 @@ (define-module (gnu packages emulators)
#:use-module (gnu packages pulseaudio)
#:use-module (gnu packages python)
#:use-module (gnu packages python-build)
+ #:use-module (gnu packages python-xyz)
#:use-module (gnu packages qt)
#:use-module (gnu packages sdl)
#:use-module (gnu packages sphinx)
@@ -289,7 +290,8 @@ (define-public dolphin-emu
(file-name (git-file-name name version))
(sha256
(base32 "1p8qsxlabgmz3nic0a9ghh9d3lzl5f8i3kmdrrvx6w8kdlp33018"))
- (modules '((guix build utils)))
+ (modules '((guix build utils)
+ (ice-9 regex)))
(snippet
'(begin
;; Remove external stuff we don't need.
@@ -317,9 +319,19 @@ (define-public dolphin-emu
"miniupnpc" "minizip" "MoltenVK" "pugixml"
"soundtouch"
"xxhash" "zlib" "zstd"))
- ;; Clean up source.
+ ;; Clean up the source.
(for-each delete-file
- (find-files "." ".*\\.(bin|dsy|exe|jar|rar)$"))
+ (find-files
+ "."
+ (lambda (file _)
+ (and (string-match "\\.(bin|dsy|exe|jar|rar)$" file)
+ ;; Preserve the important wc24 .bin
+ ;; configuration *data* files.
+ (not (member (basename file)
+ '("misc.bin"
+ "nwc24dl.bin"
+ "nwc24fl.bin"
+ "nwc24fls.bin")))))))
;; Do not attempt to include now-missing directories.
(substitute* "CMakeLists.txt"
((".*add_subdirectory.*Externals/enet.*") "")
@@ -371,7 +383,30 @@ (define-public dolphin-emu
"FileSystemTest"
"PowerPCTest"
"VertexLoaderTest")
- "|")))))))
+ "|"))))))
+ (add-before 'install 'build-codeloader.bin
+ (lambda _
+ (with-directory-excursion "../source/docs"
+ ;; The following command-line is adapted from the example in
+ ;; codehandler.s.
+ (invoke "powerpc-linux-gnu-gcc" "-mpowerpc" "-mbig"
+ "codehandler.s" "-nostartfiles" "-nodefaultlibs"
+ "-nostdlib" "-T" "codehandler.ld"
+ "-o" "codehandler.bin")
+ (copy-file "codehandler.bin" "../Data/Sys/codehandler.bin"))))
+ (add-before 'install 'build-dsp_rom.bin
+ (lambda _
+ ;; Ensure dsptool is on PATH.
+ (setenv "PATH" (string-append (getenv "PATH") ":"
+ (getcwd) "/Binaries"))
+ (with-directory-excursion "../source"
+ (invoke "dsptool" "-o" "Data/Sys/GC/dsp_rom.bin"
+ "docs/DSP/free_dsp_rom/dsp_rom.ds"))))
+ (add-before 'install 'build-dsp_coefs.bin
+ (lambda _
+ (with-directory-excursion "../source"
+ (invoke "python3" "docs/DSP/free_dsp_rom/generate_coefs.py")
+ (rename-file "dsp_coef.bin" "Data/Sys/GC/dsp_coef.bin")))))
;; The FindGTK2 cmake script only checks hardcoded directories for
;; glib/gtk headers. Also add some include directories via the CXX
;; flags to let GCC find some headers not actively searched by the
@@ -380,6 +415,7 @@ (define-public dolphin-emu
#~(list (string-append "-DCMAKE_CXX_FLAGS="
"-I" (search-input-directory
%build-inputs "include/soundtouch"))
+ "-DDSPTOOL=ON"
(string-append "-DX11_INCLUDE_DIR="
#$(this-package-input "libx11")
"/include")
@@ -389,7 +425,11 @@ (define-public dolphin-emu
"-DX11_FOUND=1")
#:test-target "unittests"))
(native-inputs
- (list gettext-minimal pkg-config))
+ (list (cross-gcc "powerpc-linux-gnu")
+ gettext-minimal
+ pkg-config
+ python-minimal
+ python-numpy))
(inputs
(list alsa-lib
ao
--
2.47.1
Added tag(s) notabug.
Request was from
Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
to
control <at> debbugs.gnu.org
.
(Thu, 23 Jan 2025 12:13:04 GMT)
Full text and
rfc822 format available.
bug closed, send any further explanations to
75694 <at> debbugs.gnu.org and Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
Request was from
Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
to
control <at> debbugs.gnu.org
.
(Thu, 23 Jan 2025 12:13:04 GMT)
Full text and
rfc822 format available.
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Thu, 20 Feb 2025 12:24:22 GMT)
Full text and
rfc822 format available.
This bug report was last modified 121 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.