diff options
Diffstat (limited to 'o3d/plugin')
-rw-r--r-- | o3d/plugin/plugin.gyp | 44 | ||||
-rw-r--r-- | o3d/plugin/win/main_win.cc | 2 |
2 files changed, 30 insertions, 16 deletions
diff --git a/o3d/plugin/plugin.gyp b/o3d/plugin/plugin.gyp index bf4fcc4..688509a 100644 --- a/o3d/plugin/plugin.gyp +++ b/o3d/plugin/plugin.gyp @@ -21,11 +21,10 @@ 'O3D_PLUGIN_MIME_TYPE="<!(python version_info.py --mimetype)"', ], }, - 'targets': [ { 'target_name': 'npo3dautoplugin', - 'type': 'shared_library', + 'type': '<(o3d_main_lib_type)', 'dependencies': [ '../../<(jpegdir)/libjpeg.gyp:libjpeg', '../../<(pngdir)/libpng.gyp:libpng', @@ -103,25 +102,21 @@ 'win/update_lock.cc', 'win/update_lock.h', ], - 'msvs_settings': { - 'VCLinkerTool': { - 'AdditionalDependencies': [ - 'rpcrt4.lib', - ], - }, + 'link_settings': { + 'libraries': [ + '-lrpcrt4.lib', + ], }, }, ], ['OS == "win" and renderer == "d3d9"', { - 'msvs_settings': { - 'VCLinkerTool': { - 'AdditionalDependencies': [ - '"$(DXSDK_DIR)/Lib/x86/DxErr9.lib"', - '"$(DXSDK_DIR)/Lib/x86/d3dx9.lib"', - 'd3d9.lib', - ], - }, + 'link_settings': { + 'libraries': [ + '-l"$(DXSDK_DIR)/Lib/x86/DxErr9.lib"', + '-l"$(DXSDK_DIR)/Lib/x86/d3dx9.lib"', + '-ld3d9.lib', + ], }, }, ], @@ -129,6 +124,23 @@ }, ], 'conditions': [ + ['o3d_in_chrome != 0', + { + 'variables': { + 'o3d_main_lib_type': 'static_library', + }, + 'target_defaults': { + 'defines': [ + 'O3D_INTERNAL_PLUGIN=1', + ], + }, + }, + { + 'variables': { + 'o3d_main_lib_type': 'shared_library', + }, + }, + ], ['OS != "linux"', { 'targets': [ diff --git a/o3d/plugin/win/main_win.cc b/o3d/plugin/win/main_win.cc index d2727d7..84347a02 100644 --- a/o3d/plugin/win/main_win.cc +++ b/o3d/plugin/win/main_win.cc @@ -553,9 +553,11 @@ LRESULT CALLBACK WindowProc(HWND hWnd, UINT Msg, WPARAM wParam, LPARAM lParam) { break; // Ignore this message; we're reentrant. } +#if !defined(O3D_INTERNAL_PLUGIN) // TODO: Only logging for windows until we figure out the proper // mac way if (g_logger) g_logger->UpdateLogging(); +#endif // If rendering continuously, invalidate the window and force a paint if // it is visible. The paint invalidates the renderer and Tick will later |