summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIonen Wolkens <ionen@gentoo.org>2023-07-24 19:36:48 -0400
committerIonen Wolkens <ionen@gentoo.org>2023-07-24 20:01:12 -0400
commitcb4d856379336e6d63e354a6255afc7df538777d (patch)
treebd62e894f5ecea3a4f851714a5f2c631422af203 /games-emulation
parentgames-emulation/pcsx2: sync live (diff)
downloadgentoo-cb4d856379336e6d63e354a6255afc7df538777d.tar.gz
gentoo-cb4d856379336e6d63e354a6255afc7df538777d.tar.bz2
gentoo-cb4d856379336e6d63e354a6255afc7df538777d.zip
games-emulation/pcsx2_patches: add 0_p20230722
Signed-off-by: Ionen Wolkens <ionen@gentoo.org>
Diffstat (limited to 'games-emulation')
-rw-r--r--games-emulation/pcsx2_patches/Manifest1
-rw-r--r--games-emulation/pcsx2_patches/pcsx2_patches-0_p20230722.ebuild54
2 files changed, 55 insertions, 0 deletions
diff --git a/games-emulation/pcsx2_patches/Manifest b/games-emulation/pcsx2_patches/Manifest
index 471531cc9eba..b15da43db636 100644
--- a/games-emulation/pcsx2_patches/Manifest
+++ b/games-emulation/pcsx2_patches/Manifest
@@ -1 +1,2 @@
DIST pcsx2_patches-0_p20230623.tar.gz 598611 BLAKE2B 5a2fb1b31f9448064d7ce46c11b1dadbf1960403c082c8cee5a4c897e9c7db334a70d1f088ad18893bad89e12ef4369e2a6cba3e493fe11846848180a755b0c4 SHA512 55b7221c8f5124a44f73aa552491d1ceac796e0c34179439ba2a599891691ece19ad35b16600fa3eea1031fdcf6f5f2ee2d9da9226656ade1413b83c983383a9
+DIST pcsx2_patches-0_p20230722.tar.gz 605026 BLAKE2B 47bc0d7676d50f5e1ec60cc473e9290070996e8159260a35a2aaabb771bc7341d248050cb5e13bb72d857709abf522f5c48a1b5a1b9f6ccbaae2c014c2511fbf SHA512 d31863829d47b77d23479e1c498990719cbfb1ddbf25786a0be9f2c2540b9c7f24f080815f4fc37ee710d4d0b75c4d9eb1dabc82564b0d092aeebab6010dc851
diff --git a/games-emulation/pcsx2_patches/pcsx2_patches-0_p20230722.ebuild b/games-emulation/pcsx2_patches/pcsx2_patches-0_p20230722.ebuild
new file mode 100644
index 000000000000..0bd2dd95b845
--- /dev/null
+++ b/games-emulation/pcsx2_patches/pcsx2_patches-0_p20230722.ebuild
@@ -0,0 +1,54 @@
+# 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=0493be5016c74373465c9d3b67bbdcdd12adb100
+ 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/share/pcsx2/resources
+ doins patches.zip
+
+ einstalldocs
+}