updated SConstruct and Makefile so that if you compile the gameengine, is always...
[blender.git] / source / gameengine / Ketsji / SConscript
1 #!/usr/bin/python
2 import sys
3
4 Import ('user_options_dict')
5 Import ('library_env')
6
7 ketsji_env = library_env.Copy ()
8
9 source_files = ['KX_WorldIpoController.cpp',
10                 'KX_WorldInfo.cpp',
11                 'KX_VisibilityActuator.cpp',
12                 'KX_VertexProxy.cpp',
13                 'KX_TrackToActuator.cpp',
14                 'KX_TouchSensor.cpp',
15                 'KX_TouchEventManager.cpp',
16                 'KX_TimeLogger.cpp',
17                 'KX_TimeCategoryLogger.cpp',
18                 'KX_SoundActuator.cpp',
19                 'KX_SG_NodeRelationships.cpp',
20                 'KX_SG_BoneParentNodeRelationship.cpp',
21                 'KX_SceneActuator.cpp',
22                 'KX_Scene.cpp',
23                 'KX_ScalingInterpolator.cpp',
24                 'KX_ScalarInterpolator.cpp',
25                 'KX_SCA_ReplaceMeshActuator.cpp',
26                 'KX_SCA_EndObjectActuator.cpp',
27                 'KX_SCA_AddObjectActuator.cpp',
28                 'KX_RaySensor.cpp',
29                 'KX_RayEventManager.cpp',
30                 'KX_RayCast.cpp',
31                 'KX_RadarSensor.cpp',
32                 'KX_PyMath.cpp',
33                 'KX_PythonInit.cpp',
34                 'KX_PyConstraintBinding.cpp',
35                 'KX_PositionInterpolator.cpp',
36                 'KX_PolygonMaterial.cpp',
37                 'KX_PhysicsObjectWrapper.cpp',
38                 'KX_OrientationInterpolator.cpp',
39                 'KX_ObjectActuator.cpp',
40                 'KX_ObColorIpoSGController.cpp',
41                 'KX_NearSensor.cpp',
42                 'KX_MouseFocusSensor.cpp',
43                 'KX_MotionState.cpp',
44                 'KX_MeshProxy.cpp',
45                 'KX_LightIpoSGController.cpp',
46                 'KX_Light.cpp',
47                 'KX_KetsjiEngine.cpp',
48                 'KX_IpoActuator.cpp',
49                 'KX_IPO_SGController.cpp',
50                 'KX_IPhysicsController.cpp',
51                 'KX_GameObject.cpp',
52                 'KX_GameActuator.cpp',
53                 'KX_EmptyObject.cpp',
54                 'KX_ConvertPhysicsObjects.cpp',
55                 'KX_ConstraintWrapper.cpp',
56                 'KX_ConstraintActuator.cpp',
57                 'KX_CDActuator.cpp',
58                 'KX_CameraIpoSGController.cpp',
59                 'KX_CameraActuator.cpp',
60                 'KX_Camera.cpp',
61                 'KX_BulletPhysicsController.cpp'
62                 ]
63
64 if user_options_dict['USE_PHYSICS'] == 'solid':
65     source_files += ['KX_SumoPhysicsController.cpp']
66     ketsji_env.Append (CPPPATH = user_options_dict['SOLID_INCLUDE'])
67
68 if user_options_dict['USE_PHYSICS'] == 'ode':
69     source_files += ['KX_OdePhysicsController.cpp']
70     ketsji_env.Append (CPPPATH = user_options_dict['SOLID_INCLUDE'])
71
72
73 ketsji_env.Append (CPPPATH = ['.',
74                               '#source/kernel/gen_system',
75                               '#intern/string',
76                               '#intern/guardedalloc',
77                               '#source/gameengine/Rasterizer/RAS_OpenGLRasterizer',
78                               '#intern/bmfont',
79                               '#intern/SoundSystem',
80                               '#intern/SoundSystem/include',
81                               '#intern/SoundSystem/openal',
82                               '#intern/SoundSystem/dummy',
83                               '#intern/SoundSystem/intern',
84                               '#source/gameengine/Converter',
85                               '#source/gameengine/BlenderRoutines',
86                               '#source/blender/imbuf',
87                               '#intern/moto/include',
88                               '#source/gameengine/Ketsji',
89                               '#source/gameengine/Ketsji/KXNetwork',
90                               '#source/blender/blenlib',
91                               '#source/blender/blenkernel',
92                               '#source/blender',
93                               '#source/blender/include',
94                               '#source/blender/makesdna',
95                               '#source/blender/python',
96                               '#source/gameengine/Rasterizer',
97                               '#source/gameengine/GameLogic',
98                               '#source/gameengine/Expressions',
99                               '#source/gameengine/Network',
100                               '#source/gameengine/SceneGraph',
101                               '#source/gameengine/Physics/common',
102                               '#source/gameengine/Physics/Bullet',
103                               '#source/gameengine/Physics/BlOde',
104                               '#source/gameengine/Physics/Dummy',
105                               '#source/gameengine/Physics/Sumo',
106                               '#source/gameengine/Physics/Sumo/include',
107                               '#source/gameengine/Physics/Sumo/Fuzzics/include',
108                               '#source/gameengine/Network/LoopBackNetwork',
109                               '#source/blender/misc',
110                               '#source/blender/blenloader'
111                              ])
112
113 if sys.platform == 'win32':
114         ketsji_env.Append (CXXFLAGS = ['/GR'])
115         ketsji_env.Append ( CCFLAGS =['/Ox'])
116 ketsji_env.Append (CPPPATH = user_options_dict['PYTHON_INCLUDE'])
117 ketsji_env.Append (CPPPATH = user_options_dict['SDL_INCLUDE'])
118 ketsji_env.Append (CPPPATH = user_options_dict['BULLET_INCLUDE'])
119
120 ketsji_env.Library (target='#'+user_options_dict['BUILD_DIR']+'/lib/KX_ketsji', source=source_files)