[renpy] 09/17: Rebase patches for new release.

Markus Koschany apo-guest at moszumanska.debian.org
Thu Jan 21 11:25:33 UTC 2016


This is an automated email from the git hooks/post-receive script.

apo-guest pushed a commit to branch experimental
in repository renpy.

commit f66961798008f960bb39297c53eda8b8ceb66577
Author: Markus Koschany <apo at debian.org>
Date:   Tue Jan 19 22:17:48 2016 +0100

    Rebase patches for new release.
---
 debian/patches/01_abspath.patch   | 35 +++++++++++++++++++++++++++++++++++
 debian/patches/02_traceback.patch | 39 +++++++++++++++++++++++++++++++++++++++
 debian/patches/03_checkdir.patch  | 23 +++++++++++++++++++++++
 debian/patches/04_typo.patch      | 36 ++++++++++++++++++++++++++++++++++++
 debian/patches/series             |  4 ++++
 5 files changed, 137 insertions(+)

diff --git a/debian/patches/01_abspath.patch b/debian/patches/01_abspath.patch
new file mode 100644
index 0000000..159c0a4
--- /dev/null
+++ b/debian/patches/01_abspath.patch
@@ -0,0 +1,35 @@
+From: Debian Games Team <pkg-games-devel at lists.alioth.debian.org>
+Date: Tue, 12 Jan 2016 18:15:44 +0100
+Subject: _abspath
+
+---
+ renpy.py | 9 ++++++++-
+ 1 file changed, 8 insertions(+), 1 deletion(-)
+
+diff --git a/renpy.py b/renpy.py
+index 7548cf6..5bf3214 100644
+--- a/renpy.py
++++ b/renpy.py
+@@ -74,6 +74,13 @@ def path_to_saves(gamedir, save_directory=None):
+ 
+         return rv
+ 
++    if gamedir.startswith("/usr/share/games/renpy"):
++        # The gamename is the final component of the path to the gamedir
++        gamename = gamedir[len("/usr/share/games/renpy"):]
++        if gamename.endswith("/game") or gamename.endswith("/data"):
++            gamename = gamename[:-5]
++        return os.path.expanduser("~/.renpy/") + gamename + "/saves"
++
+     if renpy.ios:
+         from pyobjus import autoclass
+         from pyobjus.objc_py_types import enum
+@@ -134,7 +141,7 @@ def path_to_saves(gamedir, save_directory=None):
+ # Returns the path to the Ren'Py base directory (containing common and
+ # the launcher, usually.)
+ def path_to_renpy_base():
+-    renpy_base = os.path.dirname(os.path.realpath(sys.argv[0]))
++    renpy_base = "/usr/share/games/renpy"
+     renpy_base = os.path.abspath(renpy_base)
+ 
+     return renpy_base
diff --git a/debian/patches/02_traceback.patch b/debian/patches/02_traceback.patch
new file mode 100644
index 0000000..9416b61
--- /dev/null
+++ b/debian/patches/02_traceback.patch
@@ -0,0 +1,39 @@
+From: Debian Games Team <pkg-games-devel at lists.alioth.debian.org>
+Date: Tue, 12 Jan 2016 18:15:44 +0100
+Subject: _traceback
+
+===================================================================
+---
+ renpy/error.py | 16 +++++++++++++++-
+ 1 file changed, 15 insertions(+), 1 deletion(-)
+
+diff --git a/renpy/error.py b/renpy/error.py
+index d70fe2a..07d34e0 100644
+--- a/renpy/error.py
++++ b/renpy/error.py
+@@ -216,10 +216,24 @@ def report_exception(e, editor=True):
+     simple = simple.getvalue()
+     full = full.getvalue()
+ 
++    try:
++        if not os.path.isdir(os.path.expanduser("~/.renpy")):
++            os.makedirs(os.path.expanduser("~/.renpy"))
++    except:
++        pass
++
+     # Inside of the file, which may not be openable.
+     try:
++        tbdir = renpy.config.savedir
++        if tbdir[-1] == '/':
++           tbdir = tbdir[:-1]
++        tbdir = os.path.dirname(tbdir) + "/"
++        try:
++            os.makedirs(tbdir)
++        except:
++            pass
+ 
+-        f, traceback_fn = open_error_file("traceback.txt", "w")
++        f, traceback_fn = open_error_file(tbdir + "traceback.txt", "w")
+ 
+         f.write(codecs.BOM_UTF8)
+ 
diff --git a/debian/patches/03_checkdir.patch b/debian/patches/03_checkdir.patch
new file mode 100644
index 0000000..465e569
--- /dev/null
+++ b/debian/patches/03_checkdir.patch
@@ -0,0 +1,23 @@
+From: Debian Games Team <pkg-games-devel at lists.alioth.debian.org>
+Date: Tue, 12 Jan 2016 18:15:44 +0100
+Subject: _checkdir
+
+---
+ renpy/main.py | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/renpy/main.py b/renpy/main.py
+index f8bee19..f0e76a1 100644
+--- a/renpy/main.py
++++ b/renpy/main.py
+@@ -253,6 +253,10 @@ def main():
+ 
+     log_clock("Early init")
+ 
++    # Check if the game directory exists and is a directory
++    if not os.path.isdir(renpy.config.gamedir):
++        raise Exception("The game directory '%s' doesn't exist" % renpy.config.gamedir)
++
+     # Note the game directory.
+     game.basepath = renpy.config.gamedir
+     renpy.config.searchpath = [ renpy.config.gamedir ]
diff --git a/debian/patches/04_typo.patch b/debian/patches/04_typo.patch
new file mode 100644
index 0000000..a18df92
--- /dev/null
+++ b/debian/patches/04_typo.patch
@@ -0,0 +1,36 @@
+From: Debian Games Team <pkg-games-devel at lists.alioth.debian.org>
+Date: Tue, 12 Jan 2016 18:15:44 +0100
+Subject: _typo
+
+===================================================================
+---
+ module/gen/renpy.angle.gldraw.c | 2 +-
+ module/gen/renpy.gl.gldraw.c    | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/module/gen/renpy.angle.gldraw.c b/module/gen/renpy.angle.gldraw.c
+index 0740efe..364ebd1 100644
+--- a/module/gen/renpy.angle.gldraw.c
++++ b/module/gen/renpy.angle.gldraw.c
+@@ -2258,7 +2258,7 @@ static int __pyx_pf_5renpy_5angle_6gldraw_6GLDraw___init__(struct __pyx_obj_5ren
+ 
+ /* Python wrapper */
+ static PyObject *__pyx_pw_5renpy_5angle_6gldraw_6GLDraw_3set_mode(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
+-static char __pyx_doc_5renpy_5angle_6gldraw_6GLDraw_2set_mode[] = "\n        This changes the video mode. It also initializes OpenGL, if it\n        can. It returns True if it was succesful, or False if OpenGL isn't\n        working for some reason.\n        ";
++static char __pyx_doc_5renpy_5angle_6gldraw_6GLDraw_2set_mode[] = "\n        This changes the video mode. It also initializes OpenGL, if it\n        can. It returns True if it was successful, or False if OpenGL isn't\n        working for some reason.\n        ";
+ static PyObject *__pyx_pw_5renpy_5angle_6gldraw_6GLDraw_3set_mode(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
+   PyObject *__pyx_v_virtual_size = 0;
+   PyObject *__pyx_v_physical_size = 0;
+diff --git a/module/gen/renpy.gl.gldraw.c b/module/gen/renpy.gl.gldraw.c
+index 222640f..a2358ad 100644
+--- a/module/gen/renpy.gl.gldraw.c
++++ b/module/gen/renpy.gl.gldraw.c
+@@ -2268,7 +2268,7 @@ static int __pyx_pf_5renpy_2gl_6gldraw_6GLDraw___init__(struct __pyx_obj_5renpy_
+ 
+ /* Python wrapper */
+ static PyObject *__pyx_pw_5renpy_2gl_6gldraw_6GLDraw_3set_mode(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
+-static char __pyx_doc_5renpy_2gl_6gldraw_6GLDraw_2set_mode[] = "\n        This changes the video mode. It also initializes OpenGL, if it\n        can. It returns True if it was succesful, or False if OpenGL isn't\n        working for some reason.\n        ";
++static char __pyx_doc_5renpy_2gl_6gldraw_6GLDraw_2set_mode[] = "\n        This changes the video mode. It also initializes OpenGL, if it\n        can. It returns True if it was successful, or False if OpenGL isn't\n        working for some reason.\n        ";
+ static PyObject *__pyx_pw_5renpy_2gl_6gldraw_6GLDraw_3set_mode(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
+   PyObject *__pyx_v_virtual_size = 0;
+   PyObject *__pyx_v_physical_size = 0;
diff --git a/debian/patches/series b/debian/patches/series
new file mode 100644
index 0000000..f4dfdf9
--- /dev/null
+++ b/debian/patches/series
@@ -0,0 +1,4 @@
+01_abspath.patch
+02_traceback.patch
+03_checkdir.patch
+04_typo.patch

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/renpy.git



More information about the Pkg-games-commits mailing list