summaryrefslogtreecommitdiff
path: root/platform/iphone/SCsub
blob: 4a4e06cc0f46b4812558e8a3a693893e9ed64978 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
Import('env')

iphone_lib = [

	'os_iphone.cpp',
	#'rasterizer_iphone.cpp',
	'audio_driver_iphone.cpp',
	'sem_iphone.cpp',
	'gl_view.mm',
	'main.m',
	'app_delegate.mm',
	'view_controller.mm',
	'game_center.mm',
	'in_app_store.mm',
	'Appirater.m',
]

#env.Depends('#core/math/vector3.h', 'vector3_psp.h')

#iphone_lib = env.Library('iphone', iphone_lib)

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('godot_iphone.cpp')

prog = None
if env["target"]=="release" || env["target"] == "release_debug":
	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_ios.Program('#bin/godot', [obj] + iphone_lib)
	action = "dsymutil "+File(prog)[0].path+" -o bin/godot.iphone.dSYM"
	env.AddPostAction(prog, action)