From 4d96b15775c4144cec3224c8913fac01bf6bd003 Mon Sep 17 00:00:00 2001 From: Andreas Sturmlechner Date: Sun, 5 May 2019 17:12:36 +0200 Subject: games-action/dxx-rebirth: Fix build against physfs-3 Closes: https://bugs.gentoo.org/653014 Package-Manager: Portage-2.3.66, Repoman-2.3.12 Signed-off-by: Andreas Sturmlechner --- .../dxx-rebirth/dxx-rebirth-0.59.100.ebuild | 11 ++++---- ...-rebirth-0.59.100-physfs-3-no-deprecation.patch | 30 ++++++++++++++++++++++ 2 files changed, 36 insertions(+), 5 deletions(-) create mode 100644 games-action/dxx-rebirth/files/dxx-rebirth-0.59.100-physfs-3-no-deprecation.patch (limited to 'games-action') diff --git a/games-action/dxx-rebirth/dxx-rebirth-0.59.100.ebuild b/games-action/dxx-rebirth/dxx-rebirth-0.59.100.ebuild index 048eb3cb263c..df2171429517 100644 --- a/games-action/dxx-rebirth/dxx-rebirth-0.59.100.ebuild +++ b/games-action/dxx-rebirth/dxx-rebirth-0.59.100.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2018 Gentoo Foundation +# Copyright 1999-2019 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=6 @@ -51,9 +51,11 @@ RDEPEND="${DEPEND} S="${WORKDIR}/${MY_P}" -# Remove hardcoded optimisation flags. -# Change share path to use old d1x/d2x locations. -PATCHES=( "${FILESDIR}"/${P}-{flags,sharepath}.patch ) +PATCHES=( + "${FILESDIR}"/${P}-flags.patch # Remove hardcoded optimisation flags. + "${FILESDIR}"/${P}-sharepath.patch # Change share path to use old d1x/d2x locations. + "${FILESDIR}"/${P}-physfs-3-no-deprecation.patch # bug #653014 +) src_compile() { tc-export CXX @@ -102,6 +104,5 @@ pkg_postinst() { elog "To play the game enable USE=\"data\" or manually " elog "copy the files to ${EPREFIX}/usr/share/games/{d1x,d2x}." elog "See each game's INSTALL.txt for details." - echo fi } diff --git a/games-action/dxx-rebirth/files/dxx-rebirth-0.59.100-physfs-3-no-deprecation.patch b/games-action/dxx-rebirth/files/dxx-rebirth-0.59.100-physfs-3-no-deprecation.patch new file mode 100644 index 000000000000..86e94d43389e --- /dev/null +++ b/games-action/dxx-rebirth/files/dxx-rebirth-0.59.100-physfs-3-no-deprecation.patch @@ -0,0 +1,30 @@ +From 8838b46e65c830e8d9ebaeaf568f186eff57d5c7 Mon Sep 17 00:00:00 2001 +From: Kp +Date: Sun, 22 Oct 2017 04:20:35 +0000 +Subject: [PATCH] Suppress PhysFS deprecation errors + +PhysFS 2.0 only offers PHYSFS_read/PHYSFS_write for I/O. PhysFS 3.0 +deprecates PHYSFS_read / PHYSFS_write and offers PHYSFS_readBytes / +PHYSFS_writeBytes. Converting Rebirth to use the new API is somewhat +invasive, and would require dropping support for PhysFS 2.0. + +For now, for compatibility with PhysFS 2.0, disable the deprecation +errors and continue to use the older functions. + +Reported-by: gabeotisbenson +--- + SConstruct | 6 ++++++ + 1 file changed, 6 insertions(+) + +diff --git a/SConstruct b/SConstruct +index 560a6ef1a..78491cb1a 100644 +--- a/SConstruct ++++ b/SConstruct +@@ -3177,6 +3177,7 @@ + def adjust_environment(self,program,env): + env.Append( + CXXFLAGS = ['-pthread'], ++ CPPDEFINES = [('PHYSFS_DEPRECATED', '')], + ) + + def __init__(self,__program_instance=itertools.count(1)): -- cgit v1.2.3-65-gdbad