Bug 116609

Summary: [Qt][Win] r150484 broke the build
Product: WebKit Reporter: Zoltan Arvai <zarvai>
Component: New BugsAssignee: Nobody <webkit-unassigned>
Status: RESOLVED INVALID    
Severity: Normal CC: allan.jensen, andersca, hausmann, jturcotte, kadam, kbalazs, kling, ossy
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 116578    
Attachments:
Description Flags
plugin_process
none
trying some change none

Zoltan Arvai
Reported 2013-05-22 05:55:15 PDT
It seems ENABLE_NETSCAPE_PLUGIN_API=1 but ENABLE_PLUGIN_PROCESS is not set (not in Features) on Qt Win. Probably that makes the following error on it: WebPageProxy.cpp C:\buildslave\qt-windows-32bit-release\build\Source\WebKit2\UIProcess\WebPageProxy.cpp(1426) : error C2065: 'PluginProcessSandboxPolicy' : undeclared identifier C:\buildslave\qt-windows-32bit-release\build\Source\WebKit2\UIProcess\WebPageProxy.cpp(1426) : error C2146: syntax error : missing ';' before identifier 'pluginProcessSandboxPolicy' C:\buildslave\qt-windows-32bit-release\build\Source\WebKit2\UIProcess\WebPageProxy.cpp(1426) : error C2065: 'pluginProcessSandboxPolicy' : undeclared identifier C:\buildslave\qt-windows-32bit-release\build\Source\WebKit2\UIProcess\WebPageProxy.cpp(1429) : error C2065: 'pluginProcessSandboxPolicy' : undeclared identifier C:\buildslave\qt-windows-32bit-release\build\Source\WebKit2\UIProcess\WebPageProxy.cpp(1429) : error C2065: 'PluginProcessSandboxPolicyNormal' : undeclared identifier C:\buildslave\qt-windows-32bit-release\build\Source\WebKit2\UIProcess\WebPageProxy.cpp(1432) : error C2065: 'pluginProcessSandboxPolicy' : undeclared identifier C:\buildslave\qt-windows-32bit-release\build\Source\WebKit2\UIProcess\WebPageProxy.cpp(1432) : error C2065: 'PluginProcessSandboxPolicyUnsandboxed' : undeclared identifier C:\buildslave\qt-windows-32bit-release\build\Source\WebKit2\UIProcess\WebPageProxy.cpp(1441) : error C2065: 'pluginProcessSandboxPolicy' : undeclared identifier C:\buildslave\qt-windows-32bit-release\build\Source\WebKit2\UIProcess\WebPageProxy.cpp(1441) : error C2065: 'PluginProcessSandboxPolicyUnsandboxed' : undeclared identifier C:\buildslave\qt-windows-32bit-release\build\Source\WebKit2\UIProcess\WebPageProxy.cpp(1442) : error C2653: 'PluginProcessManager' : is not a class or namespace name C:\buildslave\qt-windows-32bit-release\build\Source\WebKit2\UIProcess\WebPageProxy.cpp(1442) : error C2228: left of '.pluginProcessToken' must have class/struct/union type is ''unknown-type'' C:\buildslave\qt-windows-32bit-release\build\Source\WebKit2\UIProcess\WebPageProxy.cpp(1442) : error C2061: syntax error : identifier 'PluginProcessType'
Attachments
plugin_process (1.24 KB, patch)
2013-05-23 07:31 PDT, Zoltan Arvai
no flags
trying some change (1.88 KB, patch)
2013-05-29 07:04 PDT, Zoltan Arvai
no flags
Zoltan Arvai
Comment 1 2013-05-22 05:57:58 PDT
"#if ENABLE(PLUGIN_PROCESS)" guard is removed from WebKit2/Shared/Plugins/PluginProcessAttributes.h https://trac.webkit.org/changeset/150484/trunk/Source/WebKit2/Shared/Plugins/PluginProcessAttributes.h
Csaba Osztrogonác
Comment 2 2013-05-22 06:02:03 PDT
Yes, plugin process is mandatory now, as Anders announced it on webkit-dev. In this case it would be great to fix it in Qt build system too.
Csaba Osztrogonác
Comment 3 2013-05-22 06:11:35 PDT
Hmmm ... PluginProcess is really disabled on Qt Windows: https://trac.webkit.org/browser/trunk/Tools/qmake/mkspecs/features/features.prf#L66 It is enabled if xlib is available.
Csaba Osztrogonác
Comment 4 2013-05-22 06:17:29 PDT
Plugin process was enabled by https://trac.webkit.org/changeset/112889 on unix long long time ago. Is there a reason why wasn't it enabled on Windows too?
Zoltan Arvai
Comment 5 2013-05-23 07:31:41 PDT
Created attachment 202713 [details] plugin_process I played a little bit with the Windows build to see what happens if I turn on plugin_process on Win. Currently I got some error: PluginProcessQt.cpp C:\WebKitBuildSlave\proba\WebKit\Source\WebKit2\PluginProcess\qt\PluginProcessMa inQt.cpp(88) : error C2039: 'scanPlugin' : is not a member of 'WebKit::NetscapeP luginModule' C:\WebKitBuildSlave\proba\WebKit\Source\WebKit2\Shared\Plugins\Netscape\ NetscapePluginModule.h(42) : see declaration of 'WebKit::NetscapePluginModule' C:\WebKitBuildSlave\proba\WebKit\Source\WebKit2\PluginProcess\qt\PluginProcessMa inQt.cpp(88) : error C3861: 'scanPlugin': identifier not found C:\WebKitBuildSlave\proba\WebKit\Source\WebKit2\PluginProcess\qt\PluginProcessMa inQt.cpp(100) : error C2440: '=' : cannot convert from 'int' to 'CoreIPC::Connec tion::Identifier' Conversion from integral type to pointer type requires reinterpret_cast, C-style cast or function-style cast
Csaba Osztrogonác
Comment 6 2013-05-23 07:42:47 PDT
It seems the problem is that NetscapePluginModule::scanPlugin is implemented in NetscapePluginModuleX11.cpp Maybe disabling scanPlugin commandline option for !PLUGIN_ARCHITECTURE(X11) platform would be a good workaround until the proper fix. But it would be better if a _Qt_ engineer could comment this bug what is their plan with QtWebKit on Windows. Are you interested in making it buildable again?
Csaba Osztrogonác
Comment 7 2013-05-23 07:48:50 PDT
Source/WebKit2/Shared/Plugins/Netscape/NetscapePluginModule.h: ... #if PLUGIN_ARCHITECTURE(X11) static bool scanPlugin(const String& pluginPath); #endif ... So it seems you only need to add similar #if guard. I bet in this case plugins won't work at all ... but at least WebKit2 will be buildable. :)
Jocelyn Turcotte
Comment 8 2013-05-23 08:19:11 PDT
(In reply to comment #6) > But it would be better if a _Qt_ engineer could comment this bug what is their > plan with QtWebKit on Windows. Are you interested in making it buildable again? There is no plan for 5.2 to implement the missing pieces to make WK2 plugins work on Windows, we should at least make sure that it doesn't crash before we release. Hopefully we can keep the rest working until then without too much hassle. Ping me on IRC if you find out that this needs a bit more plumbing.
Balazs Kelemen
Comment 9 2013-05-23 08:20:33 PDT
(In reply to comment #7) > Source/WebKit2/Shared/Plugins/Netscape/NetscapePluginModule.h: > ... > #if PLUGIN_ARCHITECTURE(X11) > static bool scanPlugin(const String& pluginPath); > #endif > ... > > So it seems you only need to add similar #if guard. I bet in this case > plugins won't work at all ... but at least WebKit2 will be buildable. :) The code we have for plugins is only for X11. AFAIK Qt-WK2 has no plugin support on Windows currently, and there is not even a native Windows implementation for WebKit2 that can be simply reused. Fixing the build is a matter of adding guards for these files (rather in the files than in the build system but it's your choice). I believe IRC is a more efficient channel to resolve such not too complex problems :)
Anders Carlsson
Comment 10 2013-05-23 10:04:53 PDT
Maybe Qt/WebKit2 on Windows can just disable netscape plug-ins altogether?
Balazs Kelemen
Comment 11 2013-05-23 14:02:07 PDT
(In reply to comment #10) > Maybe Qt/WebKit2 on Windows can just disable netscape plug-ins altogether? Indeed.
Zoltan Arvai
Comment 12 2013-05-29 06:49:01 PDT
I turned off WebKit2 on Qt Win bot until we figure out the right solution for the issues.
Zoltan Arvai
Comment 13 2013-05-29 07:04:23 PDT
Created attachment 203198 [details] trying some change With disabled Netscape Plugin Api an #if turns to true in WebCore/plugins/PluginDatabase.cpp that probably should be false on Qt Win. After changing it some methods are turning to unresolved external symbol, so I added some dummy function to try a build. Maybe this is not the right way, 'cause I got errors. WebKit1.lib(qwebplugindatabase.obj) : error LNK2019: unresolved external symbol "public: static class WTF::Vector<class WTF::String,0,class WTF::CrashOnOverflow> __cdecl WebCore::PluginDatabase::defaultPluginDirectories(void)" (?defaultPluginDirectories@PluginDatabase@WebCore@@SA?AV?$Vector@VString@WTF@@$0A@VCrashOnOverflow@2@@WTF@@XZ) referenced in function "public: static class QStringList __cdecl QWebPluginDatabase::defaultSearchPaths(void)" (?defaultSearchPaths@QWebPluginDatabase@@SA?AVQStringList@@XZ) WebCore.lib(PluginDatabase.obj) : error LNK2001: unresolved external symbol "public: static class WTF::Vector<class WTF::String,0,class WTF::CrashOnOverflow> __cdecl WebCore::PluginDatabase::defaultPluginDirectories(void)" (?defaultPluginDirectories@PluginDatabase@WebCore@@SA?AV?$Vector@VString@WTF@@$0A@VCrashOnOverflow@2@@WTF@@XZ) WebCore.lib(PluginDatabase.obj) : error LNK2019: unresolved external symbol "public: unsigned int __thiscall WebCore::PluginPackage::hash(void)const " (?hash@PluginPackage@WebCore@@QBEIXZ) referenced in function "public: static unsigned int __cdecl WebCore::PluginPackageHash::hash(class WTF::RefPtr<class WebCore::PluginPackage> const &)" (?hash@PluginPackageHash@WebCore@@SAIABV?$RefPtr@VPluginPackage@WebCore@@@WTF@@@Z) WebCore.lib(PluginDatabase.obj) : error LNK2019: unresolved external symbol "public: static bool __cdecl WebCore::PluginPackage::equal(class WebCore::PluginPackage const &,class WebCore::PluginPackage const &)" (?equal@PluginPackage@WebCore@@SA_NABV12@0@Z) referenced in function "public: static bool __cdecl WebCore::PluginPackageHash::equal(class WTF::RefPtr<class WebCore::PluginPackage> const &,class WTF::RefPtr<class WebCore::PluginPackage> const &)" (?equal@PluginPackageHash@WebCore@@SA_NABV?$RefPtr@VPluginPackage@WebCore@@@WTF@@0@Z) WebCore.lib(PluginDatabase.obj) : error LNK2019: unresolved external symbol "private: void __thiscall WebCore::PluginDatabase::getPluginPathsInDirectories(class WTF::HashSet<class WTF::String,struct WTF::StringHash,struct WTF::HashTraits<class WTF::String> > &)const " (?getPluginPathsInDirectories@PluginDatabase@WebCore@@ABEXAAV?$HashSet@VString@WTF@@UStringHash@2@U?$HashTraits@VString@WTF@@@2@@WTF@@@Z) referenced in function "public: bool __thiscall WebCore::PluginDatabase::refresh(void)" (?refresh@PluginDatabase@WebCore@@QAE_NXZ) WebCore.lib(PluginPackage.obj) : error LNK2019: unresolved external symbol "public: static bool __cdecl WebCore::PluginDatabase::isPreferredPluginDirectory(class WTF::String const &)" (?isPreferredPluginDirectory@PluginDatabase@WebCore@@SA_NABVString@WTF@@@Z) referenced in function "public: int __thiscall WebCore::PluginPackage::compare(class WebCore::PluginPackage const &)const " (?compare@PluginPackage@WebCore@@QBEHABV12@@Z) WTF.lib(OSRandomSource.obj) : error LNK2019: unresolved external symbol __imp__CryptReleaseContext@8 referenced in function "void __cdecl WTF::cryptographicallyRandomValuesFromOS(unsigned char *,unsigned int)" (?cryptographicallyRandomValuesFromOS@WTF@@YAXPAEI@Z) WTF.lib(OSRandomSource.obj) : error LNK2019: unresolved external symbol __imp__CryptGenRandom@12 referenced in function "void __cdecl WTF::cryptographicallyRandomValuesFromOS(unsigned char *,unsigned int)" (?cryptographicallyRandomValuesFromOS@WTF@@YAXPAEI@Z) WTF.lib(OSRandomSource.obj) : error LNK2019: unresolved external symbol __imp__CryptAcquireContextW@20 referenced in function "void __cdecl WTF::cryptographicallyRandomValuesFromOS(unsigned char *,unsigned int)" (?cryptographicallyRandomValuesFromOS@WTF@@YAXPAEI@Z) ..\lib\Qt5WebKit.dll : fatal error LNK1120: 8 unresolved externals
Note You need to log in before you can comment on or make changes to this bug.