From 64a87b6516a882845cfbf836ae5b2e8055c6c18e Mon Sep 17 00:00:00 2001 From: landry Date: Sun, 1 Apr 2018 09:30:18 +0000 Subject: [PATCH] Fix build with py-game 1.9.3. A bit hackish, but newer renpy versions even forked their own version of py-game.. --- games/renpy/Makefile | 3 ++- games/renpy/patches/patch-module_core_c | 14 ++++++++++++++ games/renpy/patches/patch-module_ffdecode_c | 15 +++++++++++++++ games/renpy/patches/patch-module_setup_py | 9 +++++---- games/renpy/patches/patch-module_subpixel_c | 15 +++++++++++++++ 5 files changed, 51 insertions(+), 5 deletions(-) create mode 100644 games/renpy/patches/patch-module_core_c create mode 100644 games/renpy/patches/patch-module_ffdecode_c create mode 100644 games/renpy/patches/patch-module_subpixel_c diff --git a/games/renpy/Makefile b/games/renpy/Makefile index 151947097ba..a6a52888946 100644 --- a/games/renpy/Makefile +++ b/games/renpy/Makefile @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile,v 1.9 2014/08/21 00:49:16 bentley Exp $ +# $OpenBSD: Makefile,v 1.10 2018/04/01 09:30:18 landry Exp $ COMMENT = visual novel engine @@ -6,6 +6,7 @@ V = 6.17.7 MODPY_EGG_VERSION = ${V}.521 DISTNAME = renpy-${V}-source PKGNAME = ${DISTNAME:S/-source//} +REVISION = 0 CATEGORIES = games diff --git a/games/renpy/patches/patch-module_core_c b/games/renpy/patches/patch-module_core_c new file mode 100644 index 00000000000..d703a6a732a --- /dev/null +++ b/games/renpy/patches/patch-module_core_c @@ -0,0 +1,14 @@ +$OpenBSD: patch-module_core_c,v 1.1 2018/04/01 09:30:18 landry Exp $ + +Fix build with pygame 1.9.3 + +Index: module/core.c +--- module/core.c.orig ++++ module/core.c +@@ -1,5 +1,6 @@ + #include "renpy.h" + #include "IMG_savepng.h" ++#define PYGAME_H + #include + #include + #include diff --git a/games/renpy/patches/patch-module_ffdecode_c b/games/renpy/patches/patch-module_ffdecode_c new file mode 100644 index 00000000000..ff08718f37a --- /dev/null +++ b/games/renpy/patches/patch-module_ffdecode_c @@ -0,0 +1,15 @@ +$OpenBSD: patch-module_ffdecode_c,v 1.3 2018/04/01 09:30:18 landry Exp $ + +Fix build with pygame 1.9.3 + +Index: module/ffdecode.c +--- module/ffdecode.c.orig ++++ module/ffdecode.c +@@ -19,6 +19,7 @@ + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + */ + ++#define NO_PYGAME_C_API + #include + #include + #include diff --git a/games/renpy/patches/patch-module_setup_py b/games/renpy/patches/patch-module_setup_py index 78bf8d6c007..3b64dbcfd02 100644 --- a/games/renpy/patches/patch-module_setup_py +++ b/games/renpy/patches/patch-module_setup_py @@ -1,7 +1,8 @@ -$OpenBSD: patch-module_setup_py,v 1.1 2014/01/10 18:41:50 landry Exp $ ---- module/setup.py.orig Fri Jan 10 19:33:43 2014 -+++ module/setup.py Fri Jan 10 19:34:39 2014 -@@ -31,6 +31,7 @@ include("libavformat/avformat.h") +$OpenBSD: patch-module_setup_py,v 1.2 2018/04/01 09:30:18 landry Exp $ +Index: module/setup.py +--- module/setup.py.orig ++++ module/setup.py +@@ -72,6 +72,7 @@ include("libavformat/avformat.h") include("libavcodec/avcodec.h") include("libswscale/swscale.h") include("GL/glew.h") diff --git a/games/renpy/patches/patch-module_subpixel_c b/games/renpy/patches/patch-module_subpixel_c new file mode 100644 index 00000000000..c67a1dd35d8 --- /dev/null +++ b/games/renpy/patches/patch-module_subpixel_c @@ -0,0 +1,15 @@ +$OpenBSD: patch-module_subpixel_c,v 1.1 2018/04/01 09:30:18 landry Exp $ + +Fix build with pygame 1.9.3 + +Index: module/subpixel.c +--- module/subpixel.c.orig ++++ module/subpixel.c +@@ -7,6 +7,7 @@ + */ + + #include "renpy.h" ++#define NO_PYGAME_C_API + #include + #include + #include