Add support for running the networking process as an XPCService
authorweinig@apple.com <weinig@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 27 Jan 2013 05:32:53 +0000 (05:32 +0000)
committerweinig@apple.com <weinig@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 27 Jan 2013 05:32:53 +0000 (05:32 +0000)
commit4ddd9964853acc229754a2def976e3d434b25374
tree81a9958fe103a35dac435ca87f9262030a71e1d1
parente4c1a78472de16af1777739e549aec806b57857b
Add support for running the networking process as an XPCService
https://bugs.webkit.org/show_bug.cgi?id=108025

Reviewed by Dan Bernstein.

* Configurations/NetworkService.Development.xcconfig: Copied from Source/WebKit2/Configurations/WebContentService.Development.xcconfig.
* Configurations/NetworkService.xcconfig: Copied from Source/WebKit2/Configurations/WebContentService.xcconfig.
Add configurations.

* NetworkProcess/EntryPoint/mac/XPCService: Added.
* NetworkProcess/EntryPoint/mac/XPCService/NetworkService: Added.
* NetworkProcess/EntryPoint/mac/XPCService/NetworkService.Development: Added.
* NetworkProcess/EntryPoint/mac/XPCService/NetworkService.Development/Info.plist: Copied from Source/WebKit2/WebProcess/EntryPoint/mac/XPCService/WebContentService.Development/Info.plist.
* NetworkProcess/EntryPoint/mac/XPCService/NetworkService.Development/NetworkServiceMain.Development.mm: Copied from Source/WebKit2/WebProcess/EntryPoint/mac/XPCService/WebContentService.Development/WebContentServiceMain.Development.mm.
* NetworkProcess/EntryPoint/mac/XPCService/NetworkService/Info.plist: Copied from Source/WebKit2/WebProcess/EntryPoint/mac/XPCService/WebContentService/Info.plist.
* NetworkProcess/EntryPoint/mac/XPCService/NetworkService/NetworkServiceMain.mm: Copied from Source/WebKit2/WebProcess/EntryPoint/mac/XPCService/WebContentService/WebContentServiceMain.mm.
* NetworkProcess/EntryPoint/mac/XPCService/NetworkServiceEntryPoint.mm: Copied from Source/WebKit2/WebProcess/EntryPoint/mac/XPCService/WebContentServiceEntryPoint.mm.
(initializeNetworkService):
Add entry points.

* UIProcess/Launcher/mac/ProcessLauncherMac.mm:
(WebKit::serviceName):
(WebKit::connectToServiceForDevelopment):
(WebKit::createServiceForDevelopment):
(WebKit::createService):
(WebKit::createProcess):
(WebKit::ProcessLauncher::launchProcess):
Rework service creation to work for arbitrary services.

* UIProcess/Network/NetworkProcessProxy.cpp:
(WebKit::NetworkProcessProxy::~NetworkProcessProxy):
(WebKit::NetworkProcessProxy::getLaunchOptions):
* UIProcess/Network/NetworkProcessProxy.h:
* UIProcess/Network/mac/NetworkProcessProxyMac.mm:
(WebKit::shouldUseXPC):
(WebKit::NetworkProcessProxy::platformGetLaunchOptions):
Opt into xpc using the same rules as the WebProcess.

* WebKit2.xcodeproj/project.pbxproj:
Update files.

* WebProcess/EntryPoint/mac/XPCService/WebContentServiceEntryPoint.mm:
(initializeWebContentService):
Fix the comment to refer to the shim correctly.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@140924 268f45cc-cd09-0410-ab3c-d52691b4dbfc
14 files changed:
Source/WebKit2/ChangeLog
Source/WebKit2/Configurations/NetworkService.Development.xcconfig [new file with mode: 0644]
Source/WebKit2/Configurations/NetworkService.xcconfig [new file with mode: 0644]
Source/WebKit2/NetworkProcess/EntryPoint/mac/XPCService/NetworkService.Development/Info.plist [new file with mode: 0644]
Source/WebKit2/NetworkProcess/EntryPoint/mac/XPCService/NetworkService.Development/NetworkServiceMain.Development.mm [new file with mode: 0644]
Source/WebKit2/NetworkProcess/EntryPoint/mac/XPCService/NetworkService/Info.plist [new file with mode: 0644]
Source/WebKit2/NetworkProcess/EntryPoint/mac/XPCService/NetworkService/NetworkServiceMain.mm [new file with mode: 0644]
Source/WebKit2/NetworkProcess/EntryPoint/mac/XPCService/NetworkServiceEntryPoint.mm [new file with mode: 0644]
Source/WebKit2/UIProcess/Launcher/mac/ProcessLauncherMac.mm
Source/WebKit2/UIProcess/Network/NetworkProcessProxy.cpp
Source/WebKit2/UIProcess/Network/NetworkProcessProxy.h
Source/WebKit2/UIProcess/Network/mac/NetworkProcessProxyMac.mm
Source/WebKit2/WebKit2.xcodeproj/project.pbxproj
Source/WebKit2/WebProcess/EntryPoint/mac/XPCService/WebContentServiceEntryPoint.mm