First step toward iOS Support

This commit is contained in:
Jonathan Jayet 2017-08-22 16:30:32 +02:00
parent 8ca9542de6
commit 1a447c6984
7 changed files with 22 additions and 15 deletions

View file

@ -41,5 +41,5 @@ servo_url = {path = "../url"}
webvr_traits = {path = "../webvr_traits"}
webrender_api = {git = "https://github.com/servo/webrender", features = ["ipc"]}
[target.'cfg(not(target_os = "windows"))'.dependencies]
[target.'cfg(all(not(target_os = "windows"), not(target_os = "ios")))'.dependencies]
gaol = {git = "https://github.com/servo/gaol"}

View file

@ -16,7 +16,7 @@ extern crate compositing;
extern crate debugger;
extern crate devtools_traits;
extern crate euclid;
#[cfg(not(target_os = "windows"))]
#[cfg(all(not(target_os = "windows"), not(target_os = "ios")))]
extern crate gaol;
extern crate gfx;
extern crate gfx_traits;
@ -46,11 +46,11 @@ mod constellation;
mod event_loop;
mod network_listener;
mod pipeline;
#[cfg(not(target_os = "windows"))]
#[cfg(all(not(target_os = "windows"), not(target_os = "ios")))]
mod sandboxing;
mod timer_scheduler;
pub use constellation::{Constellation, FromCompositorLogger, FromScriptLogger, InitialConstellationState};
pub use pipeline::UnprivilegedPipelineContent;
#[cfg(not(target_os = "windows"))]
#[cfg(all(not(target_os = "windows"), not(target_os = "ios")))]
pub use sandboxing::content_process_sandbox_profile;

View file

@ -535,7 +535,7 @@ impl UnprivilegedPipelineContent {
}
}
#[cfg(not(target_os = "windows"))]
#[cfg(all(not(target_os = "windows"), not(target_os = "ios")))]
pub fn spawn_multiprocess(self) -> Result<(), Error> {
use gaol::sandbox::{self, Sandbox, SandboxMethods};
use ipc_channel::ipc::IpcOneShotServer;
@ -583,9 +583,9 @@ impl UnprivilegedPipelineContent {
Ok(())
}
#[cfg(target_os = "windows")]
#[cfg(any(target_os = "windows", target_os = "ios"))]
pub fn spawn_multiprocess(self) -> Result<(), Error> {
error!("Multiprocess is not supported on Windows.");
error!("Multiprocess is not supported on Windows or iOS.");
process::exit(1);
}