23 lines
573 B
Nix
23 lines
573 B
Nix
{ mkRom , lib, symlinkJoin, libretro, stdenv, retroarchBare, retroarchFull, wrapRetroarch' }:
|
|
{ name
|
|
, src
|
|
, emulator
|
|
, filename
|
|
, settings
|
|
, meta
|
|
}:
|
|
let
|
|
retroarch = wrapRetroarch' {
|
|
retroarch = retroarchBare;
|
|
cores = retroarchFull.cores;
|
|
inherit settings;
|
|
};
|
|
in
|
|
mkRom (
|
|
assert lib.assertMsg (lib.stringLength emulator > 0) "Rom ${name} need an emulator name";
|
|
{
|
|
runtimeInputs = [ retroarch ];
|
|
# To do add a check for the emulator
|
|
command = "retroarch -L ${emulator} ${builtins.placeholder "out"}/usr/share/${filename}";
|
|
inherit meta src name;
|
|
})
|