summaryrefslogtreecommitdiff
path: root/platform
diff options
context:
space:
mode:
Diffstat (limited to 'platform')
-rw-r--r--platform/isim/SCsub22
-rw-r--r--platform/isim/detect.py18
2 files changed, 31 insertions, 9 deletions
diff --git a/platform/isim/SCsub b/platform/isim/SCsub
index 6fb568465e..e7de935b2e 100644
--- a/platform/isim/SCsub
+++ b/platform/isim/SCsub
@@ -5,11 +5,14 @@ iphone_lib = [
'#platform/iphone/os_iphone.cpp',
#'#platform/iphone/rasterizer_iphone.cpp',
'#platform/iphone/audio_driver_iphone.cpp',
+ '#platform/iphone/sem_iphone.cpp',
'#platform/iphone/gl_view.mm',
'#platform/iphone/main.m',
'#platform/iphone/app_delegate.mm',
'#platform/iphone/view_controller.mm',
- '#platform/iphone/scoreloop_ios.mm',
+ '#platform/iphone/game_center.mm',
+ '#platform/iphone/in_app_store.mm',
+ '#platform/iphone/Appirater.m',
]
@@ -17,14 +20,25 @@ iphone_lib = [
#iphone_lib = env.Library('iphone', iphone_lib)
-obj = env.Object('#platform/iphone/godot_iphone.cpp')
+env_ios = env.Clone();
+
+if env['ios_gles22_override'] == "yes":
+ env_ios.Append(CPPFLAGS=['-DGLES2_OVERRIDE'])
+
+if env['ios_GLES1_override'] == "yes":
+ env_ios.Append(CPPFLAGS=['-DGLES1_OVERRIDE'])
+
+if env['ios_appirater'] == "yes":
+ env_ios.Append(CPPFLAGS=['-DAPPIRATER_ENABLED'])
+
+obj = env_ios.Object('#platform/iphone/godot_iphone.cpp')
prog = None
if env["target"]=="release":
- prog = env.Program('#bin/godot_iphone_opt', [obj] + iphone_lib)
+ prog = env_ios.Program('#bin/godot_opt', [obj] + iphone_lib)
#action = "dsymutil "+File(prog)[0].path+" -o ../build/script_exec/build/Debug-iphoneos/script_exec.app.dSYM"
#env.AddPostAction(prog, action)
else:
- prog = env.Program('#bin/godot', [obj] + iphone_lib)
+ prog = env_ios.Program('#bin/godot', [obj] + iphone_lib)
#action = "dsymutil "+File(prog)[0].path+" -o ../build/script_exec/build/Debug-iphoneos/script_exec.app.dSYM"
#env.AddPostAction(prog, action)
diff --git a/platform/isim/detect.py b/platform/isim/detect.py
index 8deabbf311..196d269deb 100644
--- a/platform/isim/detect.py
+++ b/platform/isim/detect.py
@@ -21,8 +21,14 @@ def get_opts():
return [
('ISIMPLATFORM', 'name of the iphone platform', 'iPhoneSimulator'),
- ('ISIMPATH', 'the path to iphone toolchain', '/Developer/Platforms/${ISIMPLATFORM}.platform'),
- ('ISIMSDK', 'path to the iphone SDK', '$ISIMPATH/Developer/SDKs/${ISIMPLATFORM}4.3.sdk'),
+ ('ISIMPATH', 'the path to iphone toolchain', '/Applications/Xcode.app/Contents/Developer/Platforms/${ISIMPLATFORM}.platform'),
+ ('ISIMSDK', 'path to the iphone SDK', '$ISIMPATH/Developer/SDKs/${ISIMPLATFORM}7.0.sdk'),
+ ('game_center', 'Support for game center', 'yes'),
+ ('store_kit', 'Support for in-app store', 'yes'),
+ ('ios_gles22_override', 'Force GLES2.0 on iOS', 'yes'),
+ ('ios_GLES1_override', 'Force legacy GLES (1.1) on iOS', 'no'),
+ ('ios_appirater', 'Enable Appirater', 'no'),
+ ('ios_exceptions', 'Use exceptions when compiling on playbook', 'no'),
]
def get_flags():
@@ -31,6 +37,8 @@ def get_flags():
('lua', 'no'),
('tools', 'yes'),
('nedmalloc', 'no'),
+ ('webp', 'yes'),
+ ('module_FacebookScorer_ios_enabled', 'no'),
]
@@ -50,12 +58,12 @@ def configure(env):
env['AR'] = 'ar'
import string
- env['CCFLAGS'] = string.split('-arch i386 -fobjc-abi-version=2 -fobjc-legacy-dispatch -fmessage-length=0 -fpascal-strings -fasm-blocks -Wall -D__IPHONE_OS_VERSION_MIN_REQUIRED=40100 -isysroot $ISIMSDK -mmacosx-version-min=10.6 -DCUSTOM_MATRIX_TRANSFORM_H=\\\"build/iphone/matrix4_iphone.h\\\" -DCUSTOM_VECTOR3_TRANSFORM_H=\\\"build/iphone/vector3_iphone.h\\\"')
+ env['CCFLAGS'] = string.split('-arch i386 -fobjc-abi-version=2 -fobjc-legacy-dispatch -fmessage-length=0 -fpascal-strings -fasm-blocks -Wall -D__IPHONE_OS_VERSION_MIN_REQUIRED=40100 -isysroot $ISIMSDK -mios-simulator-version-min=4.3 -DCUSTOM_MATRIX_TRANSFORM_H=\\\"build/iphone/matrix4_iphone.h\\\" -DCUSTOM_VECTOR3_TRANSFORM_H=\\\"build/iphone/vector3_iphone.h\\\"')
env.Append(LINKFLAGS=['-arch', 'i386',
- #'-miphoneos-version-min=2.2.1',
+ '-mios-simulator-version-min=4.3',
'-isysroot', '$ISIMSDK',
- '-mmacosx-version-min=10.6',
+ #'-mmacosx-version-min=10.6',
'-Xlinker',
'-objc_abi_version',
'-Xlinker', '2',