diff options
-rw-r--r-- | o3d/breakpad/breakpad.gyp | 6 | ||||
-rw-r--r-- | o3d/breakpad/win/exception_handler_win32.cc | 6 | ||||
-rw-r--r-- | o3d/installer/installer.gyp | 45 | ||||
-rw-r--r-- | o3d/plugin/branding.gypi | 22 | ||||
-rw-r--r-- | o3d/plugin/cross/main.cc | 2 | ||||
-rw-r--r-- | o3d/plugin/mac/Info.plist | 2 | ||||
-rw-r--r-- | o3d/plugin/mac/o3d_plugin.r | 2 | ||||
-rw-r--r-- | o3d/plugin/npapi_host_control/win/host_control.rgs | 42 | ||||
-rw-r--r-- | o3d/plugin/npapi_host_control/win/host_control.rgs_template | 42 | ||||
-rw-r--r-- | o3d/plugin/npapi_host_control/win/np_plugin_proxy.cc | 9 | ||||
-rw-r--r-- | o3d/plugin/npapi_host_control/win/npapi_host_control.idl_template (renamed from o3d/plugin/npapi_host_control/win/npapi_host_control.idl) | 4 | ||||
-rw-r--r-- | o3d/plugin/plugin.gyp | 121 | ||||
-rw-r--r-- | o3d/plugin/version_info.py | 37 | ||||
-rw-r--r-- | o3d/plugin/win/config.cc | 6 | ||||
-rw-r--r-- | o3d/plugin/win/o3dPlugin.def_template (renamed from o3d/plugin/win/o3dPlugin.def) | 2 | ||||
-rw-r--r-- | o3d/plugin/win/o3dPlugin.rc_template | 10 |
16 files changed, 265 insertions, 93 deletions
diff --git a/o3d/breakpad/breakpad.gyp b/o3d/breakpad/breakpad.gyp index 512501f..68e64ae 100644 --- a/o3d/breakpad/breakpad.gyp +++ b/o3d/breakpad/breakpad.gyp @@ -8,6 +8,7 @@ }, 'includes': [ '../build/common.gypi', + '../plugin/branding.gypi', ], 'target_defaults': { 'include_dirs': [ @@ -15,6 +16,11 @@ '../..', '../../breakpad/src', ], + 'defines': [ + 'O3D_PLUGIN_INSTALLDIR_CSIDL=<(plugin_installdir_csidl)', + 'O3D_PLUGIN_VENDOR_DIRECTORY="<(plugin_vendor_directory)"', + 'O3D_PLUGIN_PRODUCT_DIRECTORY="<(plugin_product_directory)"', + ], }, 'conditions': [ ['OS=="mac"', diff --git a/o3d/breakpad/win/exception_handler_win32.cc b/o3d/breakpad/win/exception_handler_win32.cc index 96851f0..70a2607 100644 --- a/o3d/breakpad/win/exception_handler_win32.cc +++ b/o3d/breakpad/win/exception_handler_win32.cc @@ -148,13 +148,15 @@ static bool MinidumpCallback(const wchar_t *minidump_folder, HRESULT result = SHGetFolderPath( NULL, - CSIDL_APPDATA, + O3D_PLUGIN_INSTALLDIR_CSIDL, NULL, 0, reporterPath); if (result == 0) { - PathAppend(reporterPath, _T("Google\\O3D\\reporter.exe")); + PathAppend(reporterPath, + _T(O3D_PLUGIN_VENDOR_DIRECTORY) _T("\\") + _T(O3D_PLUGIN_PRODUCT_DIRECTORY) _T("\\reporter.exe")); } if (PathFileExists(reporterPath)) { diff --git a/o3d/installer/installer.gyp b/o3d/installer/installer.gyp index afbd0fd..4361d65 100644 --- a/o3d/installer/installer.gyp +++ b/o3d/installer/installer.gyp @@ -8,33 +8,44 @@ }, 'includes': [ '../build/common.gypi', + '../plugin/branding.gypi', ], 'targets': [ { 'target_name': 'installer', 'type': 'none', 'conditions': [ - ['OS=="win"', + # We suppress building the installers for third parties using custom + # branding, because they contain a lot of hard-coded logic that assumes + # the official branding. A rebranded build must instead be shipped + # as part of some third-party's own installer. + ['<(plugin_rebranded) == 0', { - 'dependencies': [ - 'win/installer.gyp:installer', - 'win/installer.gyp:extras_installer', + 'conditions': [ + ['OS=="win"', + { + 'dependencies': [ + 'win/installer.gyp:installer', + 'win/installer.gyp:extras_installer', + ], + }, ], - }, - ], - ['OS=="mac"', - { - 'dependencies': [ - 'mac/installer.gyp:disk_image', + ['OS=="mac"', + { + 'dependencies': [ + 'mac/installer.gyp:disk_image', + ], + }, ], - }, - ], - ['OS=="linux"', - { - 'dependencies': [ - 'linux/installer.gyp:installer', + ['OS=="linux"', + { + 'dependencies': [ + 'linux/installer.gyp:installer', + ], + }, ], - }, + ], + } ], ], }, diff --git a/o3d/plugin/branding.gypi b/o3d/plugin/branding.gypi new file mode 100644 index 0000000..93335c8 --- /dev/null +++ b/o3d/plugin/branding.gypi @@ -0,0 +1,22 @@ +# Copyright (c) 2010 The Chromium Authors. All rights reserved. +# Use of this source code is governed by a BSD-style license that can be +# found in the LICENSE file. + +{ + 'variables': { + # Default identity. Can be overridden to allow making custom + # plugins based on O3D, but they will not work with regular O3D apps. + 'plugin_name%': 'O3D Plugin', + 'plugin_npapi_filename%': 'npo3dautoplugin', + 'plugin_npapi_mimetype%': 'application/vnd.o3d.auto', + 'plugin_activex_hostcontrol_clsid%': '9666A772-407E-4F90-BC37-982E8160EB2D', + 'plugin_activex_typelib_clsid%': 'D4F6E31C-E952-48FE-9833-6AE308BD79C6', + 'plugin_activex_hostcontrol_name%': 'o3d_host', + 'plugin_activex_typelib_name%': 'npapi_host2', + 'plugin_installdir_csidl%': 'CSIDL_APPDATA', + 'plugin_vendor_directory%': 'Google', + 'plugin_product_directory%': 'O3D', + # You must set this to 1 if changing any of the above. + 'plugin_rebranded%': '0', + } +} diff --git a/o3d/plugin/cross/main.cc b/o3d/plugin/cross/main.cc index d71e103..fe49c7c 100644 --- a/o3d/plugin/cross/main.cc +++ b/o3d/plugin/cross/main.cc @@ -170,7 +170,7 @@ NPError EXPORT_SYMBOL OSCALL NP_GetEntryPoints(NPPluginFuncs *pluginFuncs) { } char* NP_GetMIMEDescription(void) { - return const_cast<char*>(O3D_PLUGIN_MIME_TYPE "::O3D MIME"); + return const_cast<char*>(O3D_PLUGIN_NPAPI_MIMETYPE "::O3D MIME"); } } // namespace o3d / extern "C" diff --git a/o3d/plugin/mac/Info.plist b/o3d/plugin/mac/Info.plist index c772f77..3bccd89 100644 --- a/o3d/plugin/mac/Info.plist +++ b/o3d/plugin/mac/Info.plist @@ -30,7 +30,7 @@ <string>@@@PluginDescription@@@</string> <key>WebPluginMIMETypes</key> <dict> - <key>@@@PluginMimeType@@@</key> + <key>@@@PluginNpapiMimeType@@@</key> <dict> <key>WebPluginTypeDescription</key> <string>@@@PluginName@@@ Type</string> diff --git a/o3d/plugin/mac/o3d_plugin.r b/o3d/plugin/mac/o3d_plugin.r index 8032bc7..cf1cc69 100644 --- a/o3d/plugin/mac/o3d_plugin.r +++ b/o3d/plugin/mac/o3d_plugin.r @@ -10,6 +10,6 @@ resource 'STR#' (127) { { } }; resource 'STR#' (128) { { - "@@@PluginMimeType@@@", + "@@@PluginNpapiMimeType@@@", "" } }; diff --git a/o3d/plugin/npapi_host_control/win/host_control.rgs b/o3d/plugin/npapi_host_control/win/host_control.rgs deleted file mode 100644 index 5aa4a7e..0000000 --- a/o3d/plugin/npapi_host_control/win/host_control.rgs +++ /dev/null @@ -1,42 +0,0 @@ -HKCU -{ - Software - { - Classes - { - o3d_host.O3DHostControl.1 = s 'O3DHostControl Class' - { - CLSID = s '{9666A772-407E-4F90-BC37-982E8160EB2D}' - 'Insertable' - } - o3d_host.O3DHostControl = s 'O3DHostControl Class' - { - CLSID = s '{9666A772-407E-4F90-BC37-982E8160EB2D}' - CurVer = s 'o3d_host.O3DHostControl.1' - } - NoRemove CLSID - { - ForceRemove {9666A772-407E-4F90-BC37-982E8160EB2D} = s 'O3DHostControl Class' - { - ProgID = s 'o3d_host.O3DHostControl.1' - VersionIndependentProgID = s 'o3d_host.O3DHostControl' - ForceRemove 'Programmable' - InprocServer32 = s '%MODULE%' - { - val ThreadingModel = s 'Apartment' - } - val AppID = s '%APPID%' - ForceRemove 'Control' - ForceRemove 'Insertable' - ForceRemove 'ToolboxBitmap32' = s '%MODULE%, 102' - 'MiscStatus' = s '0' - { - '1' = s '%OLEMISC%' - } - 'TypeLib' = s '{D4F6E31C-E952-48FE-9833-6AE308BD79C6}' - 'Version' = s '1.0' - } - } - } - } -} diff --git a/o3d/plugin/npapi_host_control/win/host_control.rgs_template b/o3d/plugin/npapi_host_control/win/host_control.rgs_template new file mode 100644 index 0000000..93d33e0 --- /dev/null +++ b/o3d/plugin/npapi_host_control/win/host_control.rgs_template @@ -0,0 +1,42 @@ +HKCU +{ + Software + { + Classes + { + @@@PluginActiveXHostControlName@@@.O3DHostControl.1 = s 'O3DHostControl Class' + { + CLSID = s '{@@@PluginActiveXHostControlClsid@@@}' + 'Insertable' + } + @@@PluginActiveXHostControlName@@@.O3DHostControl = s 'O3DHostControl Class' + { + CLSID = s '{@@@PluginActiveXHostControlClsid@@@}' + CurVer = s '@@@PluginActiveXHostControlName@@@.O3DHostControl.1' + } + NoRemove CLSID + { + ForceRemove {@@@PluginActiveXHostControlClsid@@@} = s 'O3DHostControl Class' + { + ProgID = s '@@@PluginActiveXHostControlName@@@.O3DHostControl.1' + VersionIndependentProgID = s '@@@PluginActiveXHostControlName@@@.O3DHostControl' + ForceRemove 'Programmable' + InprocServer32 = s '%MODULE%' + { + val ThreadingModel = s 'Apartment' + } + val AppID = s '%APPID%' + ForceRemove 'Control' + ForceRemove 'Insertable' + ForceRemove 'ToolboxBitmap32' = s '%MODULE%, 102' + 'MiscStatus' = s '0' + { + '1' = s '%OLEMISC%' + } + 'TypeLib' = s '{@@@PluginActiveXTypeLibClsid@@@}' + 'Version' = s '1.0' + } + } + } + } +} diff --git a/o3d/plugin/npapi_host_control/win/np_plugin_proxy.cc b/o3d/plugin/npapi_host_control/win/np_plugin_proxy.cc index 7de9d67..afc97d1 100644 --- a/o3d/plugin/npapi_host_control/win/np_plugin_proxy.cc +++ b/o3d/plugin/npapi_host_control/win/np_plugin_proxy.cc @@ -44,9 +44,12 @@ namespace { -const wchar_t kPluginName[] = L"npo3dautoplugin.dll"; +#define WIDE(s) WIDE2(s) +#define WIDE2(s) L##s + +const wchar_t kPluginName[] = WIDE(O3D_PLUGIN_NPAPI_FILENAME) L".dll"; const wchar_t kAppDataPluginLocation[] = - L"Mozilla\\plugins\\npo3dautoplugin.dll"; + L"Mozilla\\plugins\\" WIDE(O3D_PLUGIN_NPAPI_FILENAME) L".dll"; // Returns the path to the O3D plug-in located in the current user's // Application Data directory. Returns NULL on failure. @@ -83,7 +86,7 @@ const wchar_t* GetMozillaPluginPath() { } const wchar_t kProgramFilesPluginLocation[] = - L"Mozilla Firefox\\plugins\\npo3dautoplugin.dll"; + L"Mozilla Firefox\\plugins\\" WIDE(O3D_PLUGIN_NPAPI_FILENAME) L".dll"; // Returns the path to the O3D plug-in located in the Program // Files directory. Returns NULL on failure. diff --git a/o3d/plugin/npapi_host_control/win/npapi_host_control.idl b/o3d/plugin/npapi_host_control/win/npapi_host_control.idl_template index 14822c8..207c15a 100644 --- a/o3d/plugin/npapi_host_control/win/npapi_host_control.idl +++ b/o3d/plugin/npapi_host_control/win/npapi_host_control.idl_template @@ -73,7 +73,7 @@ interface INPObjectProxy : IDispatchEx { }; [ - uuid(D4F6E31C-E952-48FE-9833-6AE308BD79C6), + uuid(@@@PluginActiveXTypeLibClsid@@@), version(1.0), helpstring("npapi_host2 1.0 Type Library") ] @@ -81,7 +81,7 @@ library npapi_host_controlLib { importlib("stdole2.tlb"); [ - uuid(9666A772-407E-4F90-BC37-982E8160EB2D), + uuid(@@@PluginActiveXHostControlClsid@@@), //control, helpstring("HostControl Class") ] diff --git a/o3d/plugin/plugin.gyp b/o3d/plugin/plugin.gyp index f2cd0fc..7caf52b 100644 --- a/o3d/plugin/plugin.gyp +++ b/o3d/plugin/plugin.gyp @@ -55,13 +55,10 @@ '../../native_client/src/shared/imc/imc.gyp:google_nacl_imc', 'idl/idl.gyp:o3dPluginIdl', ], - # Default name and mimetype. Can be overridden to allow making custom - # plugins based on O3D, but they will not work with regular O3D apps. - 'plugin_name%': 'O3D Plugin', - 'plugin_mimetype%': 'application/vnd.o3d.auto', }, 'includes': [ '../build/common.gypi', + 'branding.gypi', ], 'target_defaults': { 'include_dirs': [ @@ -70,10 +67,14 @@ '../../<(gtestdir)', ], 'defines': [ - 'O3D_PLUGIN_DESCRIPTION="<!(python version_info.py --set_name="<(plugin_name)" --set_mimetype="<(plugin_mimetype)" --description)"', - 'O3D_PLUGIN_MIME_TYPE="<(plugin_mimetype)"', + 'O3D_PLUGIN_DESCRIPTION="<!(python version_info.py --set_name="<(plugin_name)" --set_npapi_mimetype="<(plugin_npapi_mimetype)" --description)"', + 'O3D_PLUGIN_NPAPI_FILENAME="<(plugin_npapi_filename)"', + 'O3D_PLUGIN_NPAPI_MIMETYPE="<(plugin_npapi_mimetype)"', 'O3D_PLUGIN_NAME="<(plugin_name)"', 'O3D_PLUGIN_VERSION="<!(python version_info.py --version)"', + 'O3D_PLUGIN_INSTALLDIR_CSIDL=<(plugin_installdir_csidl)', + 'O3D_PLUGIN_VENDOR_DIRECTORY="<(plugin_vendor_directory)"', + 'O3D_PLUGIN_PRODUCT_DIRECTORY="<(plugin_product_directory)"', ], }, 'targets': [ @@ -85,7 +86,7 @@ 'plugin_rpath%' : '/opt/google/o3d/lib', # empty => none 'plugin_env_vars_file%' : '/opt/google/o3d/envvars', # empty => none }, - 'target_name': 'npo3dautoplugin', + 'target_name': '<(plugin_npapi_filename)', 'type': 'loadable_module', 'dependencies': [ '<@(plugin_depends)', @@ -191,7 +192,7 @@ 'action': ['python', 'version_info.py', '--set_name=<(plugin_name)', - '--set_mimetype=<(plugin_mimetype)', + '--set_npapi_mimetype=<(plugin_npapi_mimetype)', 'mac/o3d_plugin.r', '${BUILT_PRODUCTS_DIR}/O3D.r', ], @@ -486,7 +487,7 @@ 'type': 'none', 'actions': [ { - 'action_name': 'add_version', + 'action_name': 'add_version_rc', 'inputs': [ 'version_info.py', ], @@ -502,7 +503,8 @@ 'action': ['python', 'version_info.py', '--set_name=<(plugin_name)', - '--set_mimetype=<(plugin_mimetype)', + '--set_npapi_filename=<(plugin_npapi_filename)', + '--set_npapi_mimetype=<(plugin_npapi_mimetype)', 'win/o3dPlugin.rc_template', 'win/o3dPlugin.rc'], }, @@ -518,7 +520,7 @@ 'action': ['python', 'version_info.py', '--set_name=<(plugin_name)', - '--set_mimetype=<(plugin_mimetype)', + '--set_npapi_mimetype=<(plugin_npapi_mimetype)', 'mac/Info.plist', '<(SHARED_INTERMEDIATE_DIR)/plugin/Info.plist', ], @@ -527,6 +529,29 @@ ], }, ], + 'conditions': [ + ['OS=="win"', + { + 'actions': [ + { + 'action_name': 'add_version_def', + 'inputs': [ + 'version_info.py', + 'win/o3dPlugin.def_template', + ], + 'outputs': [ + 'win/o3dPlugin.def', + ], + 'action': ['python', + 'version_info.py', + '--set_npapi_filename=<(plugin_npapi_filename)', + 'win/o3dPlugin.def_template', + 'win/o3dPlugin.def'], + }, + ], + }, + ], + ], }, ], }, @@ -535,8 +560,66 @@ { 'targets': [ { + 'target_name': 'gen_host_control_rgs', + 'type': 'none', + 'actions': [ + { + 'action_name': 'gen_host_control_rgs', + 'inputs': [ + 'version_info.py', + 'npapi_host_control/win/host_control.rgs_template', + ], + 'outputs': [ + 'npapi_host_control/win/host_control.rgs', + ], + 'action': ['python', + 'version_info.py', + '--set_activex_hostcontrol_clsid=' + + '<(plugin_activex_hostcontrol_clsid)', + '--set_activex_typelib_clsid=<(plugin_activex_typelib_clsid)', + '--set_activex_hostcontrol_name=' + + '<(plugin_activex_hostcontrol_name)', + '--set_activex_typelib_name=<(plugin_activex_typelib_name)', + 'npapi_host_control/win/host_control.rgs_template', + 'npapi_host_control/win/host_control.rgs', + ], + }, + ], + }, + { + 'target_name': 'gen_npapi_host_control_idl', + 'type': 'none', + 'actions': [ + { + 'action_name': 'gen_npapi_host_control_idl', + 'inputs': [ + 'version_info.py', + 'npapi_host_control/win/npapi_host_control.idl_template', + ], + 'outputs': [ + 'npapi_host_control/win/npapi_host_control.idl', + ], + 'action': ['python', + 'version_info.py', + '--set_activex_hostcontrol_clsid=' + + '<(plugin_activex_hostcontrol_clsid)', + '--set_activex_typelib_clsid=<(plugin_activex_typelib_clsid)', + '--set_activex_hostcontrol_name=' + + '<(plugin_activex_hostcontrol_name)', + '--set_activex_typelib_name=<(plugin_activex_typelib_name)', + 'npapi_host_control/win/npapi_host_control.idl_template', + 'npapi_host_control/win/npapi_host_control.idl', + ], + }, + ], + }, + { 'target_name': 'o3d_host', 'type': 'shared_library', + 'dependencies': [ + 'gen_host_control_rgs', + 'gen_npapi_host_control_idl', + ], 'include_dirs': [ '<(INTERMEDIATE_DIR)', ], @@ -591,6 +674,22 @@ ], }, ], + # If compiling with re-branding, we alias the branded NPAPI target name to + # the unbranded one so that targets depending on it can just refer to it + # by a constant name. + ['"<(plugin_npapi_filename)" != "npo3dautoplugin"', + { + 'targets': [ + { + 'target_name': 'npo3dautoplugin', + 'type': 'none', + 'dependencies': [ + '<(plugin_npapi_filename)', + ], + }, + ], + }, + ], ], } diff --git a/o3d/plugin/version_info.py b/o3d/plugin/version_info.py index 0a234dd..c019b0b 100644 --- a/o3d/plugin/version_info.py +++ b/o3d/plugin/version_info.py @@ -40,11 +40,26 @@ gflags.DEFINE_boolean('version', False, gflags.DEFINE_boolean('commaversion', False, 'Print out the plugin version with commas and exit.') -gflags.DEFINE_string('set_name', None, +gflags.DEFINE_string('set_name', '', 'Sets the plugin name to use.') -gflags.DEFINE_string('set_mimetype', None, - 'Sets the plugin mimetype to use.') +gflags.DEFINE_string('set_npapi_filename', '', + 'Sets the plugin NPAPI filename to use.') + +gflags.DEFINE_string('set_npapi_mimetype', '', + 'Sets the plugin NPAPI mimetype to use.') + +gflags.DEFINE_string('set_activex_hostcontrol_clsid', '', + 'Sets the ActiveX HostControl\'s CLSID to use.') + +gflags.DEFINE_string('set_activex_typelib_clsid', '', + 'Sets the ActiveX TypeLib\'s CLSID to use.') + +gflags.DEFINE_string('set_activex_hostcontrol_name', '', + 'Sets the ActiveX HostControl\'s name to use.') + +gflags.DEFINE_string('set_activex_typelib_name', '', + 'Sets the ActiveX TypeLib\'s name to use.') def GetDotVersion(version): return '%d.%d.%d.%d' % version @@ -100,7 +115,12 @@ def main(argv): O3D_SDK_VERSION_COMMAS = GetCommaVersion(sdk_version) O3D_PLUGIN_DESCRIPTION = '%s version: %s' % (O3D_PLUGIN_NAME, O3D_PLUGIN_VERSION) - O3D_PLUGIN_MIME_TYPE = FLAGS.set_mimetype + O3D_PLUGIN_NPAPI_FILENAME = FLAGS.set_npapi_filename + O3D_PLUGIN_NPAPI_MIMETYPE = FLAGS.set_npapi_mimetype + O3D_PLUGIN_ACTIVEX_HOSTCONTROL_CLSID = FLAGS.set_activex_hostcontrol_clsid + O3D_PLUGIN_ACTIVEX_TYPELIB_CLSID = FLAGS.set_activex_typelib_clsid + O3D_PLUGIN_ACTIVEX_HOSTCONTROL_NAME = FLAGS.set_activex_hostcontrol_name + O3D_PLUGIN_ACTIVEX_TYPELIB_NAME = FLAGS.set_activex_typelib_name if FLAGS.description: print '%s' % O3D_PLUGIN_DESCRIPTION @@ -119,7 +139,14 @@ def main(argv): ('@@@ProductVersionCommas@@@', O3D_PLUGIN_VERSION_COMMAS), ('@@@ProductVersion@@@', O3D_PLUGIN_VERSION), ('@@@PluginDescription@@@', O3D_PLUGIN_DESCRIPTION), - ('@@@PluginMimeType@@@', O3D_PLUGIN_MIME_TYPE), + ('@@@PluginNpapiFilename@@@', O3D_PLUGIN_NPAPI_FILENAME), + ('@@@PluginNpapiMimeType@@@', O3D_PLUGIN_NPAPI_MIMETYPE), + ('@@@PluginActiveXHostControlClsid@@@', + O3D_PLUGIN_ACTIVEX_HOSTCONTROL_CLSID), + ('@@@PluginActiveXTypeLibClsid@@@', O3D_PLUGIN_ACTIVEX_TYPELIB_CLSID), + ('@@@PluginActiveXHostControlName@@@', + O3D_PLUGIN_ACTIVEX_HOSTCONTROL_NAME), + ('@@@PluginActiveXTypeLibName@@@', O3D_PLUGIN_ACTIVEX_TYPELIB_NAME), ] if len(files) == 2: diff --git a/o3d/plugin/win/config.cc b/o3d/plugin/win/config.cc index ea36452..aa99482 100644 --- a/o3d/plugin/win/config.cc +++ b/o3d/plugin/win/config.cc @@ -104,7 +104,7 @@ bool OpenDriverBlacklistFile(std::ifstream *input_file) { TCHAR app_data_path[MAX_PATH]; HRESULT result = SHGetFolderPath( NULL, - CSIDL_APPDATA, + O3D_PLUGIN_INSTALLDIR_CSIDL, NULL, 0, app_data_path); @@ -113,7 +113,9 @@ bool OpenDriverBlacklistFile(std::ifstream *input_file) { return false; } - PathAppend(app_data_path, _T("Google\\O3D\\driver_blacklist.txt")); + PathAppend(app_data_path, + _T(O3D_PLUGIN_VENDOR_DIRECTORY) _T("\\") + _T(O3D_PLUGIN_PRODUCT_DIRECTORY) _T("\\driver_blacklist.txt")); if (!PathFileExists(app_data_path)) { return false; } diff --git a/o3d/plugin/win/o3dPlugin.def b/o3d/plugin/win/o3dPlugin.def_template index 9685d16..4e3600a 100644 --- a/o3d/plugin/win/o3dPlugin.def +++ b/o3d/plugin/win/o3dPlugin.def_template @@ -1,4 +1,4 @@ -LIBRARY npo3dautoplugin +LIBRARY @@@PluginNpapiFilename@@@ EXPORTS NP_GetEntryPoints @1 diff --git a/o3d/plugin/win/o3dPlugin.rc_template b/o3d/plugin/win/o3dPlugin.rc_template index 8085cf9..3fb0940 100644 --- a/o3d/plugin/win/o3dPlugin.rc_template +++ b/o3d/plugin/win/o3dPlugin.rc_template @@ -70,15 +70,15 @@ BEGIN BLOCK "040904e4" BEGIN // This value must not change format as it is used by javascript - // to find the plugin. See o3d/main.scons + // to find the plugin. VALUE "FileDescription", "@@@PluginDescription@@@" VALUE "FileVersion", "@@@ProductVersionCommas@@@" - VALUE "InternalName", "npo3dautoplugin" + VALUE "InternalName", "@@@PluginNpapiFilename@@@" VALUE "LegalCopyright", "Copyright (C) 2007" - VALUE "MIMEType", "@@@PluginMimeType@@@" - VALUE "OriginalFilename", "npo3dautoplugin.dll" + VALUE "MIMEType", "@@@PluginNpapiMimeType@@@" + VALUE "OriginalFilename", "@@@PluginNpapiFilename@@@.dll" // This value must not change as it is used by javascript - // to find the plugin. See o3d/main.scons + // to find the plugin. VALUE "ProductName", "@@@PluginName@@@" VALUE "ProductVersion", "@@@ProductVersionCommas@@@" END |