diff options
Diffstat (limited to 'source/gameengine/GamePlayer')
-rw-r--r-- | source/gameengine/GamePlayer/common/SConscript | 10 | ||||
-rw-r--r-- | source/gameengine/GamePlayer/ghost/GPG_Application.cpp | 3 | ||||
-rw-r--r-- | source/gameengine/GamePlayer/ghost/SConscript | 8 |
3 files changed, 15 insertions, 6 deletions
diff --git a/source/gameengine/GamePlayer/common/SConscript b/source/gameengine/GamePlayer/common/SConscript index dd5a48c2b55..99eda4cb592 100644 --- a/source/gameengine/GamePlayer/common/SConscript +++ b/source/gameengine/GamePlayer/common/SConscript @@ -58,8 +58,14 @@ incs = ['.', # 'unix/GPU_System.cpp'] # gp_common_env.Append ( CPPPATH = ['unix']) -incs += Split(env['BF_PYTHON_INC']) +defs = [] + +if env['WITH_BF_PYTHON']: + incs += ' ' + env['BF_PYTHON_INC'] +else: + defs.append('DISABLE_PYTHON') + incs += Split(env['BF_PNG_INC']) incs += Split(env['BF_ZLIB_INC']) -env.BlenderLib (libname='gp_common', sources=source_files, includes=incs, defines = [], libtype=['player'], priority=[5], cxx_compileflags=env['BGE_CXXFLAGS']) +env.BlenderLib (libname='gp_common', sources=source_files, includes=incs, defines = defs, libtype=['player'], priority=[5], cxx_compileflags=env['BGE_CXXFLAGS']) diff --git a/source/gameengine/GamePlayer/ghost/GPG_Application.cpp b/source/gameengine/GamePlayer/ghost/GPG_Application.cpp index 8ec41968042..3c989293c94 100644 --- a/source/gameengine/GamePlayer/ghost/GPG_Application.cpp +++ b/source/gameengine/GamePlayer/ghost/GPG_Application.cpp @@ -679,7 +679,7 @@ bool GPG_Application::startEngine(void) // some python things PyObject* dictionaryobject = initGamePlayerPythonScripting("Ketsji", psl_Lowest, m_maggie, m_argc, m_argv); - m_ketsjiengine->SetPythonDictionary(dictionaryobject); + m_ketsjiengine->SetPyNamespace(dictionaryobject); initRasterizer(m_rasterizer, m_canvas); PyObject *gameLogic = initGameLogic(m_ketsjiengine, startscene); PyDict_SetItemString(dictionaryobject, "GameLogic", gameLogic); // Same as importing the module @@ -702,7 +702,6 @@ bool GPG_Application::startEngine(void) m_sceneconverter->ConvertScene( startscene, - dictionaryobject, m_rendertools, m_canvas); m_ketsjiengine->AddScene(startscene); diff --git a/source/gameengine/GamePlayer/ghost/SConscript b/source/gameengine/GamePlayer/ghost/SConscript index fdd7792b72a..cfb827cf8c3 100644 --- a/source/gameengine/GamePlayer/ghost/SConscript +++ b/source/gameengine/GamePlayer/ghost/SConscript @@ -40,9 +40,13 @@ incs = ['.', '#source/blender/gpu', '#extern/glew/include'] -incs += Split(env['BF_PYTHON_INC']) - defs = [] + +if env['WITH_BF_PYTHON']: + incs += ' ' + env['BF_PYTHON_INC'] +else: + defs.append('DISABLE_PYTHON') + if env['WITH_BF_FFMPEG']: defs.append('WITH_FFMPEG') |