1{ lib, buildPythonPackage, fetchFromGitHub, appdirs, dungeon-eos, explorerscript 2, ndspy, pillow, setuptools, skytemple-rust, tilequant, armips 3}: 4 5buildPythonPackage rec { 6 pname = "skytemple-files"; 7 version = "1.3.3"; 8 9 src = fetchFromGitHub { 10 owner = "SkyTemple"; 11 repo = pname; 12 rev = version; 13 sha256 = "01j6khn60mdmz32xkpqrzwdqibmpdpi2wvwzxgdnaim9sq0fdqws"; 14 fetchSubmodules = true; 15 }; 16 17 postPatch = '' 18 substituteInPlace skytemple_files/patch/arm_patcher.py \ 19 --replace "exec_name = os.getenv('SKYTEMPLE_ARMIPS_EXEC', f'{prefix}armips')" "exec_name = \"${armips}/bin/armips\"" 20 ''; 21 22 buildInputs = [ armips ]; 23 24 propagatedBuildInputs = [ appdirs dungeon-eos explorerscript ndspy pillow setuptools skytemple-rust tilequant ]; 25 26 doCheck = false; # requires Pokémon Mystery Dungeon ROM 27 pythonImportsCheck = [ "skytemple_files" ]; 28 29 meta = with lib; { 30 homepage = "https://github.com/SkyTemple/skytemple-files"; 31 description = "Python library to edit the ROM of Pokémon Mystery Dungeon Explorers of Sky"; 32 license = licenses.gpl3Plus; 33 maintainers = with maintainers; [ xfix marius851000 ]; 34 }; 35}