Merge pull request #324187 from pbsds/bump-dolphin-emu-1719964685

dolphin-emu: 5.0-21460 -> 2407, adopt
This commit is contained in:
Weijia Wang 2024-07-05 21:53:43 +02:00 committed by GitHub
commit e8f66d0529
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 10 additions and 42 deletions

View File

@ -40,11 +40,7 @@
, xz , xz
# Used in passthru # Used in passthru
, common-updater-scripts
, dolphin-emu
, jq
, testers , testers
, writeShellScript
# Darwin-only dependencies # Darwin-only dependencies
, CoreBluetooth , CoreBluetooth
@ -56,23 +52,18 @@
, VideoToolbox , VideoToolbox
}: }:
stdenv.mkDerivation rec { stdenv.mkDerivation (finalAttrs: {
pname = "dolphin-emu"; pname = "dolphin-emu";
version = "5.0-21460"; version = "2407";
src = fetchFromGitHub { src = fetchFromGitHub {
owner = "dolphin-emu"; owner = "dolphin-emu";
repo = "dolphin"; repo = "dolphin";
rev = "a9544510468740b77cf06ef28daaa65fe247fd32"; rev = "refs/tags/${finalAttrs.version}";
hash = "sha256-mhD7Uaqi8GzHdR7Y81TspvCnrZH2evWuWFgXMQ2c8g0="; hash = "sha256-8W4KyIj+rhDkWnQogjpzlEJVo3HJenfpWKimSyMGN7c=";
fetchSubmodules = true; fetchSubmodules = true;
}; };
patches = [
# TODO: Remove when merged https://github.com/dolphin-emu/dolphin/pull/12736
./find-minizip-ng.patch
];
strictDeps = true; strictDeps = true;
nativeBuildInputs = [ nativeBuildInputs = [
@ -133,8 +124,8 @@ stdenv.mkDerivation rec {
cmakeFlags = [ cmakeFlags = [
"-DDISTRIBUTOR=NixOS" "-DDISTRIBUTOR=NixOS"
"-DDOLPHIN_WC_REVISION=${src.rev}" "-DDOLPHIN_WC_REVISION=${finalAttrs.src.rev}"
"-DDOLPHIN_WC_DESCRIBE=${version}" "-DDOLPHIN_WC_DESCRIBE=${finalAttrs.version}"
"-DDOLPHIN_WC_BRANCH=master" "-DDOLPHIN_WC_BRANCH=master"
] ++ lib.optionals stdenv.isDarwin [ ] ++ lib.optionals stdenv.isDarwin [
"-DOSX_USE_DEFAULT_SEARCH_PATH=True" "-DOSX_USE_DEFAULT_SEARCH_PATH=True"
@ -165,20 +156,10 @@ stdenv.mkDerivation rec {
passthru = { passthru = {
tests.version = testers.testVersion { tests.version = testers.testVersion {
package = dolphin-emu; package = finalAttrs.finalPackage;
command = "dolphin-emu-nogui --version"; command = "dolphin-emu-nogui --version";
version = if stdenv.hostPlatform.isDarwin then "Dolphin 5.0" else version; inherit (finalAttrs) version;
}; };
updateScript = writeShellScript "dolphin-update-script" ''
set -eou pipefail
export PATH=${lib.makeBinPath [ curl jq common-updater-scripts ]}
json="$(curl -s https://dolphin-emu.org/update/latest/beta)"
version="$(jq -r '.shortrev' <<< "$json")"
rev="$(jq -r '.hash' <<< "$json")"
update-source-version dolphin-emu "$version" --rev="$rev"
'';
}; };
meta = with lib; { meta = with lib; {
@ -188,6 +169,6 @@ stdenv.mkDerivation rec {
branch = "master"; branch = "master";
license = licenses.gpl2Plus; license = licenses.gpl2Plus;
platforms = platforms.unix; platforms = platforms.unix;
maintainers = with maintainers; [ ]; maintainers = with maintainers; [ pbsds ];
}; };
} })

View File

@ -1,13 +0,0 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index fb37788513..289a25fa57 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -676,7 +676,7 @@ dolphin_find_optional_system_library_pkgconfig(ZLIB zlib-ng ZLIB::ZLIB Externals
# https://github.com/zlib-ng/minizip-ng/commit/6c5f265a55f1a12a7a016cd2962feff91cff5d2e
add_definitions(-DMZ_COMPAT_VERSION=110) # This macro is for forwards compatibility with 4.0.4+
-dolphin_find_optional_system_library_pkgconfig(MINIZIP minizip>=3.0.0 minizip::minizip Externals/minizip)
+dolphin_find_optional_system_library_pkgconfig(MINIZIP minizip-ng>=3.0.0 minizip::minizip Externals/minizip)
dolphin_find_optional_system_library(LZO Externals/LZO)