diff options
Diffstat (limited to 'pkgs/misc/emulators/retroarch')
-rw-r--r-- | pkgs/misc/emulators/retroarch/cores.nix | 28 | ||||
-rw-r--r-- | pkgs/misc/emulators/retroarch/hashes.json | 7 | ||||
-rwxr-xr-x | pkgs/misc/emulators/retroarch/update.py | 1 |
3 files changed, 32 insertions, 4 deletions
diff --git a/pkgs/misc/emulators/retroarch/cores.nix b/pkgs/misc/emulators/retroarch/cores.nix index 84a24e543e683..916ca1687075c 100644 --- a/pkgs/misc/emulators/retroarch/cores.nix +++ b/pkgs/misc/emulators/retroarch/cores.nix @@ -83,13 +83,18 @@ let }.${stdenv.hostPlatform.parsed.cpu.name} or stdenv.hostPlatform.parsed.cpu.name}" ] ++ (args.makeFlags or [ ]); + coreDir = "${placeholder "out"}/lib/retroarch/cores"; + installPhase = '' - COREDIR="$out/lib/retroarch/cores" + runHook preInstall + mkdir -p $out/bin - mkdir -p $COREDIR - mv ${d2u args.core}_libretro${stdenv.hostPlatform.extensions.sharedLibrary} $COREDIR + mkdir -p $coreDir + mv ${d2u args.core}_libretro${stdenv.hostPlatform.extensions.sharedLibrary} $coreDir makeWrapper ${retroarch}/bin/retroarch $out/bin/retroarch-${core} \ - --add-flags "-L $COREDIR/${d2u core}_libretro${stdenv.hostPlatform.extensions.sharedLibrary} $@" + --add-flags "-L $coreDir/${d2u core}_libretro${stdenv.hostPlatform.extensions.sharedLibrary} $@" + + runHook postInstall ''; enableParallelBuilding = true; @@ -530,6 +535,21 @@ in preBuild = "cd Libretro"; }; + mesen-s = mkLibRetroCore { + core = "mesens"; + src = getCoreSrc "mesen-s"; + version = "unstable-2021-11-22"; + description = "Port of Mesen-S to libretro"; + license = lib.licenses.gpl3Only; + makefile = "Makefile"; + preBuild = "cd Libretro"; + postInstall = '' + # fix library name to match libretro-core-info + mv $coreDir/mesens_libretro${stdenv.hostPlatform.extensions.sharedLibrary} \ + $coreDir/mesen-s_libretro${stdenv.hostPlatform.extensions.sharedLibrary} + ''; + }; + meteor = mkLibRetroCore { core = "meteor"; description = "Port of Meteor to libretro"; diff --git a/pkgs/misc/emulators/retroarch/hashes.json b/pkgs/misc/emulators/retroarch/hashes.json index 6269cbd01aa37..57e97c394142e 100644 --- a/pkgs/misc/emulators/retroarch/hashes.json +++ b/pkgs/misc/emulators/retroarch/hashes.json @@ -286,6 +286,13 @@ "sha256": "9+AqZRv8lugNNa+ZZzIPJNO87J1aBUEiOggL8aYno1M=", "fetchSubmodules": false }, + "mesen-s": { + "owner": "libretro", + "repo": "mesen-s", + "rev": "42eb0e8ad346608dae86feb8a04833d16ad21541", + "sha256": "q6zeoNiZtFy8ZYls9/E+O7o9BYTcVcmYjbJA48qiraU=", + "fetchSubmodules": false + }, "meteor": { "owner": "libretro", "repo": "meteor-libretro", diff --git a/pkgs/misc/emulators/retroarch/update.py b/pkgs/misc/emulators/retroarch/update.py index 844a8e545955a..96f6d9f1f615e 100755 --- a/pkgs/misc/emulators/retroarch/update.py +++ b/pkgs/misc/emulators/retroarch/update.py @@ -51,6 +51,7 @@ CORES = { "mame2016": {"repo": "mame2016-libretro"}, "melonds": {"repo": "melonds"}, "mesen": {"repo": "mesen"}, + "mesen-s": {"repo": "mesen-s"}, "meteor": {"repo": "meteor-libretro"}, "mgba": {"repo": "mgba"}, "mupen64plus": {"repo": "mupen64plus-libretro-nx"}, |