mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-08-06 00:48:18 -07:00
games-emulation/zsnes: add 2.2.1
Not looked in-depth but seems some code was shifted around from asm to C and it introduced new issues with strict-aliasing lto assuming they weren't already there. Not verified given old version fails to build wrt bug #979230, preasumably caused by newer nasm, and is fixed in this one. Closes: https://bugs.gentoo.org/979230 Signed-off-by: Ionen Wolkens <ionen@gentoo.org>
This commit is contained in:
@@ -1 +1,2 @@
|
||||
DIST zsnes-2.1.1.tar.gz 1211001 BLAKE2B 7f40305c86adf80dc6f4bec24dbb82929abc8d4dac54cb81693f9e74968a7300c88b99122cd32abea1bd3b91f0476925433581734e446a9d7b61cfc2e6359fe8 SHA512 10e71c5f9bcebf889625696f6f83a40cb7529291f3ef37113ddf8c0f231e199e6d4ca48274a4bee54996290ec9cf119b9ffc90c0df316da0097df18a043529af
|
||||
DIST zsnes-2.2.1.tar.gz 1241244 BLAKE2B 28f6f5b9acffd6109f30fbed1952866ed7952679124e7d39bd6e2004a53f3124b984489c848965fdaa882b1f488fd35259d22d6cdf3bd6cf5ce7bafb2bc5f5a1 SHA512 599fe81b296e00ad47158d57fc1d844ebd58639054b4d39c3a961bb8c9a057c1132b2dd9c5476bccb96da7bd5cf54073e76db54e2cb0a75d080ade73e3795214
|
||||
|
||||
72
games-emulation/zsnes/zsnes-2.2.1.ebuild
Normal file
72
games-emulation/zsnes/zsnes-2.2.1.ebuild
Normal file
@@ -0,0 +1,72 @@
|
||||
# Copyright 2021-2026 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
|
||||
PYTHON_COMPAT=( python3_{12..14} )
|
||||
inherit flag-o-matic multilib python-any-r1 toolchain-funcs xdg
|
||||
|
||||
DESCRIPTION="Fork of the classic Super Nintendo emulator"
|
||||
HOMEPAGE="https://github.com/xyproto/zsnes/ https://www.zsnes.com/"
|
||||
SRC_URI="
|
||||
https://github.com/xyproto/zsnes/archive/refs/tags/${PV}.tar.gz
|
||||
-> ${P}.tar.gz
|
||||
"
|
||||
|
||||
LICENSE="GPL-2"
|
||||
SLOT="0"
|
||||
KEYWORDS="-* ~amd64 ~x86"
|
||||
IUSE="ao custom-cflags pipewire"
|
||||
|
||||
RDEPEND="
|
||||
media-libs/libglvnd[X,abi_x86_32(-)]
|
||||
media-libs/libpng:=[abi_x86_32(-)]
|
||||
media-libs/libsdl3[abi_x86_32(-),opengl]
|
||||
virtual/zlib:=[abi_x86_32(-)]
|
||||
ao? ( media-libs/libao[abi_x86_32(-)] )
|
||||
pipewire? ( media-video/pipewire:=[abi_x86_32(-)] )
|
||||
"
|
||||
DEPEND="${RDEPEND}"
|
||||
BDEPEND="
|
||||
${PYTHON_DEPS}
|
||||
dev-lang/nasm
|
||||
virtual/pkgconfig
|
||||
virtual/zlib:=
|
||||
"
|
||||
|
||||
PATCHES=(
|
||||
"${FILESDIR}"/${PN}-2.1.0-cc-quotes.patch
|
||||
)
|
||||
|
||||
src_compile() {
|
||||
# Makefile forces many CFLAGS that are questionable, but zsnes' ancient x86
|
||||
# asm is fragile, not pic safe (bug #427104), broken by F_S=3 (formerly
|
||||
# broken with =2 as well), and can be affected by -march=* and similar.
|
||||
# Stick to upstream's choices, this is non-portable either way.
|
||||
if use !custom-cflags; then
|
||||
strip-flags
|
||||
append-cppflags -U_FORTIFY_SOURCE # to disable =3, Makefile enables =2
|
||||
|
||||
# furthermore fails with -Werror=strict-aliasing+lto-type-mismatch
|
||||
append-cflags -fno-strict-aliasing
|
||||
filter-lto
|
||||
fi
|
||||
|
||||
use amd64 && multilib_toolchain_setup x86
|
||||
tc-export CC
|
||||
append-cflags ${CPPFLAGS}
|
||||
|
||||
ZSNES_MAKEARGS=(
|
||||
ARCH=LINUX
|
||||
PREFIX="${EPREFIX}"/usr
|
||||
WITH_AO=$(usex ao)
|
||||
WITH_PIPEWIRE=$(usex pipewire)
|
||||
)
|
||||
|
||||
emake "${ZSNES_MAKEARGS[@]}"
|
||||
}
|
||||
|
||||
src_install() {
|
||||
emake "${ZSNES_MAKEARGS[@]}" DESTDIR="${D}" install
|
||||
einstalldocs
|
||||
}
|
||||
Reference in New Issue
Block a user