diff options
author | 2023-11-19 00:32:34 -0500 | |
---|---|---|
committer | 2023-11-19 00:53:29 -0500 | |
commit | 18a6f5c9cf0c85a300cd8eac4610d6a64b3e9ce7 (patch) | |
tree | a259e462e23b30a3e21df01c7ddaed99f49de540 /games-emulation | |
parent | media-video/mpv: update vulkan-interop comment (diff) | |
download | gentoo-18a6f5c9cf0c85a300cd8eac4610d6a64b3e9ce7.tar.gz gentoo-18a6f5c9cf0c85a300cd8eac4610d6a64b3e9ce7.tar.bz2 gentoo-18a6f5c9cf0c85a300cd8eac4610d6a64b3e9ce7.zip |
games-emulation/pcsx2_patches: add 0_p20231117
Signed-off-by: Ionen Wolkens <ionen@gentoo.org>
Diffstat (limited to 'games-emulation')
-rw-r--r-- | games-emulation/pcsx2_patches/Manifest | 1 | ||||
-rw-r--r-- | games-emulation/pcsx2_patches/pcsx2_patches-0_p20231117.ebuild | 55 |
2 files changed, 56 insertions, 0 deletions
diff --git a/games-emulation/pcsx2_patches/Manifest b/games-emulation/pcsx2_patches/Manifest index 93eb1b0071c9..459675564d27 100644 --- a/games-emulation/pcsx2_patches/Manifest +++ b/games-emulation/pcsx2_patches/Manifest @@ -1 +1,2 @@ DIST pcsx2_patches-0_p20231015.tar.gz 626844 BLAKE2B cde4e81aa354839f4e49a20cbf3d375704b9a09cf30283bfe61c0b2fcd213dd0e33431875eba3d7f5fc4ca45cb779ba1916f787464a922a5cfc484e75b727205 SHA512 6a53806ff8f348946539fb3f960e91bc40d01f8c7d6acd2e07cfbea938bd5abf4d820b1c26f19b46d103438d32325c02942a879ce3f500e30a6f5fe8b776d46c +DIST pcsx2_patches-0_p20231117.tar.gz 638316 BLAKE2B 331d2ceec0c9e10d5b8cf344a432561173083a37000f8fa3f3890e001a588884e7253bf93d5ca624d36489c9e2f4c0a865de3357d415e9f25d422bedd1106b93 SHA512 7a55a70627b045fd426e88c94e72f191adf72ee01917f9963d4bbfc4a9f96e361efb7bb86487aec4067886458779b42228fd0c5c62f2f07dfada99ba89550d8c diff --git a/games-emulation/pcsx2_patches/pcsx2_patches-0_p20231117.ebuild b/games-emulation/pcsx2_patches/pcsx2_patches-0_p20231117.ebuild new file mode 100644 index 000000000000..d90b0959a70f --- /dev/null +++ b/games-emulation/pcsx2_patches/pcsx2_patches-0_p20231117.ebuild @@ -0,0 +1,55 @@ +# Copyright 2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{10..12} ) +inherit python-any-r1 + +if [[ ${PV} == 9999 ]]; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/PCSX2/pcsx2_patches.git" +else + HASH_PCSX2_PATCHES=d6195fdc69add33dcc29fd973568896a8e8e6247 + SRC_URI=" + https://github.com/PCSX2/pcsx2_patches/archive/${HASH_PCSX2_PATCHES}.tar.gz + -> ${P}.tar.gz + " + S=${WORKDIR}/${PN}-${HASH_PCSX2_PATCHES} + KEYWORDS="~amd64" +fi + +DESCRIPTION="Collection of game patches for use with PCSX2 (e.g. widescreen hacks)" +HOMEPAGE="https://github.com/PCSX2/pcsx2_patches/" + +# these are normally distributed by upstream with PCSX2 which is GPL-3+ +LICENSE="GPL-3+" +SLOT="0" + +BDEPEND="${PYTHON_DEPS}" + +src_compile() { + # upstream uses a constantly replaced "latest" patches.zip (currently no + # real releases), and github's .zip archives cannot be used either due to + # having the patches/ subdirectory -- so we use a snapshot and repack + # (could use app-arch/zip, but python is more likely to skip a dependency) + ebegin "Creating patches.zip" + "${PYTHON}" - <<-EOF + import pathlib + from zipfile import ZipFile, ZIP_DEFLATED + + patches = pathlib.Path("patches/") + + with ZipFile("patches.zip", "w", ZIP_DEFLATED, compresslevel=9) as archive: + for file in patches.iterdir(): + archive.write(file, arcname=file.name) + EOF + eend ${?} || die +} + +src_install() { + insinto /usr/lib/pcsx2/resources + doins patches.zip + + einstalldocs +} |