From cf98b44d3fb9e3eef43845dbe7fec0cd9461341d Mon Sep 17 00:00:00 2001 From: volzhs Date: Sat, 5 Sep 2015 15:47:23 +0900 Subject: [PATCH 1/3] fix game window runs only 800x600 --- main/main.cpp | 1 - 1 file changed, 1 deletion(-) diff --git a/main/main.cpp b/main/main.cpp index 452e95660fb..c9ccf8cd7ae 100644 --- a/main/main.cpp +++ b/main/main.cpp @@ -335,7 +335,6 @@ Error Main::setup(const char *execpath,int argc, char *argv[],bool p_second_phas init_custom_pos=Point2(x,y); init_use_custom_pos=true; - force_res=true; N=I->next()->next(); } else { From 4d900859e2a62d73710ee71e73ebfbebb9c0003c Mon Sep 17 00:00:00 2001 From: punto- Date: Wed, 9 Sep 2015 21:57:49 +0200 Subject: [PATCH 2/3] ios build with osxcross --- platform/iphone/SCsub | 2 +- platform/iphone/detect.py | 11 +++++++---- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/platform/iphone/SCsub b/platform/iphone/SCsub index d495e3b5fc5..d755b3dba03 100644 --- a/platform/iphone/SCsub +++ b/platform/iphone/SCsub @@ -34,5 +34,5 @@ obj = env_ios.Object('godot_iphone.cpp') prog = None prog = env_ios.Program('#bin/godot', [obj] + iphone_lib) -action = "dsymutil "+File(prog)[0].path+" -o " + File(prog)[0].path + ".dSYM" +action = "$IPHONEPATH/usr/bin/dsymutil "+File(prog)[0].path+" -o " + File(prog)[0].path + ".dSYM" env.AddPostAction(prog, action) diff --git a/platform/iphone/detect.py b/platform/iphone/detect.py index 6be3539b9d0..e7a262a2bc2 100644 --- a/platform/iphone/detect.py +++ b/platform/iphone/detect.py @@ -11,7 +11,8 @@ def get_name(): def can_build(): import sys - if sys.platform == 'darwin': + import os + if sys.platform == 'darwin' or os.environ.has_key("OSXCROSS_IOS"): return True return False @@ -28,6 +29,7 @@ def get_opts(): ('ios_gles22_override', 'Force GLES2.0 on iOS', 'yes'), ('ios_appirater', 'Enable Appirater', 'no'), ('ios_exceptions', 'Use exceptions when compiling on playbook', 'yes'), + ('ios_triple', 'Triple for ios toolchain', ''), ] def get_flags(): @@ -48,9 +50,10 @@ def configure(env): # env['CC'] = '$IPHONEPATH/Developer/usr/bin/gcc' # env['CXX'] = '$IPHONEPATH/Developer/usr/bin/g++' - env['CC'] = '$IPHONEPATH/usr/bin/clang' - env['CXX'] = '$IPHONEPATH/usr/bin/clang++' - env['AR'] = 'ar' + env['CC'] = '$IPHONEPATH/usr/bin/${ios_triple}clang' + env['CXX'] = '$IPHONEPATH/usr/bin/${ios_triple}clang++' + env['AR'] = '$IPHONEPATH/usr/bin/${ios_triple}ar' + env['RANLIB'] = '$IPHONEPATH/usr/bin/${ios_triple}ranlib' import string if (env["bits"]=="64"): From e3e93da6b94cdf14e9a6f466cf5f50a857166928 Mon Sep 17 00:00:00 2001 From: Ariel Manzur Date: Wed, 9 Sep 2015 20:24:38 +0000 Subject: [PATCH 3/3] fixed localtime thing for ios, not tested anywhere else --- drivers/unix/os_unix.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/unix/os_unix.cpp b/drivers/unix/os_unix.cpp index 314e13cee4a..05af7ee900f 100644 --- a/drivers/unix/os_unix.cpp +++ b/drivers/unix/os_unix.cpp @@ -226,7 +226,8 @@ uint64_t OS_Unix::get_unix_time() const { uint64_t OS_Unix::get_system_time_msec() const { struct timeval tv_now; gettimeofday(&tv_now, NULL); - localtime(&tv_now.tv_usec); + //localtime(&tv_now.tv_usec); + localtime((const long *)&tv_now.tv_usec); uint64_t msec = tv_now.tv_usec/1000; return msec; }