Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--SConstruct60
-rw-r--r--source/SConscript4
-rwxr-xr-xsource/gameengine/BlenderRoutines/SConscript52
-rwxr-xr-xsource/gameengine/Converter/SConscript69
-rwxr-xr-xsource/gameengine/Expressions/SConscript37
-rwxr-xr-xsource/gameengine/GameLogic/SConscript48
-rwxr-xr-xsource/gameengine/Ketsji/KXNetwork/SConscript29
-rw-r--r--source/gameengine/Ketsji/SConscript111
-rwxr-xr-xsource/gameengine/Network/LoopBackNetwork/SConscript19
-rwxr-xr-xsource/gameengine/Network/SConscript20
-rwxr-xr-xsource/gameengine/Physics/BlOde/SConscript20
-rwxr-xr-xsource/gameengine/Physics/Dummy/SConscript17
-rwxr-xr-xsource/gameengine/Physics/Sumo/SConscript25
-rwxr-xr-xsource/gameengine/Physics/common/SConscript19
-rwxr-xr-xsource/gameengine/Rasterizer/RAS_OpenGLRasterizer/SConscript22
-rwxr-xr-xsource/gameengine/Rasterizer/SConscript27
-rw-r--r--source/gameengine/SConscript22
-rwxr-xr-xsource/gameengine/SceneGraph/SConscript20
18 files changed, 618 insertions, 3 deletions
diff --git a/SConstruct b/SConstruct
index befc7fc9c11..68eb4e51c64 100644
--- a/SConstruct
+++ b/SConstruct
@@ -15,6 +15,8 @@ if sys.platform == 'linux2':
use_openal = 'false'
use_fmod = 'false'
use_quicktime = 'false'
+ use_sumo = 'false'
+ use_ode = 'false'
release_flags = ['-O2']
debug_flags = ['-O2', '-g']
extra_flags = ['-pipe', '-fPIC', '-funsigned-char']
@@ -35,6 +37,8 @@ if sys.platform == 'linux2':
sdl_include = sdl_cdict['CPPPATH'][0]
link_env.Append (LIBS=sdl_ldict['LIBS'])
link_env.Append (LIBPATH=sdl_ldict['LIBPATH'])
+ solid_include = '#extern/solid/include'
+ ode_include = '#extern/ode/dist/include/ode'
# Python variables.
python_include = sysconfig.get_python_inc ()
python_libpath = sysconfig.get_python_lib (0, 1) + '/config'
@@ -55,6 +59,8 @@ elif sys.platform == 'darwin':
use_fmod = 'false'
use_quicktime = 'true'
use_precomp = 'true'
+ use_sumo = 'false'
+ use_ode = 'false'
# TODO: replace darwin-6.8-powerpc with the actual directiory on the
# build machine
darwin_precomp = '#../lib/darwin-6.8-powerpc'
@@ -97,6 +103,8 @@ elif sys.platform == 'cygwin':
use_openal = 'false'
use_fmod = 'false'
use_quicktime = 'false'
+ use_sumo = 'false'
+ use_ode = 'false'
release_flags = ['-O2']
debug_flags = ['-O2', '-g']
extra_flags = ['-pipe', '-mno-cygwin', '-mwindows', '-funsigned-char']
@@ -128,17 +136,19 @@ elif sys.platform == 'cygwin':
elif sys.platform == 'win32':
use_international = 'true'
- use_gameengine = 'false'
+ use_gameengine = 'true'
use_openal = 'true'
use_fmod = 'false'
use_quicktime = 'true'
+ use_sumo = 'false'
+ use_ode = 'true'
release_flags = ['/G6', '/GF']
debug_flags = []
extra_flags = ['/EHsc', '/J', '/W3', '/Gd', '/MT']
cxxflags = []
defines = ['WIN32', 'NDEBUG', '_CONSOLE', 'FTGL_STATIC_LIBRARY']
- defines += ['GAME_BLENDER=0', 'INTERNATIONAL', 'WITH_QUICKTIME']
- defines += ['_LIB', 'WITH_FREETYPE2']
+ defines += ['INTERNATIONAL', 'WITH_QUICKTIME']
+ defines += ['_LIB', 'WITH_FREETYPE2', 'USE_OPENAL']
warn_flags = []
platform_libs = ['SDL', 'freetype2ST', 'ftgl_static_ST', 'gnu_gettext',
'qtmlClient', 'odelib', 'openal_static', 'soundsystem',
@@ -188,7 +198,11 @@ elif sys.platform == 'win32':
extra_includes += ['#../lib/windows/openal/include']
sdl_include = '#../lib/windows/sdl/include'
sdl_cflags = ''
+ source_files += ['source/icons/winblender.res']
+ link_env.RES(['source/icons/winblender.rc'])
window_system = 'WIN32'
+ solid_include = '#../lib/windows/solid/include'
+ ode_include = '#extern/ode/dist/include/ode'
# Python lib name
python_include = '#../lib/windows/python/include/python2.2'
python_libpath = '#../lib/windows/python/lib'
@@ -204,6 +218,8 @@ elif string.find (sys.platform, 'irix') != -1:
use_openal = 'false'
use_fmod = 'false'
use_quicktime = 'false'
+ use_sumo = 'false'
+ use_ode = 'false'
irix_precomp = '#../lib/irix-6.5-mips'
extra_flags = ['-n32', '-mips3', '-Xcpluscomm']
cxxflags = ['-n32', '-mips3', '-Xcpluscomm', '-LANG:std']
@@ -244,6 +260,22 @@ else:
#-----------------------------------------------------------------------------
# End of platform specific section
#-----------------------------------------------------------------------------
+
+#-----------------------------------------------------------------------------
+# Game Engine settings
+#-----------------------------------------------------------------------------
+if use_gameengine == 'true':
+ defines += ['GAMEBLENDER=1']
+ if use_sumo == 'true':
+ defines += ['USE_SUMO_SOLID']
+ if use_ode == 'true':
+ defines += ['USE_ODE']
+else:
+ defines += ['GAMEBLENDER=0']
+
+#-----------------------------------------------------------------------------
+# Settings to be exported to other SConscript files
+#-----------------------------------------------------------------------------
cflags = extra_flags + release_flags + warn_flags
Export ('use_international')
@@ -251,6 +283,8 @@ Export ('use_gameengine')
Export ('use_openal')
Export ('use_fmod')
Export ('use_quicktime')
+Export ('use_ode')
+Export ('use_sumo')
Export ('python_include')
Export ('cflags')
Export ('defines')
@@ -258,6 +292,8 @@ Export ('cxxflags')
Export ('window_system')
Export ('sdl_cflags')
Export ('sdl_include')
+Export ('solid_include')
+Export ('ode_include')
Export ('extra_includes')
Export ('platform_libs')
Export ('platform_libpath')
@@ -309,6 +345,24 @@ if use_international == 'true':
link_env.Append (LIBS=['blender_FTF'])
if use_quicktime == 'true':
link_env.Append (LIBS=['blender_quicktime'])
+if use_gameengine == 'true':
+ link_env.Append (LIBS=['blender_expressions',
+ 'KX_blenderhook',
+ 'KX_converter',
+ 'KX_ketsji',
+ 'KX_network',
+ 'NG_loopbacknetwork',
+ 'NG_network',
+ 'PHY_Physics',
+ 'PHY_Dummy',
+ 'SCA_GameLogic',
+ 'RAS_rasterizer',
+ 'RAS_OpenGLRasterizer',
+ 'SG_SceneGraph'])
+ if use_sumo == 'true':
+ link_env.Append (LIBS=['PHY_Sumo'])
+ if use_ode == 'true':
+ link_env.Append (LIBS=['PHY_Ode'])
link_env.Append (LIBS=python_lib)
link_env.Append (LIBPATH=python_libpath)
diff --git a/source/SConscript b/source/SConscript
index 386881cfe1c..188c7c30051 100644
--- a/source/SConscript
+++ b/source/SConscript
@@ -1,2 +1,6 @@
+Import ('use_gameengine')
+
SConscript(['blender/SConscript',
'kernel/SConscript'])
+if use_gameengine == 'true':
+ SConscript (['gameengine/SConscript'])
diff --git a/source/gameengine/BlenderRoutines/SConscript b/source/gameengine/BlenderRoutines/SConscript
new file mode 100755
index 00000000000..2116f9fec3b
--- /dev/null
+++ b/source/gameengine/BlenderRoutines/SConscript
@@ -0,0 +1,52 @@
+kx_blenderhook_env = Environment()
+
+# Import the C flags set in the SConstruct file
+Import ('cflags')
+Import ('cxxflags')
+Import ('defines')
+Import ('python_include')
+kx_blenderhook_env.Append (CCFLAGS = cflags)
+kx_blenderhook_env.Append (CXXFLAGS = cxxflags)
+kx_blenderhook_env.Append (CPPDEFINES = defines)
+
+source_files = ['KX_BlenderSystem.cpp',
+ 'KX_BlenderRenderTools.cpp',
+ 'KX_BlenderPolyMaterial.cpp',
+ 'KX_BlenderMouseDevice.cpp',
+ 'KX_BlenderKeyboardDevice.cpp',
+ 'KX_BlenderInputDevice.cpp',
+ 'KX_BlenderGL.cpp',
+ 'KX_BlenderCanvas.cpp',
+ 'BL_KetsjiEmbedStart.cpp']
+
+kx_blenderhook_env.Append (CPPPATH=['.',
+ '#source/kernel/gen_system',
+ '#intern/string',
+ '#intern/guardedalloc',
+ '#source/gameengine/Rasterizer/RAS_OpenGLRasterizer',
+ python_include,
+ '#intern/bmfont',
+ '#source/gameengine/Converter',
+ '#source/blender/imbuf',
+ '#intern/moto/include',
+ '#source/gameengine/Ketsji',
+ '#source/blender/blenlib',
+ '#source/blender/blenkernel',
+ '#source/blender',
+ '#source/blender/include',
+ '#source/blender/makesdna',
+ '#source/gameengine/Rasterizer',
+ '#source/gameengine/GameLogic',
+ '#source/gameengine/Expressions',
+ '#source/gameengine/Network',
+ '#source/gameengine/SceneGraph',
+ '#source/gameengine/Physics/Sumo/include',
+ '#source/gameengine/Physics/Sumo/Fuzzics/include',
+ '#source/gameengine/Network/LoopBackNetwork',
+ '#intern/SoundSystem',
+ '#source/blender/misc',
+ '#source/blender/blenloader',
+ '#../lib/windows/solid/include',
+ ])
+
+kx_blenderhook_env.Library (target='#/lib/KX_blenderhook', source=source_files)
diff --git a/source/gameengine/Converter/SConscript b/source/gameengine/Converter/SConscript
new file mode 100755
index 00000000000..9567844c8dd
--- /dev/null
+++ b/source/gameengine/Converter/SConscript
@@ -0,0 +1,69 @@
+kx_converter_env = Environment()
+
+# Import the C flags set in the SConstruct file
+Import ('cflags')
+Import ('cxxflags')
+Import ('defines')
+Import ('solid_include')
+Import ('python_include')
+kx_converter_env.Append (CCFLAGS = cflags)
+kx_converter_env.Append (CXXFLAGS = cxxflags)
+kx_converter_env.Append (CPPDEFINES = defines)
+
+source_files = ['KX_IpoConvert.cpp',
+ 'KX_ConvertSensors.cpp',
+ 'KX_ConvertProperties.cpp',
+ 'KX_ConvertControllers.cpp',
+ 'KX_ConvertActuators.cpp',
+ 'KX_BlenderSceneConverter.cpp',
+ 'KX_BlenderScalarInterpolator.cpp',
+ 'BlenderWorldInfo.cpp',
+ 'BL_SkinMeshObject.cpp',
+ 'BL_SkinDeformer.cpp',
+ 'BL_MeshDeformer.cpp',
+ 'BL_DeformableGameObject.cpp',
+ 'BL_BlenderDataConversion.cpp',
+ 'BL_ArmatureObject.cpp',
+ 'BL_ActionActuator.cpp'
+ ]
+
+kx_converter_env.Append (CPPPATH = ['.',
+ '#source/kernel/gen_system',
+ '#intern/string',
+ '#intern/guardedalloc',
+ '#source/gameengine/Rasterizer/RAS_OpenGLRasterizer',
+ python_include,
+ '#intern/bmfont',
+ '#intern/SoundSystem',
+ '#intern/SoundSystem/include',
+ '#intern/SoundSystem/openal',
+ '#intern/SoundSystem/dummy',
+ '#intern/SoundSystem/intern',
+ '#source/gameengine/Converter',
+ '#source/gameengine/BlenderRoutines',
+ '#source/blender/imbuf',
+ '#intern/moto/include',
+ '#source/gameengine/Ketsji',
+ '#source/gameengine/Ketsji/KXNetwork',
+ '#source/blender/blenlib',
+ '#source/blender/blenkernel',
+ '#source/blender',
+ '#source/blender/include',
+ '#source/blender/makesdna',
+ '#source/gameengine/Rasterizer',
+ '#source/gameengine/GameLogic',
+ '#source/gameengine/Expressions',
+ '#source/gameengine/Network',
+ '#source/gameengine/SceneGraph',
+ '#source/gameengine/Physics/common',
+ '#source/gameengine/Physics/BlOde',
+ '#source/gameengine/Physics/Dummy',
+ '#source/gameengine/Physics/Sumo/include',
+ '#source/gameengine/Physics/Sumo/Fuzzics/include',
+ '#source/gameengine/Network/LoopBackNetwork',
+ '#source/blender/misc',
+ '#source/blender/blenloader',
+ solid_include
+ ])
+
+kx_converter_env.Library (target='#/lib/KX_converter', source=source_files)
diff --git a/source/gameengine/Expressions/SConscript b/source/gameengine/Expressions/SConscript
new file mode 100755
index 00000000000..c750bcd3e1a
--- /dev/null
+++ b/source/gameengine/Expressions/SConscript
@@ -0,0 +1,37 @@
+expressions_env = Environment()
+
+# Import the C flags set in the SConstruct file
+Import ('cflags')
+Import ('cxxflags')
+Import ('defines')
+Import ('python_include')
+expressions_env.Append (CCFLAGS = cflags)
+expressions_env.Append (CXXFLAGS = cxxflags)
+expressions_env.Append (CPPDEFINES = defines)
+
+source_files = ['BoolValue.cpp',
+ 'ConstExpr.cpp',
+ 'EmptyValue.cpp',
+ 'ErrorValue.cpp',
+ 'EXP_C-Api.cpp',
+ 'Expression.cpp',
+ 'FloatValue.cpp',
+ 'IdentifierExpr.cpp',
+ 'IfExpr.cpp',
+ 'InputParser.cpp',
+ 'IntValue.cpp',
+ 'KX_HashedPtr.cpp',
+ 'ListValue.cpp',
+ 'Operator1Expr.cpp',
+ 'Operator2Expr.cpp',
+ 'PyObjectPlus.cpp',
+ 'StringValue.cpp',
+ 'Value.cpp',
+ 'VectorValue.cpp']
+
+expressions_env.Append (CPPPATH = ['.',
+ '#source/kernel/gen_system',
+ '#intern/string',
+ python_include])
+
+expressions_env.Library (target='#/lib/blender_expressions', source=source_files)
diff --git a/source/gameengine/GameLogic/SConscript b/source/gameengine/GameLogic/SConscript
new file mode 100755
index 00000000000..c61b708ec43
--- /dev/null
+++ b/source/gameengine/GameLogic/SConscript
@@ -0,0 +1,48 @@
+sca_gamelogic_env = Environment()
+
+# Import the C flags set in the SConstruct file
+Import ('cflags')
+Import ('cxxflags')
+Import ('defines')
+Import ('python_include')
+sca_gamelogic_env.Append (CCFLAGS = cflags)
+sca_gamelogic_env.Append (CXXFLAGS = cxxflags)
+sca_gamelogic_env.Append (CPPDEFINES = defines)
+
+source_files = ['SCA_ANDController.cpp',
+ 'SCA_AlwaysEventManager.cpp',
+ 'SCA_AlwaysSensor.cpp',
+ 'SCA_EventManager.cpp',
+ 'SCA_ExpressionController.cpp',
+ 'SCA_IActuator.cpp',
+ 'SCA_IController.cpp',
+ 'SCA_IInputDevice.cpp',
+ 'SCA_ILogicBrick.cpp',
+ 'SCA_IObject.cpp',
+ 'SCA_IScene.cpp',
+ 'SCA_ISensor.cpp',
+ 'SCA_KeyboardManager.cpp',
+ 'SCA_KeyboardSensor.cpp',
+ 'SCA_LogicManager.cpp',
+ 'SCA_MouseManager.cpp',
+ 'SCA_MouseSensor.cpp',
+ 'SCA_ORController.cpp',
+ 'SCA_PropertyActuator.cpp',
+ 'SCA_PropertyEventManager.cpp',
+ 'SCA_PropertySensor.cpp',
+ 'SCA_PythonController.cpp',
+ 'SCA_RandomActuator.cpp',
+ 'SCA_RandomEventManager.cpp',
+ 'SCA_RandomNumberGenerator.cpp',
+ 'SCA_RandomSensor.cpp',
+ 'SCA_TimeEventManager.cpp']
+
+sca_gamelogic_env.Append (CPPPATH=['.',
+ '#/source/kernel/gen_system',
+ '#/intern/string',
+ '#/source/gameengine/Expressions',
+ '#/intern/moto/include',
+ python_include,
+ ])
+
+sca_gamelogic_env.Library (target='#/lib/SCA_GameLogic', source=source_files)
diff --git a/source/gameengine/Ketsji/KXNetwork/SConscript b/source/gameengine/Ketsji/KXNetwork/SConscript
new file mode 100755
index 00000000000..61e31bb0f66
--- /dev/null
+++ b/source/gameengine/Ketsji/KXNetwork/SConscript
@@ -0,0 +1,29 @@
+kx_network_env = Environment()
+
+# Import the C flags set in the SConstruct file
+Import ('cflags')
+Import ('cxxflags')
+Import ('defines')
+Import ('python_include')
+kx_network_env.Append (CCFLAGS = cflags)
+kx_network_env.Append (CXXFLAGS = cxxflags)
+kx_network_env.Append (CPPDEFINES = defines)
+
+source_files = ['KX_NetworkEventManager.cpp',
+ 'KX_NetworkMessageActuator.cpp',
+ 'KX_NetworkMessageSensor.cpp',
+ 'KX_NetworkObjectActuator.cpp',
+ 'KX_NetworkObjectSensor.cpp'
+ ]
+
+kx_network_env.Append (CPPPATH = ['.',
+ '#source/kernel/gen_system',
+ '#intern/string',
+ python_include,
+ '#source/gameengine/Ketsji',
+ '#source/gameengine/GameLogic',
+ '#source/gameengine/Expressions',
+ '#source/gameengine/Network',
+ ])
+
+kx_network_env.Library (target='#/lib/KX_network', source=source_files)
diff --git a/source/gameengine/Ketsji/SConscript b/source/gameengine/Ketsji/SConscript
new file mode 100644
index 00000000000..75eff210137
--- /dev/null
+++ b/source/gameengine/Ketsji/SConscript
@@ -0,0 +1,111 @@
+ketsji_env = Environment()
+
+# Import the C flags set in the SConstruct file
+Import ('cflags')
+Import ('cxxflags')
+Import ('defines')
+Import ('use_sumo')
+Import ('use_ode')
+Import ('python_include')
+Import ('solid_include')
+ketsji_env.Append (CCFLAGS = cflags)
+ketsji_env.Append (CXXFLAGS = cxxflags)
+ketsji_env.Append (CPPDEFINES = defines)
+
+source_files = ['KX_WorldIpoController.cpp',
+ 'KX_WorldInfo.cpp',
+ 'KX_VisibilityActuator.cpp',
+ 'KX_VertexProxy.cpp',
+ 'KX_TrackToActuator.cpp',
+ 'KX_TouchSensor.cpp',
+ 'KX_TouchEventManager.cpp',
+ 'KX_TimeLogger.cpp',
+ 'KX_TimeCategoryLogger.cpp',
+ 'KX_SoundActuator.cpp',
+ 'KX_SG_NodeRelationships.cpp',
+ 'KX_SceneActuator.cpp',
+ 'KX_Scene.cpp',
+ 'KX_ScalingInterpolator.cpp',
+ 'KX_ScalarInterpolator.cpp',
+ 'KX_SCA_ReplaceMeshActuator.cpp',
+ 'KX_SCA_EndObjectActuator.cpp',
+ 'KX_SCA_AddObjectActuator.cpp',
+ 'KX_RaySensor.cpp',
+ 'KX_RayEventManager.cpp',
+ 'KX_RadarSensor.cpp',
+ 'KX_PythonInit.cpp',
+ 'KX_PyConstraintBinding.cpp',
+ 'KX_PositionInterpolator.cpp',
+ 'KX_PhysicsObjectWrapper.cpp',
+ 'KX_OrientationInterpolator.cpp',
+ 'KX_ObjectActuator.cpp',
+ 'KX_ObColorIpoSGController.cpp',
+ 'KX_NearSensor.cpp',
+ 'KX_MouseFocusSensor.cpp',
+ 'KX_MotionState.cpp',
+ 'KX_MeshProxy.cpp',
+ 'KX_LightIpoSGController.cpp',
+ 'KX_Light.cpp',
+ 'KX_KetsjiEngine.cpp',
+ 'KX_IpoActuator.cpp',
+ 'KX_IPO_SGController.cpp',
+ 'KX_IPhysicsController.cpp',
+ 'KX_GameObject.cpp',
+ 'KX_GameActuator.cpp',
+ 'KX_EmptyObject.cpp',
+ 'KX_ConvertPhysicsObjects.cpp',
+ 'KX_ConstraintWrapper.cpp',
+ 'KX_ConstraintActuator.cpp',
+ 'KX_CDActuator.cpp',
+ 'KX_CameraIpoSGController.cpp',
+ 'KX_CameraActuator.cpp',
+ 'KX_Camera.cpp'
+ ]
+
+if use_sumo == 'true':
+ source_files += ['KX_SumoPhysicsController.cpp']
+ ketsji_env.Append (CPPPATH = [solid_include])
+
+if use_ode == 'true':
+ source_files += ['KX_OdePhysicsController.cpp']
+
+ketsji_env.Append (CPPPATH = ['.',
+ '#source/kernel/gen_system',
+ '#intern/string',
+ '#intern/guardedalloc',
+ '#source/gameengine/Rasterizer/RAS_OpenGLRasterizer',
+ '#intern/bmfont',
+ '#intern/SoundSystem',
+ '#intern/SoundSystem/include',
+ '#intern/SoundSystem/openal',
+ '#intern/SoundSystem/dummy',
+ '#intern/SoundSystem/intern',
+ '#source/gameengine/Converter',
+ '#source/gameengine/BlenderRoutines',
+ '#source/blender/imbuf',
+ '#intern/moto/include',
+ '#source/gameengine/Ketsji',
+ '#source/gameengine/Ketsji/KXNetwork',
+ '#source/blender/blenlib',
+ '#source/blender/blenkernel',
+ '#source/blender',
+ '#source/blender/include',
+ '#source/blender/makesdna',
+ '#source/gameengine/Rasterizer',
+ '#source/gameengine/GameLogic',
+ '#source/gameengine/Expressions',
+ '#source/gameengine/Network',
+ '#source/gameengine/SceneGraph',
+ '#source/gameengine/Physics/common',
+ '#source/gameengine/Physics/BlOde',
+ '#source/gameengine/Physics/Dummy',
+ '#source/gameengine/Physics/Sumo/',
+ '#source/gameengine/Physics/Sumo/include',
+ '#source/gameengine/Physics/Sumo/Fuzzics/include',
+ '#source/gameengine/Network/LoopBackNetwork',
+ '#source/blender/misc',
+ '#source/blender/blenloader',
+ python_include
+ ])
+
+ketsji_env.Library (target='#/lib/KX_ketsji', source=source_files)
diff --git a/source/gameengine/Network/LoopBackNetwork/SConscript b/source/gameengine/Network/LoopBackNetwork/SConscript
new file mode 100755
index 00000000000..a6cd3c435fa
--- /dev/null
+++ b/source/gameengine/Network/LoopBackNetwork/SConscript
@@ -0,0 +1,19 @@
+ng_loopbacknetwork_env = Environment()
+
+# Import the C flags set in the SConstruct file
+Import ('cflags')
+Import ('cxxflags')
+Import ('defines')
+ng_loopbacknetwork_env.Append (CCFLAGS = cflags)
+ng_loopbacknetwork_env.Append (CXXFLAGS = cxxflags)
+ng_loopbacknetwork_env.Append (CPPDEFINES = defines)
+
+source_files = ['NG_LoopBackNetworkDeviceInterface.cpp']
+
+ng_loopbacknetwork_env.Append (CPPPATH=['.',
+ '#source/kernel/gen_system',
+ '#intern/string',
+ '#source/gameengine/Network',
+ ])
+
+ng_loopbacknetwork_env.Library (target='#/lib/NG_loopbacknetwork', source=source_files)
diff --git a/source/gameengine/Network/SConscript b/source/gameengine/Network/SConscript
new file mode 100755
index 00000000000..443803f9ce3
--- /dev/null
+++ b/source/gameengine/Network/SConscript
@@ -0,0 +1,20 @@
+ng_network_env = Environment()
+
+# Import the C flags set in the SConstruct file
+Import ('cflags')
+Import ('cxxflags')
+Import ('defines')
+ng_network_env.Append (CCFLAGS = cflags)
+ng_network_env.Append (CXXFLAGS = cxxflags)
+ng_network_env.Append (CPPDEFINES = defines)
+
+source_files = ['NG_NetworkMessage.cpp',
+ 'NG_NetworkObject.cpp',
+ 'NG_NetworkScene.cpp']
+
+ng_network_env.Append (CPPPATH=['.',
+ '#source/kernel/gen_system',
+ '#intern/string'
+ ])
+
+ng_network_env.Library (target='#/lib/NG_network', source=source_files)
diff --git a/source/gameengine/Physics/BlOde/SConscript b/source/gameengine/Physics/BlOde/SConscript
new file mode 100755
index 00000000000..43ddbd31c06
--- /dev/null
+++ b/source/gameengine/Physics/BlOde/SConscript
@@ -0,0 +1,20 @@
+phy_ode_env = Environment()
+
+# Import the C flags set in the SConstruct file
+Import ('cflags')
+Import ('cxxflags')
+Import ('defines')
+Import ('ode_include')
+phy_ode_env.Append (CCFLAGS = cflags)
+phy_ode_env.Append (CXXFLAGS = cxxflags)
+phy_ode_env.Append (CPPDEFINES = defines)
+
+source_files = ['OdePhysicsController.cpp',
+ 'OdePhysicsEnvironment.cpp']
+
+phy_ode_env.Append (CPPPATH=['.',
+ '../common',
+ ode_include
+ ])
+
+phy_ode_env.Library (target='#/lib/PHY_Ode', source=source_files)
diff --git a/source/gameengine/Physics/Dummy/SConscript b/source/gameengine/Physics/Dummy/SConscript
new file mode 100755
index 00000000000..746c16bb9f3
--- /dev/null
+++ b/source/gameengine/Physics/Dummy/SConscript
@@ -0,0 +1,17 @@
+phy_dummy_env = Environment()
+
+# Import the C flags set in the SConstruct file
+Import ('cflags')
+Import ('cxxflags')
+Import ('defines')
+phy_dummy_env.Append (CCFLAGS = cflags)
+phy_dummy_env.Append (CXXFLAGS = cxxflags)
+phy_dummy_env.Append (CPPDEFINES = defines)
+
+source_files = ['DummyPhysicsEnvironment.cpp']
+
+phy_dummy_env.Append (CPPPATH = ['.',
+ '../common'
+ ])
+
+phy_dummy_env.Library (target='#/lib/PHY_Dummy', source=source_files)
diff --git a/source/gameengine/Physics/Sumo/SConscript b/source/gameengine/Physics/Sumo/SConscript
new file mode 100755
index 00000000000..a59e66cd850
--- /dev/null
+++ b/source/gameengine/Physics/Sumo/SConscript
@@ -0,0 +1,25 @@
+phy_sumo_env = Environment()
+
+# Import the C flags set in the SConstruct file
+Import ('cflags')
+Import ('cxxflags')
+Import ('defines')
+Import ('solid_include')
+phy_sumo_env.Append (CCFLAGS = cflags)
+phy_sumo_env.Append (CXXFLAGS = cxxflags)
+phy_sumo_env.Append (CPPDEFINES = defines)
+
+source_files = ['SumoPhysicsController.cpp',
+ 'SumoPhysicsEnvironment.cpp',
+ 'Fuzzics/src/SM_FhObject.cpp',
+ 'Fuzzics/src/SM_Object.cpp',
+ 'Fuzzics/src/SM_Scene.cpp']
+
+phy_sumo_env.Append (CPPPATH = ['.',
+ '../common',
+ 'Fuzzics/include',
+ solid_include,
+ '#/intern/moto/include'
+ ])
+
+phy_sumo_env.Library (target='#/lib/PHY_Sumo', source=source_files)
diff --git a/source/gameengine/Physics/common/SConscript b/source/gameengine/Physics/common/SConscript
new file mode 100755
index 00000000000..81cc93fa3c1
--- /dev/null
+++ b/source/gameengine/Physics/common/SConscript
@@ -0,0 +1,19 @@
+phy_physics_env = Environment()
+
+# Import the C flags set in the SConstruct file
+Import ('cflags')
+Import ('cxxflags')
+Import ('defines')
+phy_physics_env.Append (CCFLAGS = cflags)
+phy_physics_env.Append (CXXFLAGS = cxxflags)
+phy_physics_env.Append (CPPDEFINES = defines)
+
+source_files = ['PHY_IMotionState.cpp',
+ 'PHY_IPhysicsController.cpp',
+ 'PHY_IPhysicsEnvironment.cpp']
+
+phy_physics_env.Append (CPPPATH = ['.',
+ '../Dummy'
+ ])
+
+phy_physics_env.Library (target='#/lib/PHY_Physics', source=source_files)
diff --git a/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/SConscript b/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/SConscript
new file mode 100755
index 00000000000..d1dd79b55e8
--- /dev/null
+++ b/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/SConscript
@@ -0,0 +1,22 @@
+ras_openglrasterizer_env = Environment()
+
+# Import the C flags set in the SConstruct file
+Import ('cflags')
+Import ('cxxflags')
+Import ('defines')
+ras_openglrasterizer_env.Append (CCFLAGS = cflags)
+ras_openglrasterizer_env.Append (CXXFLAGS = cxxflags)
+ras_openglrasterizer_env.Append (CPPDEFINES = defines)
+
+source_files = ['RAS_CheckVertexArrays.cpp',
+ 'RAS_OpenGLRasterizer.cpp',
+ 'RAS_VAOpenGLRasterizer.cpp']
+
+ras_openglrasterizer_env.Append (CPPPATH=['.',
+ '#source/kernel/gen_system',
+ '#intern/string',
+ '#intern/moto/include',
+ '#source/gameengine/Rasterizer'
+ ])
+
+ras_openglrasterizer_env.Library (target='#/lib/RAS_OpenGLRasterizer', source=source_files)
diff --git a/source/gameengine/Rasterizer/SConscript b/source/gameengine/Rasterizer/SConscript
new file mode 100755
index 00000000000..5d8b31d53ec
--- /dev/null
+++ b/source/gameengine/Rasterizer/SConscript
@@ -0,0 +1,27 @@
+ras_rasterizer_env = Environment()
+
+# Import the C flags set in the SConstruct file
+Import ('cflags')
+Import ('cxxflags')
+Import ('defines')
+ras_rasterizer_env.Append (CCFLAGS = cflags)
+ras_rasterizer_env.Append (CXXFLAGS = cxxflags)
+ras_rasterizer_env.Append (CPPDEFINES = defines)
+
+source_files = ['RAS_BucketManager.cpp',
+ 'RAS_FramingManager.cpp',
+ 'RAS_IPolygonMaterial.cpp',
+ 'RAS_IRenderTools.cpp',
+ 'RAS_MaterialBucket.cpp',
+ 'RAS_MeshObject.cpp',
+ 'RAS_Polygon.cpp',
+ 'RAS_TexVert.cpp',
+ 'RAS_texmatrix.cpp']
+
+ras_rasterizer_env.Append (CPPPATH=['.',
+ '#source/kernel/gen_system',
+ '#intern/string',
+ '#intern/moto/include'
+ ])
+
+ras_rasterizer_env.Library (target='#/lib/RAS_rasterizer', source=source_files)
diff --git a/source/gameengine/SConscript b/source/gameengine/SConscript
new file mode 100644
index 00000000000..9ae0df1a8aa
--- /dev/null
+++ b/source/gameengine/SConscript
@@ -0,0 +1,22 @@
+Import ('use_ode')
+Import ('use_sumo')
+
+SConscript(['Ketsji/SConscript',
+ 'Ketsji/KXNetwork/SConscript',
+ 'Expressions/SConscript',
+ 'BlenderRoutines/SConscript',
+ 'Converter/SConscript',
+ 'Network/SConscript',
+ 'Network/LoopBackNetwork/SConscript',
+ 'GameLogic/SConscript',
+ 'Physics/common/SConscript',
+ 'Physics/Dummy/SConscript',
+ 'Rasterizer/SConscript',
+ 'Rasterizer/RAS_OpenGLRasterizer/SConscript',
+ 'SceneGraph/SConscript'])
+
+if use_sumo == 'true':
+ SConscript(['Physics/Sumo/SConscript'])
+
+if use_ode == 'true':
+ SConscript(['Physics/BlOde/SConscript'])
diff --git a/source/gameengine/SceneGraph/SConscript b/source/gameengine/SceneGraph/SConscript
new file mode 100755
index 00000000000..6f51bef7989
--- /dev/null
+++ b/source/gameengine/SceneGraph/SConscript
@@ -0,0 +1,20 @@
+sg_scenegraph_env = Environment()
+
+# Import the C flags set in the SConstruct file
+Import ('cflags')
+Import ('cxxflags')
+Import ('defines')
+sg_scenegraph_env.Append (CCFLAGS = cflags)
+sg_scenegraph_env.Append (CXXFLAGS = cxxflags)
+sg_scenegraph_env.Append (CPPDEFINES = defines)
+
+source_files = ['SG_Controller.cpp',
+ 'SG_IObject.cpp',
+ 'SG_Node.cpp',
+ 'SG_Spatial.cpp']
+
+sg_scenegraph_env.Append (CPPPATH=['.',
+ '#intern/moto/include'
+ ])
+
+sg_scenegraph_env.Library (target='#/lib/SG_SceneGraph', source=source_files)