|
| 1 | +{ |
| 2 | + python3Packages, |
| 3 | + fetchFromGitHub, |
| 4 | + lib, |
| 5 | + bash, |
| 6 | + hatch, |
| 7 | + scdoc, |
| 8 | + replaceVars, |
| 9 | + fetchpatch2, |
| 10 | +}: |
| 11 | +python3Packages.buildPythonPackage rec { |
| 12 | + pname = "umu-launcher-unwrapped"; |
| 13 | + version = "1.1.4"; |
| 14 | + |
| 15 | + src = fetchFromGitHub { |
| 16 | + owner = "Open-Wine-Components"; |
| 17 | + repo = "umu-launcher"; |
| 18 | + tag = version; |
| 19 | + hash = "sha256-TOsVK6o2V8D7CLzVOkLs8AClrZmlVQTfeii32ZIQCu4="; |
| 20 | + }; |
| 21 | + |
| 22 | + # Both patches can be safely removed with the next release |
| 23 | + patches = [ |
| 24 | + # Patch to avoid running `git describe` |
| 25 | + # Fixed by https://github.com/Open-Wine-Components/umu-launcher/pull/289 upstream |
| 26 | + (replaceVars ./no-umu-version-json.patch { inherit version; }) |
| 27 | + # Patch to use PREFIX in the installer call |
| 28 | + (fetchpatch2 { |
| 29 | + url = "https://github.com/Open-Wine-Components/umu-launcher/commit/602a2f84a05a63f7b1b1c4d8ca85d99fdaec2cd2.diff"; |
| 30 | + hash = "sha256-BMinTXr926V3HlzHHabxHKvy8quEvxsZKu1hoTGQT00="; |
| 31 | + }) |
| 32 | + ]; |
| 33 | + |
| 34 | + nativeBuildInputs = [ |
| 35 | + python3Packages.build |
| 36 | + hatch |
| 37 | + scdoc |
| 38 | + python3Packages.installer |
| 39 | + ]; |
| 40 | + |
| 41 | + pythonPath = [ |
| 42 | + python3Packages.filelock |
| 43 | + python3Packages.xlib |
| 44 | + ]; |
| 45 | + |
| 46 | + pyproject = false; |
| 47 | + configureScript = "./configure.sh"; |
| 48 | + |
| 49 | + makeFlags = [ |
| 50 | + "PYTHONDIR=$(PREFIX)/${python3Packages.python.sitePackages}" |
| 51 | + "PYTHON_INTERPRETER=${lib.getExe python3Packages.python}" |
| 52 | + # Override RELEASEDIR to avoid running `git describe` |
| 53 | + "RELEASEDIR=${pname}-${version}" |
| 54 | + "SHELL_INTERPRETER=${lib.getExe bash}" |
| 55 | + ]; |
| 56 | + |
| 57 | + meta = { |
| 58 | + description = "Unified launcher for Windows games on Linux using the Steam Linux Runtime and Tools"; |
| 59 | + changelog = "https://github.com/Open-Wine-Components/umu-launcher/releases/tag/${version}"; |
| 60 | + homepage = "https://github.com/Open-Wine-Components/umu-launcher"; |
| 61 | + license = lib.licenses.gpl3; |
| 62 | + mainProgram = "umu-run"; |
| 63 | + maintainers = with lib.maintainers; [ |
| 64 | + diniamo |
| 65 | + MattSturgeon |
| 66 | + fuzen |
| 67 | + ]; |
| 68 | + platforms = lib.platforms.linux; |
| 69 | + }; |
| 70 | +} |
0 commit comments