Building the game engine with Solid/Sumo is now optional for scons using WITH_BF_SOLID.
[blender-staging.git] / source / gameengine / Ketsji / SConscript
1 #!/usr/bin/python
2 import sys
3
4 Import ('env')
5
6 sources = env.Glob('*.cpp')
7 defs = ''
8
9 # Mathutils C files.
10 sources.extend([\
11         '#source/blender/python/api2_2x/Mathutils.c',\
12         '#source/blender/python/api2_2x/constant.c',\
13         '#source/blender/python/api2_2x/euler.c',\
14         '#source/blender/python/api2_2x/gen_utils.c',\
15         '#source/blender/python/api2_2x/matrix.c',\
16         '#source/blender/python/api2_2x/point.c',\
17         '#source/blender/python/api2_2x/quat.c',\
18         '#source/blender/python/api2_2x/vector.c',\
19 ])
20
21 incs = '. #source/blender/python/api2_2x' # Only for Mathutils! - no other deps
22
23 incs += ' #source/kernel/gen_system #intern/string #intern/guardedalloc'
24 incs += ' #source/gameengine/Rasterizer/RAS_OpenGLRasterizer #intern/bmfont'
25 incs += ' #intern/SoundSystem #intern/SoundSystem/include #intern/SoundSystem/openal'
26 incs += ' #intern/SoundSystem/dummy #intern/SoundSystem/intern #source/gameengine/Converter'
27 incs += ' #source/gameengine/BlenderRoutines #source/blender/imbuf #intern/moto/include'
28 incs += ' #source/gameengine/Ketsji #source/gameengine/Ketsji/KXNetwork #source/blender/blenlib'
29 incs += ' #source/blender/blenkernel #source/blender #source/blender/include'
30 incs += ' #source/blender/makesdna #source/blender/python #source/gameengine/Rasterizer'
31 incs += ' #source/gameengine/GameLogic #source/gameengine/Expressions #source/gameengine/Network'
32 incs += ' #source/gameengine/SceneGraph #source/gameengine/Physics/common #source/gameengine/Physics/Bullet'
33 incs += ' #source/gameengine/Physics/BlOde #source/gameengine/Physics/Dummy'
34 incs += ' #source/blender/misc #source/blender/blenloader #extern/glew/include #source/blender/gpu'
35
36 if env['WITH_BF_SOLID']:
37         incs += ' #source/gameengine/Physics/Sumo #source/gameengine/Physics/Sumo/include'
38         incs += ' #source/gameengine/Physics/Sumo/Fuzzics/include #source/gameengine/Network/LoopBackNetwork'
39         incs += ' ' + env['BF_SOLID_INC']
40         defs += ' USE_SUMO_SOLID'
41
42
43 incs += ' ' + env['BF_PYTHON_INC']
44 incs += ' ' + env['BF_BULLET_INC']
45 incs += ' ' + env['BF_OPENGL_INC']
46
47 if  env['WITH_BF_SDL']:
48     incs += ' ' + env['BF_SDL_INC']
49 else:
50         defs += ' DISABLE_SDL'
51         
52 cxxflags = []
53 if env['OURPLATFORM']=='win32-vc':
54         cxxflags.append ('/GR')
55         cxxflags.append ('/O2')
56
57 env.BlenderLib ( 'bf_ketsji', sources, Split(incs), Split(defs), libtype=['game','player'], priority=[25, 72], cxx_compileflags = cxxflags )