From d4e36358020d616a374bcff4bd0a398a761ceee4 Mon Sep 17 00:00:00 2001 From: Richard Date: Fri, 4 Nov 2016 12:47:04 +0200 Subject: [PATCH 1/3] Removed std out re-direction --- tools/templates/{{ cookiecutter.project_name }}-ios/main.m | 7 ------- 1 file changed, 7 deletions(-) diff --git a/tools/templates/{{ cookiecutter.project_name }}-ios/main.m b/tools/templates/{{ cookiecutter.project_name }}-ios/main.m index 99f2325..3627339 100644 --- a/tools/templates/{{ cookiecutter.project_name }}-ios/main.m +++ b/tools/templates/{{ cookiecutter.project_name }}-ios/main.m @@ -121,13 +121,6 @@ void load_custom_builtin_importer() { "import sys, imp\n" \ "from os import environ\n" \ "from os.path import exists, join\n" \ - "# Fake redirection when we run the app without xcode\n" \ - "if 'CFLOG_FORCE_STDERR' not in environ:\n" \ - " class fakestd(object):\n" \ - " def write(self, *args, **kw): pass\n" \ - " def flush(self, *args, **kw): pass\n" \ - " sys.stdout = fakestd()\n" \ - " sys.stderr = fakestd()\n" \ "# Custom builtin importer for precompiled modules\n" \ "class CustomBuiltinImporter(object):\n" \ " def find_module(self, fullname, mpath=None):\n" \ From f48f66363cd18092e7bf8516d6de7e28b70a8b23 Mon Sep 17 00:00:00 2001 From: Richard Date: Sun, 6 Nov 2016 14:46:31 +0200 Subject: [PATCH 2/3] Added corrected check for KIVY_NO_CONSOLE flag --- .../templates/{{ cookiecutter.project_name }}-ios/main.m | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/tools/templates/{{ cookiecutter.project_name }}-ios/main.m b/tools/templates/{{ cookiecutter.project_name }}-ios/main.m index 3627339..80468a8 100644 --- a/tools/templates/{{ cookiecutter.project_name }}-ios/main.m +++ b/tools/templates/{{ cookiecutter.project_name }}-ios/main.m @@ -121,6 +121,14 @@ void load_custom_builtin_importer() { "import sys, imp\n" \ "from os import environ\n" \ "from os.path import exists, join\n" \ + "# Fake redirection to supress console output\n" \ + "if environ.get('KIVY_NO_CONSOLE', '0') == '1':\n" \ + " print('Killing console. Remove me!')\n" \ + " class fakestd(object):\n" \ + " def write(self, *args, **kw): pass\n" \ + " def flush(self, *args, **kw): pass\n" \ + " sys.stdout = fakestd()\n" \ + " sys.stderr = fakestd()\n" \ "# Custom builtin importer for precompiled modules\n" \ "class CustomBuiltinImporter(object):\n" \ " def find_module(self, fullname, mpath=None):\n" \ From d661336935a8920e1e5c5971ab454b36773e6a92 Mon Sep 17 00:00:00 2001 From: Richard Date: Sun, 6 Nov 2016 14:47:55 +0200 Subject: [PATCH 3/3] Removed test line --- tools/templates/{{ cookiecutter.project_name }}-ios/main.m | 1 - 1 file changed, 1 deletion(-) diff --git a/tools/templates/{{ cookiecutter.project_name }}-ios/main.m b/tools/templates/{{ cookiecutter.project_name }}-ios/main.m index 80468a8..a5f6c4d 100644 --- a/tools/templates/{{ cookiecutter.project_name }}-ios/main.m +++ b/tools/templates/{{ cookiecutter.project_name }}-ios/main.m @@ -123,7 +123,6 @@ void load_custom_builtin_importer() { "from os.path import exists, join\n" \ "# Fake redirection to supress console output\n" \ "if environ.get('KIVY_NO_CONSOLE', '0') == '1':\n" \ - " print('Killing console. Remove me!')\n" \ " class fakestd(object):\n" \ " def write(self, *args, **kw): pass\n" \ " def flush(self, *args, **kw): pass\n" \