Bug 1402304 - Update Cargo lockfiles and re-vendor rust dependencies. r?jrmuizel draft
authorKartikaya Gupta <kgupta@mozilla.com>
Fri, 22 Sep 2017 09:58:21 -0400
changeset 669103 aaa20faab3825f7b35295af19116c7094d5341ea
parent 669102 360af82ea6b5acfc0a0e194510e6c4c47725153c
child 669104 00a137f48b800151904babe3e38bc48504cb66fa
push id81210
push userkgupta@mozilla.com
push dateFri, 22 Sep 2017 14:09:59 +0000
reviewersjrmuizel
bugs1402304
milestone58.0a1
Bug 1402304 - Update Cargo lockfiles and re-vendor rust dependencies. r?jrmuizel MozReview-Commit-ID: 3WHcJZG6FTf
third_party/rust/core-foundation-sys-0.3.1/.cargo-checksum.json
third_party/rust/core-foundation-sys-0.3.1/.cargo-ok
third_party/rust/core-foundation-sys-0.3.1/Cargo.toml
third_party/rust/core-foundation-sys-0.3.1/build.rs
third_party/rust/core-foundation-sys-0.3.1/src/array.rs
third_party/rust/core-foundation-sys-0.3.1/src/base.rs
third_party/rust/core-foundation-sys-0.3.1/src/bundle.rs
third_party/rust/core-foundation-sys-0.3.1/src/data.rs
third_party/rust/core-foundation-sys-0.3.1/src/date.rs
third_party/rust/core-foundation-sys-0.3.1/src/dictionary.rs
third_party/rust/core-foundation-sys-0.3.1/src/error.rs
third_party/rust/core-foundation-sys-0.3.1/src/lib.rs
third_party/rust/core-foundation-sys-0.3.1/src/messageport.rs
third_party/rust/core-foundation-sys-0.3.1/src/number.rs
third_party/rust/core-foundation-sys-0.3.1/src/propertylist.rs
third_party/rust/core-foundation-sys-0.3.1/src/runloop.rs
third_party/rust/core-foundation-sys-0.3.1/src/set.rs
third_party/rust/core-foundation-sys-0.3.1/src/string.rs
third_party/rust/core-foundation-sys-0.3.1/src/url.rs
third_party/rust/core-foundation-sys/.cargo-checksum.json
third_party/rust/core-foundation-sys/Cargo.toml
third_party/rust/core-foundation-sys/build.rs
third_party/rust/core-foundation-sys/src/bundle.rs
third_party/rust/core-foundation-sys/src/lib.rs
third_party/rust/core-foundation-sys/src/number.rs
third_party/rust/core-foundation-sys/src/set.rs
third_party/rust/core-foundation-sys/src/url.rs
third_party/rust/core-foundation/.cargo-checksum.json
third_party/rust/core-foundation/Cargo.toml
third_party/rust/core-foundation/src/bundle.rs
third_party/rust/core-foundation/src/runloop.rs
third_party/rust/core-foundation/src/url.rs
third_party/rust/core-graphics/.cargo-checksum.json
third_party/rust/core-graphics/Cargo.toml
third_party/rust/core-graphics/src/base.rs
third_party/rust/core-graphics/src/color_space.rs
third_party/rust/core-graphics/src/context.rs
third_party/rust/core-graphics/src/data_provider.rs
third_party/rust/core-graphics/src/display.rs
third_party/rust/core-graphics/src/event.rs
third_party/rust/core-graphics/src/event_source.rs
third_party/rust/core-graphics/src/font.rs
third_party/rust/core-graphics/src/geometry.rs
third_party/rust/core-graphics/src/image.rs
third_party/rust/core-graphics/src/lib.rs
third_party/rust/core-text/.cargo-checksum.json
third_party/rust/core-text/Cargo.toml
toolkit/library/gtest/rust/Cargo.lock
toolkit/library/rust/Cargo.lock
new file mode 100644
--- /dev/null
+++ b/third_party/rust/core-foundation-sys-0.3.1/.cargo-checksum.json
@@ -0,0 +1,1 @@
+{"files":{".cargo-ok":"e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855","Cargo.toml":"4516face4b018e46fc36cfe24eff335671684032a75435305d62fd5f280f05a7","build.rs":"4dbf3e5a423e5eba48fc7f11e4f7638c054e53a3750c888059a96d96f8923ef2","src/array.rs":"d648ed8cf0ccb72c3ca0d9e018a3db804edad9685739eba13f8f515e04f3708b","src/base.rs":"c995d91c9e5aed99ea28fc75561cfd573f5e8ff806ef512194e7b616c35c308f","src/bundle.rs":"ff5f5253f331b7fa054414a3f256d74760e3ce805b720cdb735a2e46cc66dce6","src/data.rs":"21e968951fe56e080d33474f4438de2dfb7e0c8af426a6dfb100efdd6c530eec","src/date.rs":"f6cdcb94658fafc5bacb83cfbd20ad97502b8ddf6bd1c0c0d6a2545a4f7b7420","src/dictionary.rs":"97c40c1afc719b970968179112ad76c3c89b6b4eb4ea18f7ac3f059d98cce736","src/error.rs":"61bc31a401ec6c8495668175eade9284e257da056fc666af74a5555af5daf33f","src/lib.rs":"8bdbc6ed8fcbbc5b69d7634031ff44d50b9ac789279eb89b80c280ea156c98b3","src/messageport.rs":"59ba92ca90bb9b3162b6df44188fac18cd979250f33a52361144c902e86529bd","src/number.rs":"8881c7cd1b510c654c445485de898f83abda91557fd3e6f9daccf2d1b9c4c57e","src/propertylist.rs":"cc2b27f8f8ebc80c03871b7b1ad50ee348539b016078ce721c86b8cd5f9d75bd","src/runloop.rs":"7feab3bbb9913c3b40285bc37b920f9fe4d937d1db08d8ae69a2ec9597713598","src/set.rs":"51e978fc81d4c55013dfc6df4e76c58daaf5deedf9aafda0f6a9e04e7575272c","src/string.rs":"27b92e8e5d3fc95a521dc6447ccfefd9eb28ec5f42bd8571defd124d950b133f","src/url.rs":"8a3f4137ca26e379a24666b4caa7a08f9726f838e53e9dbb92ba474036309669"},"package":"41115a6aa5d3e1e5ef98148373f25971d1fad53818553f216495f9e67e90a624"}
\ No newline at end of file
new file mode 100644
new file mode 100644
--- /dev/null
+++ b/third_party/rust/core-foundation-sys-0.3.1/Cargo.toml
@@ -0,0 +1,12 @@
+[package]
+name = "core-foundation-sys"
+description = "Bindings to Core Foundation for OS X"
+homepage = "https://github.com/servo/core-foundation-rs"
+repository = "https://github.com/servo/core-foundation-rs"
+version = "0.3.1"
+authors = ["The Servo Project Developers"]
+license = "MIT / Apache-2.0"
+build = "build.rs"
+
+[dependencies]
+libc = "0.2"
new file mode 100644
--- /dev/null
+++ b/third_party/rust/core-foundation-sys-0.3.1/build.rs
@@ -0,0 +1,12 @@
+// Copyright 2013-2015 The Servo Project Developers. See the COPYRIGHT
+// file at the top-level directory of this distribution.
+//
+// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
+// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
+// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
+// option. This file may not be copied, modified, or distributed
+// except according to those terms.
+
+fn main() {
+    println!("cargo:rustc-link-lib=framework=CoreFoundation");
+}
new file mode 100644
--- /dev/null
+++ b/third_party/rust/core-foundation-sys-0.3.1/src/array.rs
@@ -0,0 +1,61 @@
+// Copyright 2013-2015 The Servo Project Developers. See the COPYRIGHT
+// file at the top-level directory of this distribution.
+//
+// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
+// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
+// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
+// option. This file may not be copied, modified, or distributed
+// except according to those terms.
+
+use libc::c_void;
+
+use base::{CFRange, CFIndex, CFAllocatorRef, CFTypeID};
+
+/// FIXME(pcwalton): This is wrong.
+pub type CFArrayRetainCallBack = *const u8;
+
+/// FIXME(pcwalton): This is wrong.
+pub type CFArrayReleaseCallBack = *const u8;
+
+/// FIXME(pcwalton): This is wrong.
+pub type CFArrayCopyDescriptionCallBack = *const u8;
+
+/// FIXME(pcwalton): This is wrong.
+pub type CFArrayEqualCallBack = *const u8;
+
+#[repr(C)]
+#[derive(Clone, Copy)]
+pub struct CFArrayCallBacks {
+    pub version: CFIndex,
+    pub retain: CFArrayRetainCallBack,
+    pub release: CFArrayReleaseCallBack,
+    pub copyDescription: CFArrayCopyDescriptionCallBack,
+    pub equal: CFArrayEqualCallBack,
+}
+
+#[repr(C)]
+pub struct __CFArray(c_void);
+
+pub type CFArrayRef = *const __CFArray;
+
+extern {
+    /*
+     * CFArray.h
+     */
+    pub static kCFTypeArrayCallBacks: CFArrayCallBacks;
+
+    pub fn CFArrayCreate(allocator: CFAllocatorRef, values: *const *const c_void,
+                     numValues: CFIndex, callBacks: *const CFArrayCallBacks) -> CFArrayRef;
+    pub fn CFArrayCreateCopy(allocator: CFAllocatorRef , theArray: CFArrayRef) -> CFArrayRef;
+    
+    // CFArrayBSearchValues
+    // CFArrayContainsValue
+    pub fn CFArrayGetCount(theArray: CFArrayRef) -> CFIndex;
+    // CFArrayGetCountOfValue
+    // CFArrayGetFirstIndexOfValue
+    // CFArrayGetLastIndexOfValue
+    pub fn CFArrayGetValues(theArray: CFArrayRef, range: CFRange, values: *mut *const c_void);
+    pub fn CFArrayGetValueAtIndex(theArray: CFArrayRef, idx: CFIndex) -> *const c_void;
+    // CFArrayApplyFunction
+    pub fn CFArrayGetTypeID() -> CFTypeID;
+}
new file mode 100644
--- /dev/null
+++ b/third_party/rust/core-foundation-sys-0.3.1/src/base.rs
@@ -0,0 +1,76 @@
+// Copyright 2013-2015 The Servo Project Developers. See the COPYRIGHT
+// file at the top-level directory of this distribution.
+//
+// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
+// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
+// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
+// option. This file may not be copied, modified, or distributed
+// except according to those terms.
+
+use libc::{c_uint, c_long, c_ulong, c_void, c_int};
+
+pub type Boolean = u8;
+pub type CFIndex = c_long;
+pub type mach_port_t = c_uint;
+pub type CFAllocatorRef = *const c_void;
+pub type CFNullRef = *const c_void;
+pub type CFHashCode = c_ulong;
+pub type CFTypeID = c_ulong;
+pub type CFTypeRef = *const c_void;
+pub type CFOptionFlags = u32;
+pub type OSStatus = i32;
+pub type SInt32 = c_int;
+
+#[repr(C)]
+#[derive(Clone, Copy)]
+pub struct CFRange {
+    pub location: CFIndex,
+    pub length: CFIndex
+}
+
+// for back-compat
+impl CFRange {
+    pub fn init(location: CFIndex, length: CFIndex) -> CFRange {
+        CFRange {
+            location: location,
+            length: length,
+        }
+    }
+}
+
+extern {
+    /*
+     * CFBase.h
+     */
+
+    /* CFAllocator Reference */
+    // N.B. Many CFAllocator functions and constants are omitted here.
+    pub static kCFAllocatorDefault: CFAllocatorRef;
+    pub static kCFAllocatorSystemDefault: CFAllocatorRef;
+    pub static kCFAllocatorMalloc: CFAllocatorRef;
+    pub static kCFAllocatorMallocZone: CFAllocatorRef;
+    pub static kCFAllocatorNull: CFAllocatorRef;
+    pub static kCFAllocatorUseContext: CFAllocatorRef;
+
+    /* CFNull Reference */
+
+    pub static kCFNull: CFNullRef;
+
+    /* CFType Reference */
+
+    //fn CFCopyDescription
+    //fn CFCopyTypeIDDescription
+    //fn CFEqual
+    //fn CFGetAllocator
+    pub fn CFEqual(cf1: CFTypeRef, cf2: CFTypeRef) -> Boolean;
+    pub fn CFGetRetainCount(cf: CFTypeRef) -> CFIndex;
+    pub fn CFGetTypeID(cf: CFTypeRef) -> CFTypeID;
+    pub fn CFHash(cf: CFTypeRef) -> CFHashCode;
+    //fn CFMakeCollectable
+    pub fn CFRelease(cf: CFTypeRef);
+    pub fn CFRetain(cf: CFTypeRef) -> CFTypeRef;
+    pub fn CFShow(obj: CFTypeRef);
+
+    /* Base Utilities Reference */
+    // N.B. Some things missing here.
+}
new file mode 100644
--- /dev/null
+++ b/third_party/rust/core-foundation-sys-0.3.1/src/bundle.rs
@@ -0,0 +1,31 @@
+// Copyright 2013-2015 The Servo Project Developers. See the COPYRIGHT
+// file at the top-level directory of this distribution.
+//
+// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
+// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
+// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
+// option. This file may not be copied, modified, or distributed
+// except according to those terms.
+
+use libc::c_void;
+
+use base::CFTypeID;
+use dictionary::CFDictionaryRef;
+use string::CFStringRef;
+
+#[repr(C)]
+pub struct __CFBundle(c_void);
+
+pub type CFBundleRef = *const __CFBundle;
+
+extern {
+    /*
+     * CFBundle.h
+     */
+    pub fn CFBundleGetBundleWithIdentifier(bundleID: CFStringRef) -> CFBundleRef;
+    pub fn CFBundleGetFunctionPointerForName(bundle: CFBundleRef, function_name: CFStringRef) -> *const c_void;
+    pub fn CFBundleGetMainBundle() -> CFBundleRef;
+    pub fn CFBundleGetInfoDictionary(bundle: CFBundleRef) -> CFDictionaryRef;
+
+    pub fn CFBundleGetTypeID() -> CFTypeID;
+}
new file mode 100644
--- /dev/null
+++ b/third_party/rust/core-foundation-sys-0.3.1/src/data.rs
@@ -0,0 +1,22 @@
+use libc::c_void;
+
+use base::{CFAllocatorRef, CFTypeID, CFIndex};
+
+#[repr(C)]
+pub struct __CFData(c_void);
+
+pub type CFDataRef = *const __CFData;
+
+extern {
+    /*
+     * CFData.h
+     */
+
+    pub fn CFDataCreate(allocator: CFAllocatorRef,
+                        bytes: *const u8, length: CFIndex) -> CFDataRef;
+    //fn CFDataFind
+    pub fn CFDataGetBytePtr(theData: CFDataRef) -> *const u8;
+    pub fn CFDataGetLength(theData: CFDataRef) -> CFIndex;
+
+    pub fn CFDataGetTypeID() -> CFTypeID;
+}
new file mode 100644
--- /dev/null
+++ b/third_party/rust/core-foundation-sys-0.3.1/src/date.rs
@@ -0,0 +1,15 @@
+// Copyright 2013-2015 The Servo Project Developers. See the COPYRIGHT
+// file at the top-level directory of this distribution.
+//
+// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
+// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
+// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
+// option. This file may not be copied, modified, or distributed
+// except according to those terms.
+
+pub type CFTimeInterval = f64;
+pub type CFAbsoluteTime = CFTimeInterval;
+
+extern {
+    pub fn CFAbsoluteTimeGetCurrent() -> CFAbsoluteTime;
+}
new file mode 100644
--- /dev/null
+++ b/third_party/rust/core-foundation-sys-0.3.1/src/dictionary.rs
@@ -0,0 +1,79 @@
+// Copyright 2013-2015 The Servo Project Developers. See the COPYRIGHT
+// file at the top-level directory of this distribution.
+//
+// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
+// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
+// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
+// option. This file may not be copied, modified, or distributed
+// except according to those terms.
+
+use libc::{c_void};
+
+use base::{CFAllocatorRef, CFIndex, CFTypeID, Boolean};
+
+pub type CFDictionaryApplierFunction = extern "C" fn (key: *const c_void,
+                                                      value: *const c_void,
+                                                      context: *mut c_void);
+pub type CFDictionaryCopyDescriptionCallBack = *const u8;
+pub type CFDictionaryEqualCallBack = *const u8;
+pub type CFDictionaryHashCallBack = *const u8;
+pub type CFDictionaryReleaseCallBack = *const u8;
+pub type CFDictionaryRetainCallBack = *const u8;
+
+#[allow(dead_code)]
+#[repr(C)]
+#[derive(Clone, Copy)]
+pub struct CFDictionaryKeyCallBacks {
+    pub version: CFIndex,
+    pub retain: CFDictionaryRetainCallBack,
+    pub release: CFDictionaryReleaseCallBack,
+    pub copyDescription: CFDictionaryCopyDescriptionCallBack,
+    pub equal: CFDictionaryEqualCallBack,
+    pub hash: CFDictionaryHashCallBack
+}
+
+#[allow(dead_code)]
+#[repr(C)]
+#[derive(Clone, Copy)]
+pub struct CFDictionaryValueCallBacks {
+    pub version: CFIndex,
+    pub retain: CFDictionaryRetainCallBack,
+    pub release: CFDictionaryReleaseCallBack,
+    pub copyDescription: CFDictionaryCopyDescriptionCallBack,
+    pub equal: CFDictionaryEqualCallBack
+}
+
+#[repr(C)]
+pub struct __CFDictionary(c_void);
+
+pub type CFDictionaryRef = *const __CFDictionary;
+pub type CFMutableDictionaryRef = *const __CFDictionary;
+
+extern {
+    /*
+     * CFDictionary.h
+     */
+
+    pub static kCFTypeDictionaryKeyCallBacks: CFDictionaryKeyCallBacks;
+    pub static kCFTypeDictionaryValueCallBacks: CFDictionaryValueCallBacks;
+
+    pub fn CFDictionaryContainsKey(theDict: CFDictionaryRef, key: *const c_void) -> Boolean;
+    pub fn CFDictionaryCreate(allocator: CFAllocatorRef, keys: *const *const c_void, values: *const *const c_void,
+                              numValues: CFIndex, keyCallBacks: *const CFDictionaryKeyCallBacks,
+                              valueCallBacks: *const CFDictionaryValueCallBacks)
+                              -> CFDictionaryRef;
+    pub fn CFDictionaryGetCount(theDict: CFDictionaryRef) -> CFIndex;
+    pub fn CFDictionaryGetTypeID() -> CFTypeID;
+    pub fn CFDictionaryGetValueIfPresent(theDict: CFDictionaryRef, key: *const c_void, value: *mut *const c_void)
+                                         -> Boolean;
+    pub fn CFDictionaryApplyFunction(theDict: CFDictionaryRef,
+                                     applier: CFDictionaryApplierFunction,
+                                     context: *mut c_void);
+    pub fn CFDictionarySetValue(theDict: CFMutableDictionaryRef,
+                                key: *const c_void,
+                                value: *const c_void);
+    pub fn CFDictionaryGetKeysAndValues(theDict: CFDictionaryRef,
+                                        keys: *mut *const c_void,
+                                        values: *mut *const c_void);
+
+}
new file mode 100644
--- /dev/null
+++ b/third_party/rust/core-foundation-sys-0.3.1/src/error.rs
@@ -0,0 +1,32 @@
+// Copyright 2016 The Servo Project Developers. See the COPYRIGHT
+// file at the top-level directory of this distribution.
+//
+// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
+// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
+// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
+// option. This file may not be copied, modified, or distributed
+// except according to those terms.
+
+use libc::c_void;
+
+use base::{CFTypeID, CFIndex};
+use string::CFStringRef;
+
+#[repr(C)]
+pub struct __CFError(c_void);
+
+pub type CFErrorRef = *mut __CFError;
+
+extern "C" {
+    pub fn CFErrorGetTypeID() -> CFTypeID;
+
+    pub static kCFErrorDomainPOSIX: CFStringRef;
+    pub static kCFErrorDomainOSStatus: CFStringRef;
+    pub static kCFErrorDomainMach: CFStringRef;
+    pub static kCFErrorDomainCocoa: CFStringRef;
+
+    pub fn CFErrorGetDomain(err: CFErrorRef) -> CFStringRef;
+    pub fn CFErrorGetCode(err: CFErrorRef) -> CFIndex;
+
+    pub fn CFErrorCopyDescription(err: CFErrorRef) -> CFStringRef;
+}
new file mode 100644
--- /dev/null
+++ b/third_party/rust/core-foundation-sys-0.3.1/src/lib.rs
@@ -0,0 +1,26 @@
+// Copyright 2013-2015 The Servo Project Developers. See the COPYRIGHT
+// file at the top-level directory of this distribution.
+//
+// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
+// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
+// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
+// option. This file may not be copied, modified, or distributed
+// except according to those terms.
+#![allow(non_snake_case, non_camel_case_types, non_upper_case_globals, improper_ctypes)]
+
+extern crate libc;
+
+pub mod array;
+pub mod base;
+pub mod bundle;
+pub mod data;
+pub mod date;
+pub mod dictionary;
+pub mod error;
+pub mod messageport;
+pub mod number;
+pub mod propertylist;
+pub mod runloop;
+pub mod set;
+pub mod string;
+pub mod url;
new file mode 100644
--- /dev/null
+++ b/third_party/rust/core-foundation-sys-0.3.1/src/messageport.rs
@@ -0,0 +1,79 @@
+// Copyright 2013-2015 The Servo Project Developers. See the COPYRIGHT
+// file at the top-level directory of this distribution.
+//
+// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
+// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
+// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
+// option. This file may not be copied, modified, or distributed
+// except according to those terms.
+
+use libc::c_void;
+
+use base::{CFAllocatorRef, CFIndex, CFTypeID, Boolean};
+use data::CFDataRef;
+use date::CFTimeInterval;
+use runloop::CFRunLoopSourceRef;
+use string::CFStringRef;
+
+#[repr(C)]
+#[derive(Copy, Clone)]
+#[derive(Debug)]
+pub struct CFMessagePortContext {
+    pub version: CFIndex,
+    pub info: *mut c_void,
+    pub retain: Option<unsafe extern fn(info: *const c_void) -> *const c_void>,
+    pub release: Option<unsafe extern fn(info: *const c_void)>,
+    pub copyDescription: Option<unsafe extern fn(info: *const c_void)
+        -> CFStringRef>,
+}
+
+pub type CFMessagePortCallBack = Option<
+    unsafe extern fn(local: CFMessagePortRef,
+                     msgid: i32,
+                     data: CFDataRef,
+                     info: *mut c_void) -> CFDataRef>;
+
+pub type CFMessagePortInvalidationCallBack = Option<
+    unsafe extern "C" fn(ms: CFMessagePortRef, info: *mut c_void)>;
+
+#[repr(C)]
+pub struct __CFMessagePort(c_void);
+pub type CFMessagePortRef = *const __CFMessagePort;
+
+extern {
+    /*
+     * CFMessagePort.h
+     */
+    pub fn CFMessagePortGetTypeID() -> CFTypeID;
+    pub fn CFMessagePortCreateLocal(allocator: CFAllocatorRef,
+                                    name: CFStringRef,
+                                    callout: CFMessagePortCallBack,
+                                    context: *const CFMessagePortContext,
+                                    shouldFreeInfo: *mut Boolean)
+        -> CFMessagePortRef;
+    pub fn CFMessagePortCreateRemote(allocator: CFAllocatorRef,
+                                     name: CFStringRef) -> CFMessagePortRef;
+    pub fn CFMessagePortIsRemote(ms: CFMessagePortRef) -> Boolean;
+    pub fn CFMessagePortGetName(ms: CFMessagePortRef) -> CFStringRef;
+    pub fn CFMessagePortSetName(ms: CFMessagePortRef, newName: CFStringRef)
+        -> Boolean;
+    pub fn CFMessagePortGetContext(ms: CFMessagePortRef,
+                                   context: *mut CFMessagePortContext);
+    pub fn CFMessagePortInvalidate(ms: CFMessagePortRef);
+    pub fn CFMessagePortIsValid(ms: CFMessagePortRef) -> Boolean;
+    pub fn CFMessagePortGetInvalidationCallBack(ms: CFMessagePortRef)
+        -> CFMessagePortInvalidationCallBack;
+    pub fn CFMessagePortSetInvalidationCallBack(ms: CFMessagePortRef,
+                                                callout: CFMessagePortInvalidationCallBack);
+    pub fn CFMessagePortSendRequest(remote: CFMessagePortRef, msgid: i32,
+                                    data: CFDataRef,
+                                    sendTimeout: CFTimeInterval,
+                                    rcvTimeout: CFTimeInterval,
+                                    replyMode: CFStringRef,
+                                    returnData: *mut CFDataRef) -> i32;
+    pub fn CFMessagePortCreateRunLoopSource(allocator: CFAllocatorRef,
+                                            local: CFMessagePortRef,
+                                            order: CFIndex)
+        -> CFRunLoopSourceRef;
+    // CFMessagePortSetDispatchQueue
+}
new file mode 100644
--- /dev/null
+++ b/third_party/rust/core-foundation-sys-0.3.1/src/number.rs
@@ -0,0 +1,59 @@
+// Copyright 2013-2015 The Servo Project Developers. See the COPYRIGHT
+// file at the top-level directory of this distribution.
+//
+// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
+// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
+// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
+// option. This file may not be copied, modified, or distributed
+// except according to those terms.
+
+use libc::c_void;
+
+use base::{CFAllocatorRef, CFTypeID};
+
+#[repr(C)]
+pub struct __CFBoolean(c_void);
+
+pub type CFBooleanRef = *const __CFBoolean;
+
+pub type CFNumberType = u32;
+
+// members of enum CFNumberType
+// static kCFNumberSInt8Type:     CFNumberType = 1;
+// static kCFNumberSInt16Type:    CFNumberType = 2;
+pub static kCFNumberSInt32Type:    CFNumberType = 3;
+pub static kCFNumberSInt64Type:    CFNumberType = 4;
+// static kCFNumberFloat32Type:   CFNumberType = 5;
+pub static kCFNumberFloat64Type:   CFNumberType = 6;
+// static kCFNumberCharType:      CFNumberType = 7;
+// static kCFNumberShortType:     CFNumberType = 8;
+// static kCFNumberIntType:       CFNumberType = 9;
+// static kCFNumberLongType:      CFNumberType = 10;
+// static kCFNumberLongLongType:  CFNumberType = 11;
+// static kCFNumberFloatType:     CFNumberType = 12;
+// static kCFNumberDoubleType:    CFNumberType = 13;
+// static kCFNumberCFIndexType:   CFNumberType = 14;
+// static kCFNumberNSIntegerType: CFNumberType = 15;
+// static kCFNumberCGFloatType:   CFNumberType = 16;
+// static kCFNumberMaxType:       CFNumberType = 16;
+
+#[repr(C)]
+pub struct __CFNumber;
+
+pub type CFNumberRef = *const __CFNumber;
+
+extern {
+    /*
+     * CFNumber.h
+     */
+    pub static kCFBooleanTrue: CFBooleanRef;
+    pub static kCFBooleanFalse: CFBooleanRef;
+
+    pub fn CFBooleanGetTypeID() -> CFTypeID;
+    pub fn CFNumberCreate(allocator: CFAllocatorRef, theType: CFNumberType, valuePtr: *const c_void)
+                          -> CFNumberRef;
+    //fn CFNumberGetByteSize
+    pub fn CFNumberGetValue(number: CFNumberRef, theType: CFNumberType, valuePtr: *mut c_void) -> bool;
+    //fn CFNumberCompare
+    pub fn CFNumberGetTypeID() -> CFTypeID;
+}
new file mode 100644
--- /dev/null
+++ b/third_party/rust/core-foundation-sys-0.3.1/src/propertylist.rs
@@ -0,0 +1,37 @@
+use base::{CFAllocatorRef, CFIndex, CFOptionFlags, CFTypeRef};
+use data::CFDataRef;
+use error::CFErrorRef;
+
+pub type CFPropertyListRef = CFTypeRef;
+
+pub type CFPropertyListFormat = CFIndex;
+pub const kCFPropertyListOpenStepFormat: CFPropertyListFormat = 1;
+pub const kCFPropertyListXMLFormat_v1_0: CFPropertyListFormat = 100;
+pub const kCFPropertyListBinaryFormat_v1_0: CFPropertyListFormat = 200;
+
+pub type CFPropertyListMutabilityOptions = CFOptionFlags;
+pub const kCFPropertyListImmutable: CFPropertyListMutabilityOptions = 0;
+pub const kCFPropertyListMutableContainers: CFPropertyListMutabilityOptions = 1;
+pub const kCFPropertyListMutableContainersAndLeaves: CFPropertyListMutabilityOptions = 2;
+
+extern "C" {
+    // CFPropertyList.h
+    //
+
+    // fn CFPropertyListCreateDeepCopy
+    // fn CFPropertyListIsValid
+    pub fn CFPropertyListCreateWithData(allocator: CFAllocatorRef,
+                                        data: CFDataRef,
+                                        options: CFPropertyListMutabilityOptions,
+                                        format: *mut CFPropertyListFormat,
+                                        error: *mut CFErrorRef)
+                                        -> CFPropertyListRef;
+    // fn CFPropertyListCreateWithStream
+    // fn CFPropertyListWrite
+    pub fn CFPropertyListCreateData(allocator: CFAllocatorRef,
+                                    propertyList: CFPropertyListRef,
+                                    format: CFPropertyListFormat,
+                                    options: CFOptionFlags,
+                                    error: *mut CFErrorRef)
+                                    -> CFDataRef;
+}
new file mode 100644
--- /dev/null
+++ b/third_party/rust/core-foundation-sys-0.3.1/src/runloop.rs
@@ -0,0 +1,164 @@
+// Copyright 2013-2015 The Servo Project Developers. See the COPYRIGHT
+// file at the top-level directory of this distribution.
+//
+// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
+// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
+// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
+// option. This file may not be copied, modified, or distributed
+// except according to those terms.
+
+use libc::c_void;
+
+use array::CFArrayRef;
+use base::{Boolean, CFIndex, CFTypeID, CFAllocatorRef, CFOptionFlags, CFHashCode, mach_port_t};
+use date::{CFAbsoluteTime, CFTimeInterval};
+use string::CFStringRef;
+
+#[repr(C)]
+pub struct __CFRunLoop(c_void);
+
+pub type CFRunLoopRef = *const __CFRunLoop;
+
+#[repr(C)]
+pub struct __CFRunLoopSource(c_void);
+
+pub type CFRunLoopSourceRef = *const __CFRunLoopSource;
+
+#[repr(C)]
+pub struct __CFRunLoopObserver(c_void);
+
+pub type CFRunLoopObserverRef = *const __CFRunLoopObserver;
+
+// Reasons for CFRunLoopRunInMode() to Return
+pub const kCFRunLoopRunFinished: i32      = 1;
+pub const kCFRunLoopRunStopped: i32       = 2;
+pub const kCFRunLoopRunTimedOut: i32      = 3;
+pub const kCFRunLoopRunHandledSource: i32 = 4;
+
+// Run Loop Observer Activities
+//typedef CF_OPTIONS(CFOptionFlags, CFRunLoopActivity) {
+pub type CFRunLoopActivity = CFOptionFlags;
+pub const kCFRunLoopEntry: CFOptionFlags         = 1 << 0;
+pub const kCFRunLoopBeforeTimers: CFOptionFlags  = 1 << 1;
+pub const kCFRunLoopBeforeSources: CFOptionFlags = 1 << 2;
+pub const kCFRunLoopBeforeWaiting: CFOptionFlags = 1 << 5;
+pub const kCFRunLoopAfterWaiting: CFOptionFlags  = 1 << 6;
+pub const kCFRunLoopExit: CFOptionFlags          = 1 << 7;
+pub const kCFRunLoopAllActivities: CFOptionFlags = 0x0FFFFFFF;
+
+#[repr(C)]
+pub struct CFRunLoopSourceContext {
+    pub version: CFIndex,
+    pub info: *mut c_void,
+    pub retain: extern "C" fn (info: *const c_void) -> *const c_void,
+    pub release: extern "C" fn (info: *const c_void),
+    pub copyDescription: extern "C" fn (info: *const c_void) -> CFStringRef,
+    pub equal: extern "C" fn (info1: *const c_void, info2: *const c_void) -> Boolean,
+    pub hash: extern "C" fn (info: *const c_void) -> CFHashCode,
+    pub schedule: extern "C" fn (info: *const c_void, rl: CFRunLoopRef, mode: CFStringRef),
+    pub cancel: extern "C" fn (info: *const c_void, rl: CFRunLoopRef, mode: CFStringRef),
+    pub perform: extern "C" fn (info: *const c_void),
+}
+
+#[repr(C)]
+pub struct CFRunLoopSourceContext1 {
+    pub version: CFIndex,
+    pub info: *mut c_void,
+    pub retain: extern "C" fn (info: *const c_void) -> *const c_void,
+    pub release: extern "C" fn (info: *const c_void),
+    pub copyDescription: extern "C" fn (info: *const c_void) -> CFStringRef,
+    pub equal: extern "C" fn (info1: *const c_void, info2: *const c_void) -> Boolean,
+    pub hash: extern "C" fn (info: *const c_void) -> CFHashCode,
+    // note that the following two fields are platform dependent in the C header, the ones here are for OS X
+    pub getPort: extern "C" fn (info: *mut c_void) -> mach_port_t,
+    pub perform: extern "C" fn (msg: *mut c_void, size: CFIndex, allocator: CFAllocatorRef, info: *mut c_void) -> *mut c_void,
+}
+
+#[repr(C)]
+pub struct CFRunLoopObserverContext {
+    pub version: CFIndex,
+    pub info: *mut c_void,
+    pub retain: extern "C" fn (info: *const c_void) -> *const c_void,
+    pub release: extern "C" fn (info: *const c_void),
+    pub copyDescription: extern "C" fn (info: *const c_void) -> CFStringRef,
+}
+
+pub type CFRunLoopObserverCallBack = extern "C" fn (observer: CFRunLoopObserverRef, activity: CFRunLoopActivity, info: *mut c_void);
+
+#[repr(C)]
+pub struct CFRunLoopTimerContext {
+    pub version: CFIndex,
+    pub info: *mut c_void,
+    pub retain: extern "C" fn (info: *const c_void) -> *const c_void,
+    pub release: extern "C" fn (info: *const c_void),
+    pub copyDescription: extern "C" fn (info: *const c_void) -> CFStringRef,
+}
+
+pub type CFRunLoopTimerCallBack = extern "C" fn (timer: CFRunLoopTimerRef, info: *mut c_void);
+
+#[repr(C)]
+pub struct __CFRunLoopTimer;
+
+pub type CFRunLoopTimerRef = *const __CFRunLoopTimer;
+
+extern {
+    /*
+     * CFRunLoop.h
+     */
+    pub static kCFRunLoopDefaultMode: CFStringRef;
+    pub static kCFRunLoopCommonModes: CFStringRef;
+    pub fn CFRunLoopGetTypeID() -> CFTypeID;
+    pub fn CFRunLoopGetCurrent() -> CFRunLoopRef;
+    pub fn CFRunLoopGetMain() -> CFRunLoopRef;
+    pub fn CFRunLoopCopyCurrentMode(rl: CFRunLoopRef) -> CFStringRef;
+    pub fn CFRunLoopCopyAllModes(rl: CFRunLoopRef) -> CFArrayRef;
+    pub fn CFRunLoopAddCommonMode(rl: CFRunLoopRef, mode: CFStringRef);
+    pub fn CFRunLoopGetNextTimerFireDate(rl: CFRunLoopRef, mode: CFStringRef) -> CFAbsoluteTime;
+    pub fn CFRunLoopRun();
+    pub fn CFRunLoopRunInMode(mode: CFStringRef, seconds: CFTimeInterval, returnAfterSourceHandled: Boolean) -> i32;
+    pub fn CFRunLoopIsWaiting(rl: CFRunLoopRef) -> Boolean;
+    pub fn CFRunLoopWakeUp(rl: CFRunLoopRef);
+    pub fn CFRunLoopStop(rl: CFRunLoopRef);
+    // fn CFRunLoopPerformBlock(rl: CFRunLoopRef, mode: CFTypeRef, block: void (^)(void));
+    pub fn CFRunLoopContainsSource(rl: CFRunLoopRef, source: CFRunLoopSourceRef, mode: CFStringRef) -> Boolean;
+    pub fn CFRunLoopAddSource(rl: CFRunLoopRef, source: CFRunLoopSourceRef, mode: CFStringRef);
+    pub fn CFRunLoopRemoveSource(rl: CFRunLoopRef, source: CFRunLoopSourceRef, mode: CFStringRef);
+    pub fn CFRunLoopContainsObserver(rl: CFRunLoopRef, observer: CFRunLoopObserverRef, mode: CFStringRef) -> Boolean;
+    pub fn CFRunLoopAddObserver(rl: CFRunLoopRef, observer: CFRunLoopObserverRef, mode: CFStringRef);
+    pub fn CFRunLoopRemoveObserver(rl: CFRunLoopRef, observer: CFRunLoopObserverRef, mode: CFStringRef);
+    pub fn CFRunLoopContainsTimer(rl: CFRunLoopRef, timer: CFRunLoopTimerRef, mode: CFStringRef) -> Boolean;
+    pub fn CFRunLoopAddTimer(rl: CFRunLoopRef, timer: CFRunLoopTimerRef, mode: CFStringRef);
+    pub fn CFRunLoopRemoveTimer(rl: CFRunLoopRef, timer: CFRunLoopTimerRef, mode: CFStringRef);
+
+    pub fn CFRunLoopSourceGetTypeID() -> CFTypeID;
+    pub fn CFRunLoopSourceCreate(allocator: CFAllocatorRef, order: CFIndex, context: *mut CFRunLoopSourceContext) -> CFRunLoopSourceRef;
+    pub fn CFRunLoopSourceGetOrder(source: CFRunLoopSourceRef) -> CFIndex;
+    pub fn CFRunLoopSourceInvalidate(source: CFRunLoopSourceRef);
+    pub fn CFRunLoopSourceIsValid(source: CFRunLoopSourceRef) -> Boolean;
+    pub fn CFRunLoopSourceGetContext(source: CFRunLoopSourceRef, context: *mut CFRunLoopSourceContext);
+    pub fn CFRunLoopSourceSignal(source: CFRunLoopSourceRef);
+
+    pub fn CFRunLoopObserverGetTypeID() -> CFTypeID;
+    pub fn CFRunLoopObserverCreate(allocator: CFAllocatorRef, activities: CFOptionFlags, repeats: Boolean, order: CFIndex, callout: CFRunLoopObserverCallBack, context: *mut CFRunLoopObserverContext) -> CFRunLoopObserverRef;
+    // fn CFRunLoopObserverCreateWithHandler(allocator: CFAllocatorRef, activities: CFOptionFlags, repeats: Boolean, order: CFIndex, block: void (^) (CFRunLoopObserverRef observer, CFRunLoopActivity activity)) -> CFRunLoopObserverRef;
+    pub fn CFRunLoopObserverGetActivities(observer: CFRunLoopObserverRef) -> CFOptionFlags;
+    pub fn CFRunLoopObserverDoesRepeat(observer: CFRunLoopObserverRef) -> Boolean;
+    pub fn CFRunLoopObserverGetOrder(observer: CFRunLoopObserverRef) -> CFIndex;
+    pub fn CFRunLoopObserverInvalidate(observer: CFRunLoopObserverRef);
+    pub fn CFRunLoopObserverIsValid(observer: CFRunLoopObserverRef) -> Boolean;
+    pub fn CFRunLoopObserverGetContext(observer: CFRunLoopObserverRef, context: *mut CFRunLoopObserverContext);
+
+    pub fn CFRunLoopTimerGetTypeID() -> CFTypeID;
+    pub fn CFRunLoopTimerCreate(allocator: CFAllocatorRef, fireDate: CFAbsoluteTime, interval: CFTimeInterval, flags: CFOptionFlags, order: CFIndex, callout: CFRunLoopTimerCallBack, context: *mut CFRunLoopTimerContext) -> CFRunLoopTimerRef;
+    // fn CFRunLoopTimerCreateWithHandler(allocator: CFAllocatorRef, fireDate: CFAbsoluteTime, interval: CFTimeInterval, flags: CFOptionFlags, order: CFIndex, block: void (^) (CFRunLoopTimerRef timer)) -> CFRunLoopTimerRef;
+    pub fn CFRunLoopTimerGetNextFireDate(timer: CFRunLoopTimerRef) -> CFAbsoluteTime;
+    pub fn CFRunLoopTimerSetNextFireDate(timer: CFRunLoopTimerRef, fireDate: CFAbsoluteTime);
+    pub fn CFRunLoopTimerGetInterval(timer: CFRunLoopTimerRef) -> CFTimeInterval;
+    pub fn CFRunLoopTimerDoesRepeat(timer: CFRunLoopTimerRef) -> Boolean;
+    pub fn CFRunLoopTimerGetOrder(timer: CFRunLoopTimerRef) -> CFIndex;
+    pub fn CFRunLoopTimerInvalidate(timer: CFRunLoopTimerRef);
+    pub fn CFRunLoopTimerIsValid(timer: CFRunLoopTimerRef) -> Boolean;
+    pub fn CFRunLoopTimerGetContext(timer: CFRunLoopTimerRef, context: *mut CFRunLoopTimerContext);
+    pub fn CFRunLoopTimerGetTolerance(timer: CFRunLoopTimerRef) -> CFTimeInterval;
+    pub fn CFRunLoopTimerSetTolerance(timer: CFRunLoopTimerRef, tolerance: CFTimeInterval);
+}
new file mode 100644
--- /dev/null
+++ b/third_party/rust/core-foundation-sys-0.3.1/src/set.rs
@@ -0,0 +1,52 @@
+// Copyright 2013-2015 The Servo Project Developers. See the COPYRIGHT
+// file at the top-level directory of this distribution.
+//
+// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
+// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
+// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
+// option. This file may not be copied, modified, or distributed
+// except according to those terms.
+
+use libc::c_void;
+
+use base::{CFAllocatorRef, CFIndex, CFTypeID};
+
+pub type CFSetRetainCallBack = *const u8;
+pub type CFSetReleaseCallBack = *const u8;
+pub type CFSetCopyDescriptionCallBack = *const u8;
+pub type CFSetEqualCallBack = *const u8;
+pub type CFSetHashCallBack = *const u8;
+
+#[repr(C)]
+#[derive(Clone, Copy)]
+pub struct CFSetCallBacks {
+    pub version: CFIndex,
+    pub retain: CFSetRetainCallBack,
+    pub release: CFSetReleaseCallBack,
+    pub copyDescription: CFSetCopyDescriptionCallBack,
+    pub equal: CFSetEqualCallBack,
+    pub hash: CFSetHashCallBack,
+}
+
+#[repr(C)]
+pub struct __CFSet(c_void);
+
+pub type CFSetRef = *const __CFSet;
+
+extern {
+    /*
+     * CFSet.h
+     */
+
+    pub static kCFTypeSetCallBacks: CFSetCallBacks;
+
+    /* Creating Sets */
+    pub fn CFSetCreate(allocator: CFAllocatorRef, values: *const *const c_void, numValues: CFIndex,
+                       callBacks: *const CFSetCallBacks) -> CFSetRef;
+
+    /* Applying a Function to Set Members */
+    //fn CFSetApplyFunction
+
+    pub fn CFSetGetTypeID() -> CFTypeID;
+}
+
new file mode 100644
--- /dev/null
+++ b/third_party/rust/core-foundation-sys-0.3.1/src/string.rs
@@ -0,0 +1,320 @@
+// Copyright 2013-2015 The Servo Project Developers. See the COPYRIGHT
+// file at the top-level directory of this distribution.
+//
+// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
+// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
+// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
+// option. This file may not be copied, modified, or distributed
+// except according to those terms.
+
+use libc::{c_char, c_ushort, c_void};
+
+use base::{Boolean, CFOptionFlags, CFIndex, CFAllocatorRef, CFRange, CFTypeID};
+
+pub type UniChar = c_ushort;
+
+// CFString.h
+
+pub type CFStringCompareFlags = CFOptionFlags;
+//static kCFCompareCaseInsensitive: CFStringCompareFlags = 1;
+//static kCFCompareBackwards: CFStringCompareFlags = 4;
+//static kCFCompareAnchored: CFStringCompareFlags = 8;
+//static kCFCompareNonliteral: CFStringCompareFlags = 16;
+//static kCFCompareLocalized: CFStringCompareFlags = 32;
+//static kCFCompareNumerically: CFStringCompareFlags = 64;
+//static kCFCompareDiacriticInsensitive: CFStringCompareFlags = 128;
+//static kCFCompareWidthInsensitive: CFStringCompareFlags = 256;
+//static kCFCompareForcedOrdering: CFStringCompareFlags = 512;
+
+pub type CFStringEncoding = u32;
+
+// OS X built-in encodings.
+
+//static kCFStringEncodingMacRoman: CFStringEncoding = 0;
+//static kCFStringEncodingWindowsLatin1: CFStringEncoding = 0x0500;
+//static kCFStringEncodingISOLatin1: CFStringEncoding = 0x0201;
+//static kCFStringEncodingNextStepLatin: CFStringEncoding = 0x0B01;
+//static kCFStringEncodingASCII: CFStringEncoding = 0x0600;
+//static kCFStringEncodingUnicode: CFStringEncoding = 0x0100;
+pub static kCFStringEncodingUTF8: CFStringEncoding = 0x08000100;
+//static kCFStringEncodingNonLossyASCII: CFStringEncoding = 0x0BFF;
+
+//static kCFStringEncodingUTF16: CFStringEncoding = 0x0100;
+//static kCFStringEncodingUTF16BE: CFStringEncoding = 0x10000100;
+//static kCFStringEncodingUTF16LE: CFStringEncoding = 0x14000100;
+//static kCFStringEncodingUTF32: CFStringEncoding = 0x0c000100;
+//static kCFStringEncodingUTF32BE: CFStringEncoding = 0x18000100;
+//static kCFStringEncodingUTF32LE: CFStringEncoding = 0x1c000100;
+
+
+// CFStringEncodingExt.h
+
+pub type CFStringEncodings = CFIndex;
+
+// External encodings, except those defined above.
+// Defined above: kCFStringEncodingMacRoman = 0
+//static kCFStringEncodingMacJapanese: CFStringEncoding = 1;
+//static kCFStringEncodingMacChineseTrad: CFStringEncoding = 2;
+//static kCFStringEncodingMacKorean: CFStringEncoding = 3;
+//static kCFStringEncodingMacArabic: CFStringEncoding = 4;
+//static kCFStringEncodingMacHebrew: CFStringEncoding = 5;
+//static kCFStringEncodingMacGreek: CFStringEncoding = 6;
+//static kCFStringEncodingMacCyrillic: CFStringEncoding = 7;
+//static kCFStringEncodingMacDevanagari: CFStringEncoding = 9;
+//static kCFStringEncodingMacGurmukhi: CFStringEncoding = 10;
+//static kCFStringEncodingMacGujarati: CFStringEncoding = 11;
+//static kCFStringEncodingMacOriya: CFStringEncoding = 12;
+//static kCFStringEncodingMacBengali: CFStringEncoding = 13;
+//static kCFStringEncodingMacTamil: CFStringEncoding = 14;
+//static kCFStringEncodingMacTelugu: CFStringEncoding = 15;
+//static kCFStringEncodingMacKannada: CFStringEncoding = 16;
+//static kCFStringEncodingMacMalayalam: CFStringEncoding = 17;
+//static kCFStringEncodingMacSinhalese: CFStringEncoding = 18;
+//static kCFStringEncodingMacBurmese: CFStringEncoding = 19;
+//static kCFStringEncodingMacKhmer: CFStringEncoding = 20;
+//static kCFStringEncodingMacThai: CFStringEncoding = 21;
+//static kCFStringEncodingMacLaotian: CFStringEncoding = 22;
+//static kCFStringEncodingMacGeorgian: CFStringEncoding = 23;
+//static kCFStringEncodingMacArmenian: CFStringEncoding = 24;
+//static kCFStringEncodingMacChineseSimp: CFStringEncoding = 25;
+//static kCFStringEncodingMacTibetan: CFStringEncoding = 26;
+//static kCFStringEncodingMacMongolian: CFStringEncoding = 27;
+//static kCFStringEncodingMacEthiopic: CFStringEncoding = 28;
+//static kCFStringEncodingMacCentralEurRoman: CFStringEncoding = 29;
+//static kCFStringEncodingMacVietnamese: CFStringEncoding = 30;
+//static kCFStringEncodingMacExtArabic: CFStringEncoding = 31;
+//static kCFStringEncodingMacSymbol: CFStringEncoding = 33;
+//static kCFStringEncodingMacDingbats: CFStringEncoding = 34;
+//static kCFStringEncodingMacTurkish: CFStringEncoding = 35;
+//static kCFStringEncodingMacCroatian: CFStringEncoding = 36;
+//static kCFStringEncodingMacIcelandic: CFStringEncoding = 37;
+//static kCFStringEncodingMacRomanian: CFStringEncoding = 38;
+//static kCFStringEncodingMacCeltic: CFStringEncoding = 39;
+//static kCFStringEncodingMacGaelic: CFStringEncoding = 40;
+//static kCFStringEncodingMacFarsi: CFStringEncoding = 0x8C;
+//static kCFStringEncodingMacUkrainian: CFStringEncoding = 0x98;
+//static kCFStringEncodingMacInuit: CFStringEncoding = 0xEC;
+//static kCFStringEncodingMacVT100: CFStringEncoding = 0xFC;
+//static kCFStringEncodingMacHFS: CFStringEncoding = 0xFF;
+// Defined above: kCFStringEncodingISOLatin1 = 0x0201
+//static kCFStringEncodingISOLatin2: CFStringEncoding = 0x0202;
+//static kCFStringEncodingISOLatin3: CFStringEncoding = 0x0203;
+//static kCFStringEncodingISOLatin4: CFStringEncoding = 0x0204;
+//static kCFStringEncodingISOLatinCyrillic: CFStringEncoding = 0x0205;
+//static kCFStringEncodingISOLatinArabic: CFStringEncoding = 0x0206;
+//static kCFStringEncodingISOLatinGreek: CFStringEncoding = 0x0207;
+//static kCFStringEncodingISOLatinHebrew: CFStringEncoding = 0x0208;
+//static kCFStringEncodingISOLatin5: CFStringEncoding = 0x0209;
+//static kCFStringEncodingISOLatin6: CFStringEncoding = 0x020A;
+//static kCFStringEncodingISOLatinThai: CFStringEncoding = 0x020B;
+//static kCFStringEncodingISOLatin7: CFStringEncoding = 0x020D;
+//static kCFStringEncodingISOLatin8: CFStringEncoding = 0x020E;
+//static kCFStringEncodingISOLatin9: CFStringEncoding = 0x020F;
+//static kCFStringEncodingISOLatin10: CFStringEncoding = 0x0210;
+//static kCFStringEncodingDOSLatinUS: CFStringEncoding = 0x0400;
+//static kCFStringEncodingDOSGreek: CFStringEncoding = 0x0405;
+//static kCFStringEncodingDOSBalticRim: CFStringEncoding = 0x0406;
+//static kCFStringEncodingDOSLatin1: CFStringEncoding = 0x0410;
+//static kCFStringEncodingDOSGreek1: CFStringEncoding = 0x0411;
+//static kCFStringEncodingDOSLatin2: CFStringEncoding = 0x0412;
+//static kCFStringEncodingDOSCyrillic: CFStringEncoding = 0x0413;
+//static kCFStringEncodingDOSTurkish: CFStringEncoding = 0x0414;
+//static kCFStringEncodingDOSPortuguese: CFStringEncoding = 0x0415;
+//static kCFStringEncodingDOSIcelandic: CFStringEncoding = 0x0416;
+//static kCFStringEncodingDOSHebrew: CFStringEncoding = 0x0417;
+//static kCFStringEncodingDOSCanadianFrench: CFStringEncoding = 0x0418;
+//static kCFStringEncodingDOSArabic: CFStringEncoding = 0x0419;
+//static kCFStringEncodingDOSNordic: CFStringEncoding = 0x041A;
+//static kCFStringEncodingDOSRussian: CFStringEncoding = 0x041B;
+//static kCFStringEncodingDOSGreek2: CFStringEncoding = 0x041C;
+//static kCFStringEncodingDOSThai: CFStringEncoding = 0x041D;
+//static kCFStringEncodingDOSJapanese: CFStringEncoding = 0x0420;
+//static kCFStringEncodingDOSChineseSimplif: CFStringEncoding = 0x0421;
+//static kCFStringEncodingDOSKorean: CFStringEncoding = 0x0422;
+//static kCFStringEncodingDOSChineseTrad: CFStringEncoding = 0x0423;
+// Defined above: kCFStringEncodingWindowsLatin1 = 0x0500
+//static kCFStringEncodingWindowsLatin2: CFStringEncoding = 0x0501;
+//static kCFStringEncodingWindowsCyrillic: CFStringEncoding = 0x0502;
+//static kCFStringEncodingWindowsGreek: CFStringEncoding = 0x0503;
+//static kCFStringEncodingWindowsLatin5: CFStringEncoding = 0x0504;
+//static kCFStringEncodingWindowsHebrew: CFStringEncoding = 0x0505;
+//static kCFStringEncodingWindowsArabic: CFStringEncoding = 0x0506;
+//static kCFStringEncodingWindowsBalticRim: CFStringEncoding = 0x0507;
+//static kCFStringEncodingWindowsVietnamese: CFStringEncoding = 0x0508;
+//static kCFStringEncodingWindowsKoreanJohab: CFStringEncoding = 0x0510;
+// Defined above: kCFStringEncodingASCII = 0x0600
+//static kCFStringEncodingANSEL: CFStringEncoding = 0x0601;
+//static kCFStringEncodingJIS_X0201_76: CFStringEncoding = 0x0620;
+//static kCFStringEncodingJIS_X0208_83: CFStringEncoding = 0x0621;
+//static kCFStringEncodingJIS_X0208_90: CFStringEncoding = 0x0622;
+//static kCFStringEncodingJIS_X0212_90: CFStringEncoding = 0x0623;
+//static kCFStringEncodingJIS_C6226_78: CFStringEncoding = 0x0624;
+//static kCFStringEncodingShiftJIS_X0213: CFStringEncoding = 0x0628;
+//static kCFStringEncodingShiftJIS_X0213_MenKuTen: CFStringEncoding = 0x0629;
+//static kCFStringEncodingGB_2312_80: CFStringEncoding = 0x0630;
+//static kCFStringEncodingGBK_95: CFStringEncoding = 0x0631;
+//static kCFStringEncodingGB_18030_2000: CFStringEncoding = 0x0632;
+//static kCFStringEncodingKSC_5601_87: CFStringEncoding = 0x0640;
+//static kCFStringEncodingKSC_5601_92_Johab: CFStringEncoding = 0x0641;
+//static kCFStringEncodingCNS_11643_92_P1: CFStringEncoding = 0x0651;
+//static kCFStringEncodingCNS_11643_92_P2: CFStringEncoding = 0x0652;
+//static kCFStringEncodingCNS_11643_92_P3: CFStringEncoding = 0x0653;
+//static kCFStringEncodingISO_2022_JP: CFStringEncoding = 0x0820;
+//static kCFStringEncodingISO_2022_JP_2: CFStringEncoding = 0x0821;
+//static kCFStringEncodingISO_2022_JP_1: CFStringEncoding = 0x0822;
+//static kCFStringEncodingISO_2022_JP_3: CFStringEncoding = 0x0823;
+//static kCFStringEncodingISO_2022_CN: CFStringEncoding = 0x0830;
+//static kCFStringEncodingISO_2022_CN_EXT: CFStringEncoding = 0x0831;
+//static kCFStringEncodingISO_2022_KR: CFStringEncoding = 0x0840;
+//static kCFStringEncodingEUC_JP: CFStringEncoding = 0x0920;
+//static kCFStringEncodingEUC_CN: CFStringEncoding = 0x0930;
+//static kCFStringEncodingEUC_TW: CFStringEncoding = 0x0931;
+//static kCFStringEncodingEUC_KR: CFStringEncoding = 0x0940;
+//static kCFStringEncodingShiftJIS: CFStringEncoding = 0x0A01;
+//static kCFStringEncodingKOI8_R: CFStringEncoding = 0x0A02;
+//static kCFStringEncodingBig5: CFStringEncoding = 0x0A03;
+//static kCFStringEncodingMacRomanLatin1: CFStringEncoding = 0x0A04;
+//static kCFStringEncodingHZ_GB_2312: CFStringEncoding = 0x0A05;
+//static kCFStringEncodingBig5_HKSCS_1999: CFStringEncoding = 0x0A06;
+//static kCFStringEncodingVISCII: CFStringEncoding = 0x0A07;
+//static kCFStringEncodingKOI8_U: CFStringEncoding = 0x0A08;
+//static kCFStringEncodingBig5_E: CFStringEncoding = 0x0A09;
+// Defined above: kCFStringEncodingNextStepLatin = 0x0B01
+//static kCFStringEncodingNextStepJapanese: CFStringEncoding = 0x0B02;
+//static kCFStringEncodingEBCDIC_US: CFStringEncoding = 0x0C01;
+//static kCFStringEncodingEBCDIC_CP037: CFStringEncoding = 0x0C02;
+//static kCFStringEncodingUTF7: CFStringEncoding = 0x04000100;
+//static kCFStringEncodingUTF7_IMAP: CFStringEncoding = 0x0A10;
+//static kCFStringEncodingShiftJIS_X0213_00: CFStringEncoding = 0x0628; /* Deprecated */
+
+#[repr(C)]
+pub struct __CFString(c_void);
+
+pub type CFStringRef = *const __CFString;
+
+extern {
+    /*
+     * CFString.h
+     */
+
+    // N.B. organized according to "Functions by task" in docs
+
+    /* Creating a CFString */
+    //fn CFSTR
+    //fn CFStringCreateArrayBySeparatingStrings
+    //fn CFStringCreateByCombiningStrings
+    //fn CFStringCreateCopy
+    //fn CFStringCreateFromExternalRepresentation
+    pub fn CFStringCreateWithBytes(alloc: CFAllocatorRef,
+                                   bytes: *const u8,
+                                   numBytes: CFIndex,
+                                   encoding: CFStringEncoding,
+                                   isExternalRepresentation: Boolean,
+                                   contentsDeallocator: CFAllocatorRef)
+                                   -> CFStringRef;
+    pub fn CFStringCreateWithBytesNoCopy(alloc: CFAllocatorRef,
+                                         bytes: *const u8,
+                                         numBytes: CFIndex,
+                                         encoding: CFStringEncoding,
+                                         isExternalRepresentation: Boolean,
+                                         contentsDeallocator: CFAllocatorRef)
+                                         -> CFStringRef;
+    //fn CFStringCreateWithCharacters
+    //fn CFStringCreateWithCharactersNoCopy
+    pub fn CFStringCreateWithCString(alloc: CFAllocatorRef,
+                                     cStr: *const c_char,
+                                     encoding: CFStringEncoding)
+                                     -> CFStringRef;
+    //fn CFStringCreateWithCStringNoCopy
+    //fn CFStringCreateWithFormat
+    //fn CFStringCreateWithFormatAndArguments
+    //fn CFStringCreateWithPascalString
+    //fn CFStringCreateWithPascalStringNoCopy
+    //fn CFStringCreateWithSubstring
+
+    /* Searching Strings */
+    //fn CFStringCreateArrayWithFindResults
+    //fn CFStringFind
+    //fn CFStringFindCharacterFromSet
+    //fn CFStringFindWithOptions
+    //fn CFStringFindWithOptionsAndLocale
+    //fn CFStringGetLineBounds
+
+    /* Comparing Strings */
+    //fn CFStringCompare
+    //fn CFStringCompareWithOptions
+    //fn CFStringCompareWithOptionsAndLocale
+    //fn CFStringHasPrefix
+    //fn CFStringHasSuffix
+
+    /* Accessing Characters */
+    //fn CFStringCreateExternalRepresentation
+    pub fn CFStringGetBytes(theString: CFStringRef,
+                            range: CFRange,
+                            encoding: CFStringEncoding,
+                            lossByte: u8,
+                            isExternalRepresentation: Boolean,
+                            buffer: *mut u8,
+                            maxBufLen: CFIndex,
+                            usedBufLen: *mut CFIndex)
+                            -> CFIndex;
+    //fn CFStringGetCharacterAtIndex
+    //fn CFStringGetCharacters
+    //fn CFStringGetCharactersPtr
+    //fn CFStringGetCharacterFromInlineBuffer
+    pub fn CFStringGetCString(theString: CFStringRef,
+                              buffer: *mut c_char,
+                              bufferSize: CFIndex,
+                              encoding: CFStringEncoding)
+                              -> Boolean;
+    pub fn CFStringGetCStringPtr(theString: CFStringRef,
+                                 encoding: CFStringEncoding)
+                                 -> *const c_char;
+    pub fn CFStringGetLength(theString: CFStringRef) -> CFIndex;
+    //fn CFStringGetPascalString
+    //fn CFStringGetPascalStringPtr
+    //fn CFStringGetRangeOfComposedCharactersAtIndex
+    //fn CFStringInitInlineBuffer
+
+    /* Working With Hyphenation */
+    //fn CFStringGetHyphenationLocationBeforeIndex
+    //fn CFStringIsHyphenationAvailableForLocale
+
+    /* Working With Encodings */
+    //fn CFStringConvertEncodingToIANACharSetName
+    //fn CFStringConvertEncodingToNSStringEncoding
+    //fn CFStringConvertEncodingToWindowsCodepage
+    //fn CFStringConvertIANACharSetNameToEncoding
+    //fn CFStringConvertNSStringEncodingToEncoding
+    //fn CFStringConvertWindowsCodepageToEncoding
+    //fn CFStringGetFastestEncoding
+    //fn CFStringGetListOfAvailableEncodings
+    //fn CFStringGetMaximumSizeForEncoding
+    //fn CFStringGetMostCompatibleMacStringEncoding
+    //fn CFStringGetNameOfEncoding
+    //fn CFStringGetSmallestEncoding
+    //fn CFStringGetSystemEncoding
+    //fn CFStringIsEncodingAvailable
+
+    /* Getting Numeric Values */
+    //fn CFStringGetDoubleValue
+    //fn CFStringGetIntValue
+
+    /* Getting String Properties */
+    //fn CFShowStr
+    pub fn CFStringGetTypeID() -> CFTypeID;
+
+    /* String File System Representations */
+    //fn CFStringCreateWithFileSystemRepresentation
+    //fn CFStringGetFileSystemRepresentation
+    //fn CFStringGetMaximumSizeOfFileSystemRepresentation
+
+    /* Getting Paragraph Bounds */
+    //fn CFStringGetParagraphBounds
+
+    /* Managing Surrogates */
+    //fn CFStringGetLongCharacterForSurrogatePair
+    //fn CFStringGetSurrogatePairForLongCharacter
+    //fn CFStringIsSurrogateHighCharacter
+    //fn CFStringIsSurrogateLowCharacter
+}
new file mode 100644
--- /dev/null
+++ b/third_party/rust/core-foundation-sys-0.3.1/src/url.rs
@@ -0,0 +1,156 @@
+// Copyright 2013-2015 The Servo Project Developers. See the COPYRIGHT
+// file at the top-level directory of this distribution.
+//
+// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
+// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
+// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
+// option. This file may not be copied, modified, or distributed
+// except according to those terms.
+use libc::c_void;
+
+use base::{CFOptionFlags, CFIndex, CFAllocatorRef, Boolean, CFTypeID, SInt32};
+use string::CFStringRef;
+
+#[repr(C)]
+pub struct __CFURL(c_void);
+
+pub type CFURLRef = *const __CFURL;
+
+pub type CFURLBookmarkCreationOptions = CFOptionFlags;
+
+pub type CFURLPathStyle = CFIndex;
+
+/* typedef CF_ENUM(CFIndex, CFURLPathStyle) */
+pub const kCFURLPOSIXPathStyle: CFURLPathStyle   = 0;
+pub const kCFURLHFSPathStyle: CFURLPathStyle     = 1;
+pub const kCFURLWindowsPathStyle: CFURLPathStyle = 2;
+
+// static kCFURLBookmarkCreationPreferFileIDResolutionMask: CFURLBookmarkCreationOptions =
+//     (1 << 8) as u32;
+// static kCFURLBookmarkCreationMinimalBookmarkMask: CFURLBookmarkCreationOptions =
+//     (1 << 9) as u32;
+// static kCFURLBookmarkCreationSuitableForBookmarkFile: CFURLBookmarkCreationOptions =
+//     (1 << 10) as u32;
+// static kCFURLBookmarkCreationWithSecurityScope: CFURLBookmarkCreationOptions =
+//     (1 << 11) as u32;
+// static kCFURLBookmarkCreationSecurityScopeAllowOnlyReadAccess: CFURLBookmarkCreationOptions =
+//     (1 << 12) as u32;
+
+// TODO: there are a lot of missing keys and constants. Add if you are bored or need them.
+
+extern {
+    /*
+     * CFURL.h
+     */
+
+    /* Common File System Resource Keys */
+    // static kCFURLAttributeModificationDateKey: CFStringRef;
+    // static kCFURLContentAccessDateKey: CFStringRef;
+    // static kCFURLContentModificationDateKey: CFStringRef;
+    // static kCFURLCreationDateKey: CFStringRef;
+    // static kCFURLCustomIconKey: CFStringRef;
+    // static kCFURLEffectiveIconKey: CFStringRef;
+    // static kCFURLFileResourceIdentifierKey: CFStringRef;
+    // static kCFURLFileSecurityKey: CFStringRef;
+    // static kCFURLHasHiddenExtensionKey: CFStringRef;
+    // static kCFURLIsDirectoryKey: CFStringRef;
+    // static kCFURLIsExecutableKey: CFStringRef;
+    // static kCFURLIsHiddenKey: CFStringRef;
+    // static kCFURLIsPackageKey: CFStringRef;
+    // static kCFURLIsReadableKey: CFStringRef;
+    // static kCFURLIsRegularFileKey: CFStringRef;
+    // static kCFURLIsSymbolicLinkKey: CFStringRef;
+    // static kCFURLIsSystemImmutableKey: CFStringRef;
+    // static kCFURLIsUserImmutableKey: CFStringRef;
+    // static kCFURLIsVolumeKey: CFStringRef;
+    // static kCFURLIsWritableKey: CFStringRef;
+    // static kCFURLLabelColorKey: CFStringRef;
+    // static kCFURLLabelNumberKey: CFStringRef;
+    // static kCFURLLinkCountKey: CFStringRef;
+    // static kCFURLLocalizedLabelKey: CFStringRef;
+    // static kCFURLLocalizedNameKey: CFStringRef;
+    // static kCFURLLocalizedTypeDescriptionKey: CFStringRef;
+    // static kCFURLNameKey: CFStringRef;
+    // static kCFURLParentDirectoryURLKey: CFStringRef;
+    // static kCFURLPreferredIOBlockSizeKey: CFStringRef;
+    // static kCFURLTypeIdentifierKey: CFStringRef;
+    // static kCFURLVolumeIdentifierKey: CFStringRef;
+    // static kCFURLVolumeURLKey: CFStringRef;
+    // static kCFURLIsExcludedFromBackupKey: CFStringRef;
+    // static kCFURLFileResourceTypeKey: CFStringRef;
+
+    /* Creating a CFURL */
+    //fn CFURLCopyAbsoluteURL
+    //fn CFURLCreateAbsoluteURLWithBytes
+    //fn CFURLCreateByResolvingBookmarkData
+    //fn CFURLCreateCopyAppendingPathComponent
+    //fn CFURLCreateCopyAppendingPathExtension
+    //fn CFURLCreateCopyDeletingLastPathComponent
+    //fn CFURLCreateCopyDeletingPathExtension
+    //fn CFURLCreateFilePathURL
+    //fn CFURLCreateFileReferenceURL
+    //fn CFURLCreateFromFileSystemRepresentation
+    //fn CFURLCreateFromFileSystemRepresentationRelativeToBase
+    //fn CFURLCreateFromFSRef
+    //fn CFURLCreateWithBytes
+    //fn CFURLCreateWithFileSystemPath
+    pub fn CFURLCreateWithFileSystemPath(allocator: CFAllocatorRef, filePath: CFStringRef, pathStyle: CFURLPathStyle, isDirectory: Boolean) -> CFURLRef;
+    //fn CFURLCreateWithFileSystemPathRelativeToBase
+    //fn CFURLCreateWithString(allocator: CFAllocatorRef, urlString: CFStringRef,
+    //                         baseURL: CFURLRef) -> CFURLRef;
+
+    /* Accessing the Parts of a URL */
+    pub fn CFURLCanBeDecomposed(anURL: CFURLRef) -> Boolean;
+    pub fn CFURLCopyFileSystemPath(anURL: CFURLRef, pathStyle: CFURLPathStyle) -> CFStringRef;
+    pub fn CFURLCopyFragment(anURL: CFURLRef, charactersToLeaveEscaped: CFStringRef) -> CFStringRef;
+    pub fn CFURLCopyHostName(anURL: CFURLRef) -> CFStringRef;
+    pub fn CFURLCopyLastPathComponent(anURL: CFURLRef) -> CFStringRef;
+    pub fn CFURLCopyNetLocation(anURL: CFURLRef) -> CFStringRef;
+    pub fn CFURLCopyParameterString(anURL: CFURLRef, charactersToLeaveEscaped: CFStringRef) -> CFStringRef;
+    pub fn CFURLCopyPassword(anURL: CFURLRef) -> CFStringRef;
+    pub fn CFURLCopyPath(anURL: CFURLRef) -> CFStringRef;
+    pub fn CFURLCopyPathExtension(anURL: CFURLRef) -> CFStringRef;
+    pub fn CFURLCopyQueryString(anURL: CFURLRef, charactersToLeaveEscaped: CFStringRef) -> CFStringRef;
+    pub fn CFURLCopyResourceSpecifier(anURL: CFURLRef) -> CFStringRef;
+    pub fn CFURLCopyScheme(anURL: CFURLRef) -> CFStringRef;
+    pub fn CFURLCopyStrictPath(anURL: CFURLRef, isAbsolute: *mut Boolean) -> CFStringRef;
+    pub fn CFURLCopyUserName(anURL: CFURLRef) -> CFStringRef;
+    pub fn CFURLGetPortNumber(anURL: CFURLRef) -> SInt32;
+    pub fn CFURLHasDirectoryPath(anURL: CFURLRef) -> Boolean;
+
+    /* Converting URLs to Other Representations */
+    //fn CFURLCreateData(allocator: CFAllocatorRef, url: CFURLRef,
+    //                   encoding: CFStringEncoding, escapeWhitespace: bool) -> CFDataRef;
+    //fn CFURLCreateStringByAddingPercentEscapes
+    //fn CFURLCreateStringByReplacingPercentEscapes
+    //fn CFURLCreateStringByReplacingPercentEscapesUsingEncoding
+    //fn CFURLGetFileSystemRepresentation
+    //fn CFURLGetFSRef
+    pub fn CFURLGetString(anURL: CFURLRef) -> CFStringRef;
+
+    /* Getting URL Properties */
+    //fn CFURLGetBaseURL(anURL: CFURLRef) -> CFURLRef;
+    //fn CFURLGetBytes
+    //fn CFURLGetByteRangeForComponent
+    pub fn CFURLGetTypeID() -> CFTypeID;
+    //fn CFURLResourceIsReachable
+
+    /* Getting and Setting File System Resource Properties */
+    //fn CFURLClearResourcePropertyCache
+    //fn CFURLClearResourcePropertyCacheForKey
+    //fn CFURLCopyResourcePropertiesForKeys
+    //fn CFURLCopyResourcePropertyForKey
+    //fn CFURLCreateResourcePropertiesForKeysFromBookmarkData
+    //fn CFURLCreateResourcePropertyForKeyFromBookmarkData
+    //fn CFURLSetResourcePropertiesForKeys
+    //fn CFURLSetResourcePropertyForKey
+    //fn CFURLSetTemporaryResourcePropertyForKey
+
+    /* Working with Bookmark Data */
+    //fn CFURLCreateBookmarkData
+    //fn CFURLCreateBookmarkDataFromAliasRecord
+    //fn CFURLCreateBookmarkDataFromFile
+    //fn CFURLWriteBookmarkDataToFile
+    //fn CFURLStartAccessingSecurityScopedResource
+    //fn CFURLStopAccessingSecurityScopedResource
+}
--- a/third_party/rust/core-foundation-sys/.cargo-checksum.json
+++ b/third_party/rust/core-foundation-sys/.cargo-checksum.json
@@ -1,1 +1,1 @@
-{"files":{".cargo-ok":"e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855","Cargo.toml":"4516face4b018e46fc36cfe24eff335671684032a75435305d62fd5f280f05a7","build.rs":"4dbf3e5a423e5eba48fc7f11e4f7638c054e53a3750c888059a96d96f8923ef2","src/array.rs":"d648ed8cf0ccb72c3ca0d9e018a3db804edad9685739eba13f8f515e04f3708b","src/base.rs":"c995d91c9e5aed99ea28fc75561cfd573f5e8ff806ef512194e7b616c35c308f","src/bundle.rs":"ff5f5253f331b7fa054414a3f256d74760e3ce805b720cdb735a2e46cc66dce6","src/data.rs":"21e968951fe56e080d33474f4438de2dfb7e0c8af426a6dfb100efdd6c530eec","src/date.rs":"f6cdcb94658fafc5bacb83cfbd20ad97502b8ddf6bd1c0c0d6a2545a4f7b7420","src/dictionary.rs":"97c40c1afc719b970968179112ad76c3c89b6b4eb4ea18f7ac3f059d98cce736","src/error.rs":"61bc31a401ec6c8495668175eade9284e257da056fc666af74a5555af5daf33f","src/lib.rs":"8bdbc6ed8fcbbc5b69d7634031ff44d50b9ac789279eb89b80c280ea156c98b3","src/messageport.rs":"59ba92ca90bb9b3162b6df44188fac18cd979250f33a52361144c902e86529bd","src/number.rs":"8881c7cd1b510c654c445485de898f83abda91557fd3e6f9daccf2d1b9c4c57e","src/propertylist.rs":"cc2b27f8f8ebc80c03871b7b1ad50ee348539b016078ce721c86b8cd5f9d75bd","src/runloop.rs":"7feab3bbb9913c3b40285bc37b920f9fe4d937d1db08d8ae69a2ec9597713598","src/set.rs":"51e978fc81d4c55013dfc6df4e76c58daaf5deedf9aafda0f6a9e04e7575272c","src/string.rs":"27b92e8e5d3fc95a521dc6447ccfefd9eb28ec5f42bd8571defd124d950b133f","src/url.rs":"8a3f4137ca26e379a24666b4caa7a08f9726f838e53e9dbb92ba474036309669"},"package":"41115a6aa5d3e1e5ef98148373f25971d1fad53818553f216495f9e67e90a624"}
\ No newline at end of file
+{"files":{".cargo-ok":"e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855","Cargo.toml":"77d394e2185996b9c2478c670a7aed78fa872e61585a838ac2b93109a338813d","build.rs":"9433ed3b20cc99e716dda4c6d8507c29bc04882544cbbea8d4e48ba80fd0fa12","src/array.rs":"d648ed8cf0ccb72c3ca0d9e018a3db804edad9685739eba13f8f515e04f3708b","src/base.rs":"c995d91c9e5aed99ea28fc75561cfd573f5e8ff806ef512194e7b616c35c308f","src/bundle.rs":"1b6df1e2a112c1965c5b5ae095634444b771eb078e78bc5b251714b9ccc3d8e0","src/data.rs":"21e968951fe56e080d33474f4438de2dfb7e0c8af426a6dfb100efdd6c530eec","src/date.rs":"f6cdcb94658fafc5bacb83cfbd20ad97502b8ddf6bd1c0c0d6a2545a4f7b7420","src/dictionary.rs":"97c40c1afc719b970968179112ad76c3c89b6b4eb4ea18f7ac3f059d98cce736","src/error.rs":"61bc31a401ec6c8495668175eade9284e257da056fc666af74a5555af5daf33f","src/lib.rs":"0a061fa3866fb98568dc5307b68297819853d0737ab07ff2b515910f1ff5afaa","src/messageport.rs":"59ba92ca90bb9b3162b6df44188fac18cd979250f33a52361144c902e86529bd","src/number.rs":"0fc5598a0498baa70d64891d96522be58802a0ec18eb6f9570e0b154eb0a564c","src/propertylist.rs":"cc2b27f8f8ebc80c03871b7b1ad50ee348539b016078ce721c86b8cd5f9d75bd","src/runloop.rs":"7feab3bbb9913c3b40285bc37b920f9fe4d937d1db08d8ae69a2ec9597713598","src/set.rs":"22055b5ce6a2ce37847ee955f5e6e517348a351770d335373704776bc5412b9f","src/string.rs":"27b92e8e5d3fc95a521dc6447ccfefd9eb28ec5f42bd8571defd124d950b133f","src/url.rs":"bd965da3db23ef0e14ae196511b4ece88a3de8bbdf3e9dd58e224959f10b07ae"},"package":"bc9fb3d6cb663e6fd7cf1c63f9b144ee2b1e4a78595a0451dd34bff85b9a3387"}
\ No newline at end of file
--- a/third_party/rust/core-foundation-sys/Cargo.toml
+++ b/third_party/rust/core-foundation-sys/Cargo.toml
@@ -1,12 +1,27 @@
+# THIS FILE IS AUTOMATICALLY GENERATED BY CARGO
+#
+# When uploading crates to the registry Cargo will automatically
+# "normalize" Cargo.toml files for maximal compatibility
+# with all versions of Cargo and also rewrite `path` dependencies
+# to registry (e.g. crates.io) dependencies
+#
+# If you believe there's an error in this file please file an
+# issue against the rust-lang/cargo repository. If you're
+# editing this file be aware that the upstream Cargo.toml
+# will likely look very different (and much more reasonable)
+
 [package]
 name = "core-foundation-sys"
+version = "0.4.4"
+authors = ["The Servo Project Developers"]
+build = "build.rs"
 description = "Bindings to Core Foundation for OS X"
 homepage = "https://github.com/servo/core-foundation-rs"
+license = "MIT / Apache-2.0"
 repository = "https://github.com/servo/core-foundation-rs"
-version = "0.3.1"
-authors = ["The Servo Project Developers"]
-license = "MIT / Apache-2.0"
-build = "build.rs"
+[dependencies.libc]
+version = "0.2"
 
-[dependencies]
-libc = "0.2"
+[features]
+mac_os_10_7_support = []
+mac_os_10_8_features = []
--- a/third_party/rust/core-foundation-sys/build.rs
+++ b/third_party/rust/core-foundation-sys/build.rs
@@ -3,10 +3,12 @@
 //
 // Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
 // http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
 // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
 fn main() {
-    println!("cargo:rustc-link-lib=framework=CoreFoundation");
+    if std::env::var("TARGET").unwrap().contains("-apple") {
+        println!("cargo:rustc-link-lib=framework=CoreFoundation");
+    }
 }
--- a/third_party/rust/core-foundation-sys/src/bundle.rs
+++ b/third_party/rust/core-foundation-sys/src/bundle.rs
@@ -4,28 +4,33 @@
 // Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
 // http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
 // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
 use libc::c_void;
 
-use base::CFTypeID;
+use base::{CFTypeID, CFAllocatorRef};
+use url::CFURLRef;
 use dictionary::CFDictionaryRef;
 use string::CFStringRef;
 
 #[repr(C)]
 pub struct __CFBundle(c_void);
 
 pub type CFBundleRef = *const __CFBundle;
 
 extern {
     /*
      * CFBundle.h
      */
+    pub fn CFBundleCreate(allocator: CFAllocatorRef, bundleURL: CFURLRef) -> CFBundleRef;
+
     pub fn CFBundleGetBundleWithIdentifier(bundleID: CFStringRef) -> CFBundleRef;
     pub fn CFBundleGetFunctionPointerForName(bundle: CFBundleRef, function_name: CFStringRef) -> *const c_void;
     pub fn CFBundleGetMainBundle() -> CFBundleRef;
     pub fn CFBundleGetInfoDictionary(bundle: CFBundleRef) -> CFDictionaryRef;
 
     pub fn CFBundleGetTypeID() -> CFTypeID;
+    pub fn CFBundleCopyExecutableURL(bundle: CFBundleRef) -> CFURLRef;
+    pub fn CFBundleCopyPrivateFrameworksURL(bundle: CFBundleRef) -> CFURLRef;
 }
--- a/third_party/rust/core-foundation-sys/src/lib.rs
+++ b/third_party/rust/core-foundation-sys/src/lib.rs
@@ -3,16 +3,18 @@
 //
 // Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
 // http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
 // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 #![allow(non_snake_case, non_camel_case_types, non_upper_case_globals, improper_ctypes)]
 
+#![cfg_attr(all(feature="mac_os_10_7_support", feature="mac_os_10_8_features"), feature(linkage))] // back-compat requires weak linkage
+
 extern crate libc;
 
 pub mod array;
 pub mod base;
 pub mod bundle;
 pub mod data;
 pub mod date;
 pub mod dictionary;
--- a/third_party/rust/core-foundation-sys/src/number.rs
+++ b/third_party/rust/core-foundation-sys/src/number.rs
@@ -32,18 +32,19 @@ pub static kCFNumberFloat64Type:   CFNum
 // static kCFNumberLongLongType:  CFNumberType = 11;
 // static kCFNumberFloatType:     CFNumberType = 12;
 // static kCFNumberDoubleType:    CFNumberType = 13;
 // static kCFNumberCFIndexType:   CFNumberType = 14;
 // static kCFNumberNSIntegerType: CFNumberType = 15;
 // static kCFNumberCGFloatType:   CFNumberType = 16;
 // static kCFNumberMaxType:       CFNumberType = 16;
 
-#[repr(C)]
-pub struct __CFNumber;
+// This is an enum due to zero-sized types warnings.
+// For more details see https://github.com/rust-lang/rust/issues/27303
+pub enum __CFNumber {}
 
 pub type CFNumberRef = *const __CFNumber;
 
 extern {
     /*
      * CFNumber.h
      */
     pub static kCFBooleanTrue: CFBooleanRef;
--- a/third_party/rust/core-foundation-sys/src/set.rs
+++ b/third_party/rust/core-foundation-sys/src/set.rs
@@ -6,16 +6,18 @@
 // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
 use libc::c_void;
 
 use base::{CFAllocatorRef, CFIndex, CFTypeID};
 
+pub type CFSetApplierFunction = extern "C" fn (value: *const c_void,
+                                               context: *const c_void);
 pub type CFSetRetainCallBack = *const u8;
 pub type CFSetReleaseCallBack = *const u8;
 pub type CFSetCopyDescriptionCallBack = *const u8;
 pub type CFSetEqualCallBack = *const u8;
 pub type CFSetHashCallBack = *const u8;
 
 #[repr(C)]
 #[derive(Clone, Copy)]
@@ -40,13 +42,17 @@ extern {
 
     pub static kCFTypeSetCallBacks: CFSetCallBacks;
 
     /* Creating Sets */
     pub fn CFSetCreate(allocator: CFAllocatorRef, values: *const *const c_void, numValues: CFIndex,
                        callBacks: *const CFSetCallBacks) -> CFSetRef;
 
     /* Applying a Function to Set Members */
-    //fn CFSetApplyFunction
+    pub fn CFSetApplyFunction(theSet: CFSetRef,
+                              applier: CFSetApplierFunction,
+                              context: *const c_void);
+
+    pub fn CFSetGetCount(theSet: CFSetRef) -> CFIndex;
 
     pub fn CFSetGetTypeID() -> CFTypeID;
 }
 
--- a/third_party/rust/core-foundation-sys/src/url.rs
+++ b/third_party/rust/core-foundation-sys/src/url.rs
@@ -3,18 +3,19 @@
 //
 // Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
 // http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
 // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 use libc::c_void;
 
-use base::{CFOptionFlags, CFIndex, CFAllocatorRef, Boolean, CFTypeID, SInt32};
-use string::CFStringRef;
+use base::{CFOptionFlags, CFIndex, CFAllocatorRef, Boolean, CFTypeID, CFTypeRef, SInt32};
+use string::{CFStringRef, CFStringEncoding};
+use error::CFErrorRef;
 
 #[repr(C)]
 pub struct __CFURL(c_void);
 
 pub type CFURLRef = *const __CFURL;
 
 pub type CFURLBookmarkCreationOptions = CFOptionFlags;
 
@@ -39,68 +40,67 @@ pub const kCFURLWindowsPathStyle: CFURLP
 // TODO: there are a lot of missing keys and constants. Add if you are bored or need them.
 
 extern {
     /*
      * CFURL.h
      */
 
     /* Common File System Resource Keys */
-    // static kCFURLAttributeModificationDateKey: CFStringRef;
-    // static kCFURLContentAccessDateKey: CFStringRef;
-    // static kCFURLContentModificationDateKey: CFStringRef;
-    // static kCFURLCreationDateKey: CFStringRef;
-    // static kCFURLCustomIconKey: CFStringRef;
-    // static kCFURLEffectiveIconKey: CFStringRef;
-    // static kCFURLFileResourceIdentifierKey: CFStringRef;
-    // static kCFURLFileSecurityKey: CFStringRef;
-    // static kCFURLHasHiddenExtensionKey: CFStringRef;
-    // static kCFURLIsDirectoryKey: CFStringRef;
-    // static kCFURLIsExecutableKey: CFStringRef;
-    // static kCFURLIsHiddenKey: CFStringRef;
-    // static kCFURLIsPackageKey: CFStringRef;
-    // static kCFURLIsReadableKey: CFStringRef;
-    // static kCFURLIsRegularFileKey: CFStringRef;
-    // static kCFURLIsSymbolicLinkKey: CFStringRef;
-    // static kCFURLIsSystemImmutableKey: CFStringRef;
-    // static kCFURLIsUserImmutableKey: CFStringRef;
-    // static kCFURLIsVolumeKey: CFStringRef;
-    // static kCFURLIsWritableKey: CFStringRef;
-    // static kCFURLLabelColorKey: CFStringRef;
-    // static kCFURLLabelNumberKey: CFStringRef;
-    // static kCFURLLinkCountKey: CFStringRef;
-    // static kCFURLLocalizedLabelKey: CFStringRef;
-    // static kCFURLLocalizedNameKey: CFStringRef;
-    // static kCFURLLocalizedTypeDescriptionKey: CFStringRef;
-    // static kCFURLNameKey: CFStringRef;
-    // static kCFURLParentDirectoryURLKey: CFStringRef;
-    // static kCFURLPreferredIOBlockSizeKey: CFStringRef;
-    // static kCFURLTypeIdentifierKey: CFStringRef;
-    // static kCFURLVolumeIdentifierKey: CFStringRef;
-    // static kCFURLVolumeURLKey: CFStringRef;
-    // static kCFURLIsExcludedFromBackupKey: CFStringRef;
-    // static kCFURLFileResourceTypeKey: CFStringRef;
+    pub static kCFURLAttributeModificationDateKey: CFStringRef;
+    pub static kCFURLContentAccessDateKey: CFStringRef;
+    pub static kCFURLContentModificationDateKey: CFStringRef;
+    pub static kCFURLCreationDateKey: CFStringRef;
+    pub static kCFURLFileResourceIdentifierKey: CFStringRef;
+    pub static kCFURLFileSecurityKey: CFStringRef;
+    pub static kCFURLHasHiddenExtensionKey: CFStringRef;
+    pub static kCFURLIsDirectoryKey: CFStringRef;
+    pub static kCFURLIsExecutableKey: CFStringRef;
+    pub static kCFURLIsHiddenKey: CFStringRef;
+    pub static kCFURLIsPackageKey: CFStringRef;
+    pub static kCFURLIsReadableKey: CFStringRef;
+    pub static kCFURLIsRegularFileKey: CFStringRef;
+    pub static kCFURLIsSymbolicLinkKey: CFStringRef;
+    pub static kCFURLIsSystemImmutableKey: CFStringRef;
+    pub static kCFURLIsUserImmutableKey: CFStringRef;
+    pub static kCFURLIsVolumeKey: CFStringRef;
+    pub static kCFURLIsWritableKey: CFStringRef;
+    pub static kCFURLLabelNumberKey: CFStringRef;
+    pub static kCFURLLinkCountKey: CFStringRef;
+    pub static kCFURLLocalizedLabelKey: CFStringRef;
+    pub static kCFURLLocalizedNameKey: CFStringRef;
+    pub static kCFURLLocalizedTypeDescriptionKey: CFStringRef;
+    pub static kCFURLNameKey: CFStringRef;
+    pub static kCFURLParentDirectoryURLKey: CFStringRef;
+    pub static kCFURLPreferredIOBlockSizeKey: CFStringRef;
+    pub static kCFURLTypeIdentifierKey: CFStringRef;
+    pub static kCFURLVolumeIdentifierKey: CFStringRef;
+    pub static kCFURLVolumeURLKey: CFStringRef;
+
+    #[cfg(feature="mac_os_10_8_features")]
+    #[cfg_attr(feature = "mac_os_10_7_support", linkage = "extern_weak")]
+    pub static kCFURLIsExcludedFromBackupKey: CFStringRef;
+    pub static kCFURLFileResourceTypeKey: CFStringRef;
 
     /* Creating a CFURL */
-    //fn CFURLCopyAbsoluteURL
+    pub fn CFURLCopyAbsoluteURL(anURL: CFURLRef) -> CFURLRef;
     //fn CFURLCreateAbsoluteURLWithBytes
     //fn CFURLCreateByResolvingBookmarkData
     //fn CFURLCreateCopyAppendingPathComponent
     //fn CFURLCreateCopyAppendingPathExtension
     //fn CFURLCreateCopyDeletingLastPathComponent
     //fn CFURLCreateCopyDeletingPathExtension
-    //fn CFURLCreateFilePathURL
+    pub fn CFURLCreateFilePathURL(allocator: CFAllocatorRef, url: CFURLRef, error: *mut CFErrorRef) -> CFURLRef;
     //fn CFURLCreateFileReferenceURL
-    //fn CFURLCreateFromFileSystemRepresentation
+    pub fn CFURLCreateFromFileSystemRepresentation(allocator: CFAllocatorRef, buffer: *const u8, bufLen: CFIndex, isDirectory: Boolean) -> CFURLRef;
     //fn CFURLCreateFromFileSystemRepresentationRelativeToBase
     //fn CFURLCreateFromFSRef
-    //fn CFURLCreateWithBytes
-    //fn CFURLCreateWithFileSystemPath
+    pub fn CFURLCreateWithBytes(allocator: CFAllocatorRef, URLBytes: *const u8, length: CFIndex, encoding: CFStringEncoding, baseURL: CFURLRef) -> CFURLRef;
     pub fn CFURLCreateWithFileSystemPath(allocator: CFAllocatorRef, filePath: CFStringRef, pathStyle: CFURLPathStyle, isDirectory: Boolean) -> CFURLRef;
-    //fn CFURLCreateWithFileSystemPathRelativeToBase
+    pub fn CFURLCreateWithFileSystemPathRelativeToBase(allocator: CFAllocatorRef, filePath: CFStringRef, pathStyle: CFURLPathStyle, isDirectory: Boolean, baseURL: CFURLRef) -> CFURLRef;
     //fn CFURLCreateWithString(allocator: CFAllocatorRef, urlString: CFStringRef,
     //                         baseURL: CFURLRef) -> CFURLRef;
 
     /* Accessing the Parts of a URL */
     pub fn CFURLCanBeDecomposed(anURL: CFURLRef) -> Boolean;
     pub fn CFURLCopyFileSystemPath(anURL: CFURLRef, pathStyle: CFURLPathStyle) -> CFStringRef;
     pub fn CFURLCopyFragment(anURL: CFURLRef, charactersToLeaveEscaped: CFStringRef) -> CFStringRef;
     pub fn CFURLCopyHostName(anURL: CFURLRef) -> CFStringRef;
@@ -131,26 +131,32 @@ extern {
     /* Getting URL Properties */
     //fn CFURLGetBaseURL(anURL: CFURLRef) -> CFURLRef;
     //fn CFURLGetBytes
     //fn CFURLGetByteRangeForComponent
     pub fn CFURLGetTypeID() -> CFTypeID;
     //fn CFURLResourceIsReachable
 
     /* Getting and Setting File System Resource Properties */
-    //fn CFURLClearResourcePropertyCache
+    pub fn CFURLClearResourcePropertyCache(url: CFURLRef);
     //fn CFURLClearResourcePropertyCacheForKey
     //fn CFURLCopyResourcePropertiesForKeys
     //fn CFURLCopyResourcePropertyForKey
     //fn CFURLCreateResourcePropertiesForKeysFromBookmarkData
     //fn CFURLCreateResourcePropertyForKeyFromBookmarkData
     //fn CFURLSetResourcePropertiesForKeys
-    //fn CFURLSetResourcePropertyForKey
+    pub fn CFURLSetResourcePropertyForKey(url: CFURLRef, key: CFStringRef, value: CFTypeRef, error: *mut CFErrorRef) -> Boolean;
     //fn CFURLSetTemporaryResourcePropertyForKey
 
     /* Working with Bookmark Data */
     //fn CFURLCreateBookmarkData
     //fn CFURLCreateBookmarkDataFromAliasRecord
     //fn CFURLCreateBookmarkDataFromFile
     //fn CFURLWriteBookmarkDataToFile
     //fn CFURLStartAccessingSecurityScopedResource
     //fn CFURLStopAccessingSecurityScopedResource
 }
+
+#[test]
+#[cfg(feature="mac_os_10_8_features")]
+fn can_see_excluded_from_backup_key() {
+    let _ = unsafe { kCFURLIsExcludedFromBackupKey };
+}
--- a/third_party/rust/core-foundation/.cargo-checksum.json
+++ b/third_party/rust/core-foundation/.cargo-checksum.json
@@ -1,1 +1,1 @@
-{"files":{".cargo-ok":"e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855","Cargo.toml":"7b2f3fe208482ac4c1cf309681e202f3b6e10b512f13a7717e6b298809cd8e03","src/array.rs":"ceeb3298fb939ead81914a0e6a555098e59f97c47e62adb625273bde2bb299a4","src/base.rs":"540c85a6600503e2bdf34087e7e921615b094f7493099c7e319c76f34ab97a02","src/boolean.rs":"112adb640ded232cba59eb27edafcf4a3c045cca6f4b0ecb53bb48b741c2139a","src/bundle.rs":"bd172a5e0cc1dffc80edf17da59b90120d0a110181f50f212589b0334fcba72c","src/data.rs":"fc44b08e644b66ae471bb7c8141ec6be7cf5f35eb985dbca5924668a67f0efe5","src/dictionary.rs":"0f3129629db02ea233d08fd937e8290c40f401d644f6a8afc13717094a767559","src/error.rs":"0edbf66bcaa8a68f1de77b9056696b6be4f2dc773f4561f4279e6494cc38453a","src/lib.rs":"71ee7a83a7012138b5a86897f5617d2742c668ccc69664a8c5b4cf080486ddd8","src/number.rs":"262db248c88ac08a3d28d0940ef25fe796fd4ebcf1eeea7bb8a6caa3abdc97f9","src/propertylist.rs":"ec814aa190bc6cf8c2bb3f2d5c65e1a706a770701c8589d29fc01bddad6a11c6","src/runloop.rs":"10e35be9104db16c064dfcb3454a71d00c498fda6145eba53f6e43cb37ee9c15","src/set.rs":"f98fbd31b107f27680727676ab7a3725d6b4370f428e58759ca680eb339a5ea3","src/string.rs":"ec5420a3916e5ebd2cc487ffc605d8fe8de7d09cae8c9fecbf20aa21595f4bee","src/url.rs":"2bdc580d8fa4556c9466923aeccc845257fee9fb5e960b8ff84d6bfead994335"},"package":"f51ce3b8ebe311c56de14231eb57572c15abebd2d32b3bcb99bcdb9c101f5ac3"}
\ No newline at end of file
+{"files":{".cargo-ok":"e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855","Cargo.toml":"309020bd517f30f6daaf95caf2a832118eb3cd23d5732d076e059a7a8f4dea49","src/array.rs":"ceeb3298fb939ead81914a0e6a555098e59f97c47e62adb625273bde2bb299a4","src/base.rs":"540c85a6600503e2bdf34087e7e921615b094f7493099c7e319c76f34ab97a02","src/boolean.rs":"112adb640ded232cba59eb27edafcf4a3c045cca6f4b0ecb53bb48b741c2139a","src/bundle.rs":"69fa69ec2d8ea8e897363e2351d947235d040eaa5f5ff562e280e59399f56769","src/data.rs":"fc44b08e644b66ae471bb7c8141ec6be7cf5f35eb985dbca5924668a67f0efe5","src/dictionary.rs":"0f3129629db02ea233d08fd937e8290c40f401d644f6a8afc13717094a767559","src/error.rs":"0edbf66bcaa8a68f1de77b9056696b6be4f2dc773f4561f4279e6494cc38453a","src/lib.rs":"71ee7a83a7012138b5a86897f5617d2742c668ccc69664a8c5b4cf080486ddd8","src/number.rs":"262db248c88ac08a3d28d0940ef25fe796fd4ebcf1eeea7bb8a6caa3abdc97f9","src/propertylist.rs":"ec814aa190bc6cf8c2bb3f2d5c65e1a706a770701c8589d29fc01bddad6a11c6","src/runloop.rs":"6fdc656958950ff84a167c67111e94818246caa50e2ba84004853f28652490d6","src/set.rs":"f98fbd31b107f27680727676ab7a3725d6b4370f428e58759ca680eb339a5ea3","src/string.rs":"ec5420a3916e5ebd2cc487ffc605d8fe8de7d09cae8c9fecbf20aa21595f4bee","src/url.rs":"2b3caaea223bc27fb268a81f0607b975f92b9df9a58194ac1881dacf314e4219"},"package":"5909502e547762013619f4c4e01cc7393c20fe2d52d7fa471c1210adb2320dc7"}
\ No newline at end of file
--- a/third_party/rust/core-foundation/Cargo.toml
+++ b/third_party/rust/core-foundation/Cargo.toml
@@ -1,15 +1,29 @@
+# THIS FILE IS AUTOMATICALLY GENERATED BY CARGO
+#
+# When uploading crates to the registry Cargo will automatically
+# "normalize" Cargo.toml files for maximal compatibility
+# with all versions of Cargo and also rewrite `path` dependencies
+# to registry (e.g. crates.io) dependencies
+#
+# If you believe there's an error in this file please file an
+# issue against the rust-lang/cargo repository. If you're
+# editing this file be aware that the upstream Cargo.toml
+# will likely look very different (and much more reasonable)
+
 [package]
 name = "core-foundation"
+version = "0.4.4"
+authors = ["The Servo Project Developers"]
 description = "Bindings to Core Foundation for OS X"
 homepage = "https://github.com/servo/core-foundation-rs"
+license = "MIT / Apache-2.0"
 repository = "https://github.com/servo/core-foundation-rs"
-version = "0.3.0"
-authors = ["The Servo Project Developers"]
-license = "MIT / Apache-2.0"
+[dependencies.libc]
+version = "0.2"
 
 [dependencies.core-foundation-sys]
-path = "../core-foundation-sys"
-version = "0.3.0"
+version = "0.4.4"
 
-[dependencies]
-libc = "0.2"
+[features]
+mac_os_10_8_features = ["core-foundation-sys/mac_os_10_8_features"]
+mac_os_10_7_support = ["core-foundation-sys/mac_os_10_7_support"]
--- a/third_party/rust/core-foundation/src/bundle.rs
+++ b/third_party/rust/core-foundation/src/bundle.rs
@@ -5,42 +5,123 @@
 // http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
 // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
 //! Core Foundation Bundle Type
 
 pub use core_foundation_sys::bundle::*;
-use core_foundation_sys::base::CFRelease;
+use core_foundation_sys::base::{CFRelease, kCFAllocatorDefault};
 
-use base::{TCFType};
+use base::TCFType;
+use url::CFURL;
 use dictionary::CFDictionary;
 
 /// A Bundle type.
 pub struct CFBundle(CFBundleRef);
 
 impl Drop for CFBundle {
     fn drop(&mut self) {
         unsafe {
             CFRelease(self.as_CFTypeRef())
         }
     }
 }
 
 impl CFBundle {
+    pub fn new(bundleURL: CFURL) -> Option<CFBundle> {
+        unsafe {
+            let bundle_ref = CFBundleCreate(kCFAllocatorDefault, bundleURL.as_concrete_TypeRef());
+            if bundle_ref.is_null() {
+                None
+            } else {
+                Some(TCFType::wrap_under_create_rule(bundle_ref))
+            }
+        }
+    }
+
     pub fn main_bundle() -> CFBundle {
         unsafe {
             let bundle_ref = CFBundleGetMainBundle();
             TCFType::wrap_under_get_rule(bundle_ref)
         }
     }
 
     pub fn info_dictionary(&self) -> CFDictionary {
         unsafe {
             let info_dictionary = CFBundleGetInfoDictionary(self.0);
             TCFType::wrap_under_get_rule(info_dictionary)
         }
     }
+
+    pub fn executable_url(&self) -> Option<CFURL> {
+        unsafe {
+            let exe_url = CFBundleCopyExecutableURL(self.0);
+            if exe_url.is_null() {
+                None
+            } else {
+                Some(TCFType::wrap_under_create_rule(exe_url))
+            }
+        }
+    }
+
+    pub fn private_frameworks_url(&self) -> Option<CFURL> {
+        unsafe {
+            let fw_url = CFBundleCopyPrivateFrameworksURL(self.0);
+            if fw_url.is_null() {
+                None
+            } else {
+                Some(TCFType::wrap_under_create_rule(fw_url))
+            }
+        }
+    }
 }
 
 impl_TCFType!(CFBundle, CFBundleRef, CFBundleGetTypeID);
 
+#[test]
+fn safari_executable_url() {
+    use string::CFString;
+    use url::{CFURL, kCFURLPOSIXPathStyle};
+
+    let cfstr_path = CFString::from_static_string("/Applications/Safari.app");
+    let cfurl_path = CFURL::from_file_system_path(cfstr_path, kCFURLPOSIXPathStyle, true);
+    let cfurl_executable = CFBundle::new(cfurl_path)
+        .expect("Safari not present")
+        .executable_url();
+    assert!(cfurl_executable.is_some());
+    assert_eq!(cfurl_executable
+                   .unwrap()
+                   .absolute()
+                   .get_file_system_path(kCFURLPOSIXPathStyle)
+                   .to_string(),
+               "/Applications/Safari.app/Contents/MacOS/Safari");
+}
+
+#[test]
+fn safari_private_frameworks_url() {
+    use string::CFString;
+    use url::{CFURL, kCFURLPOSIXPathStyle};
+
+    let cfstr_path = CFString::from_static_string("/Applications/Safari.app");
+    let cfurl_path = CFURL::from_file_system_path(cfstr_path, kCFURLPOSIXPathStyle, true);
+    let cfurl_executable = CFBundle::new(cfurl_path)
+        .expect("Safari not present")
+        .private_frameworks_url();
+    assert!(cfurl_executable.is_some());
+    assert_eq!(cfurl_executable
+                   .unwrap()
+                   .absolute()
+                   .get_file_system_path(kCFURLPOSIXPathStyle)
+                   .to_string(),
+               "/Applications/Safari.app/Contents/Frameworks");
+}
+
+#[test]
+fn non_existant_bundle() {
+    use string::CFString;
+    use url::{CFURL, kCFURLPOSIXPathStyle};
+
+    let cfstr_path = CFString::from_static_string("/usr/local/foo");
+    let cfurl_path = CFURL::from_file_system_path(cfstr_path, kCFURLPOSIXPathStyle, true);
+    assert!(CFBundle::new(cfurl_path).is_none());
+}
--- a/third_party/rust/core-foundation/src/runloop.rs
+++ b/third_party/rust/core-foundation/src/runloop.rs
@@ -120,18 +120,19 @@ mod test {
             info: mem::transmute(&mut now),
             retain: mem::zeroed(),
             release: mem::zeroed(),
             copyDescription: mem::zeroed(),
         } };
 
 
         let run_loop_timer = CFRunLoopTimer::new(now + 0.20f64, 0f64, 0, 0, timer_popped, &mut context);
-        run_loop.add_timer(&run_loop_timer, kCFRunLoopDefaultMode);
-
+        unsafe {
+            run_loop.add_timer(&run_loop_timer, kCFRunLoopDefaultMode);
+        }
         CFRunLoop::run_current();
     }
 
     extern "C" fn timer_popped(_timer: CFRunLoopTimerRef, _info: *mut c_void) {
         let previous_now_ptr: *const CFAbsoluteTime = unsafe { mem::transmute(_info) };
         let previous_now = unsafe { *previous_now_ptr };
         let now = unsafe { CFAbsoluteTimeGetCurrent() };
         assert!(now - previous_now > 0.19 && now - previous_now < 0.21);
--- a/third_party/rust/core-foundation/src/url.rs
+++ b/third_party/rust/core-foundation/src/url.rs
@@ -6,21 +6,23 @@
 // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
 //! A URL type for Core Foundation.
 
 pub use core_foundation_sys::url::*;
 
-use base::{TCFType};
+use base::{TCFType, CFIndex};
 use string::{CFString};
 
 use core_foundation_sys::base::{kCFAllocatorDefault, CFRelease};
 use std::fmt;
+use std::ptr;
+use std::path::Path;
 
 pub struct CFURL(CFURLRef);
 
 impl Drop for CFURL {
     fn drop(&mut self) {
         unsafe {
             CFRelease(self.as_CFTypeRef())
         }
@@ -35,29 +37,84 @@ impl fmt::Debug for CFURL {
         unsafe {
             let string: CFString = TCFType::wrap_under_get_rule(CFURLGetString(self.0));
             write!(f, "{}", string.to_string())
         }
     }
 }
 
 impl CFURL {
+    pub fn from_path<P: AsRef<Path>>(path: P, isDirectory: bool) -> Option<CFURL> {
+        let path = match path.as_ref().to_str() {
+            Some(path) => path,
+            None => return None,
+        };
+
+        unsafe {
+            let url_ref = CFURLCreateFromFileSystemRepresentation(ptr::null_mut(), path.as_ptr(), path.len() as CFIndex, isDirectory as u8);
+            if url_ref.is_null() {
+                return None;
+            }
+            Some(TCFType::wrap_under_create_rule(url_ref))
+        }
+    }
+
     pub fn from_file_system_path(filePath: CFString, pathStyle: CFURLPathStyle, isDirectory: bool) -> CFURL {
         unsafe {
             let url_ref = CFURLCreateWithFileSystemPath(kCFAllocatorDefault, filePath.as_concrete_TypeRef(), pathStyle, isDirectory as u8);
             TCFType::wrap_under_create_rule(url_ref)
         }
     }
 
     pub fn get_string(&self) -> CFString {
         unsafe {
             TCFType::wrap_under_get_rule(CFURLGetString(self.0))
         }
     }
+
+    pub fn get_file_system_path(&self, pathStyle: CFURLPathStyle) -> CFString {
+        unsafe {
+            TCFType::wrap_under_create_rule(CFURLCopyFileSystemPath(self.as_concrete_TypeRef(), pathStyle))
+        }
+    }
+
+    pub fn absolute(&self) -> CFURL {
+        unsafe {
+            TCFType::wrap_under_create_rule(CFURLCopyAbsoluteURL(self.as_concrete_TypeRef()))
+        }
+    }
 }
 
 #[test]
 fn file_url_from_path() {
     let path = "/usr/local/foo/";
     let cfstr_path = CFString::from_static_string(path);
     let cfurl = CFURL::from_file_system_path(cfstr_path, kCFURLPOSIXPathStyle, true);
-    assert!(cfurl.get_string().to_string() == "file:///usr/local/foo/");
+    assert_eq!(cfurl.get_string().to_string(), "file:///usr/local/foo/");
 }
+
+#[test]
+fn absolute_file_url() {
+    use core_foundation_sys::url::CFURLCreateWithFileSystemPathRelativeToBase;
+    use std::path::PathBuf;
+
+    let path = "/usr/local/foo";
+    let file = "bar";
+
+    let cfstr_path = CFString::from_static_string(path);
+    let cfstr_file = CFString::from_static_string(file);
+    let cfurl_base = CFURL::from_file_system_path(cfstr_path, kCFURLPOSIXPathStyle, true);
+    let cfurl_relative: CFURL = unsafe {
+        let url_ref = CFURLCreateWithFileSystemPathRelativeToBase(kCFAllocatorDefault,
+            cfstr_file.as_concrete_TypeRef(),
+            kCFURLPOSIXPathStyle,
+            false as u8,
+            cfurl_base.as_concrete_TypeRef());
+        TCFType::wrap_under_create_rule(url_ref)
+    };
+
+    let mut absolute_path = PathBuf::from(path);
+    absolute_path.push(file);
+
+    assert_eq!(cfurl_relative.get_file_system_path(kCFURLPOSIXPathStyle).to_string(), file);
+    assert_eq!(cfurl_relative.absolute().get_file_system_path(kCFURLPOSIXPathStyle).to_string(),
+        absolute_path.to_str().unwrap());
+}
--- a/third_party/rust/core-graphics/.cargo-checksum.json
+++ b/third_party/rust/core-graphics/.cargo-checksum.json
@@ -1,1 +1,1 @@
-{"files":{".cargo-ok":"e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",".travis.yml":"b71b9a6f84b9263b2b89be6ec90dff5920ee68cf9e5768d73ed71957de2d0670","COPYRIGHT":"ec82b96487e9e778ee610c7ab245162464782cfa1f555c2299333f8dbe5c036a","Cargo.toml":"5b53cadf8fadf693d9d96d43d135a9fe0f3a3eea0742971e4cba9400fb4d6981","LICENSE-APACHE":"a60eea817514531668d7e00765731449fe14d059d3249e0bc93b36de45f759f2","LICENSE-MIT":"62065228e42caebca7e7d7db1204cbb867033de5982ca4009928915e4095f3a3","README.md":"4a45abeb1e684e30bb361dfa7db59189423348e18d310cbae694b7c8c57cd86a","src/base.rs":"3f3d5d69bd79b146cc3c0402de6260f7531c04e6a44b080f4ec7c8cedebd1337","src/color_space.rs":"7d447e774e85cc33de574637a93c9a8550b681c8d4b94e99f95261ea9740e288","src/context.rs":"6ca07886ad2c3c488f440b95cbffc4cefce212625799e9f1bb9f83f2b9985538","src/data_provider.rs":"b20cbff65a960409abfc1e3eb8145db892c6f9f0294805e5425a4186b88d32c3","src/display.rs":"b63f3a6d5971ad216edf8e961dcd201b84b4028d6bc3eebcfc6371300d841629","src/event.rs":"8b188320702836bd1d6fe18db0deb4415755c5a10e2c44afa691fec02f1e3ce2","src/event_source.rs":"6d1c1378dab8988c46dd3bf20639913716418980b9b490a37a0d5120c60ad580","src/font.rs":"a763205dbab72498a60e62ca7e63fc23bcb05cce0bfe5eacb1189a5783f18314","src/geometry.rs":"d452bbfe443d26b80a54ae8dc9eccb68fd03e35f846eba37618ee0c295af122d","src/image.rs":"08a61e703577bcebe5102e3382a777b319b0e9b063dfefb00982094e56525011","src/lib.rs":"62efb6fccbc8a26ea855cb509e649d83b92573941ce7ef4b9a90b2be926a0b91","src/private.rs":"87c96ed2002bd567bf02535b4c6e8e3f22827afb2dd92ee17d91cfb45bc6072c"},"package":"a9f841e9637adec70838c537cae52cb4c751cc6514ad05669b51d107c2021c79"}
\ No newline at end of file
+{"files":{".cargo-ok":"e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",".travis.yml":"b71b9a6f84b9263b2b89be6ec90dff5920ee68cf9e5768d73ed71957de2d0670","COPYRIGHT":"ec82b96487e9e778ee610c7ab245162464782cfa1f555c2299333f8dbe5c036a","Cargo.toml":"7ec2f5418172e650baa8dfd874a0f337370d512f6abcbf5c86b8c8535156f2f6","LICENSE-APACHE":"a60eea817514531668d7e00765731449fe14d059d3249e0bc93b36de45f759f2","LICENSE-MIT":"62065228e42caebca7e7d7db1204cbb867033de5982ca4009928915e4095f3a3","README.md":"4a45abeb1e684e30bb361dfa7db59189423348e18d310cbae694b7c8c57cd86a","src/base.rs":"3f0a5be163f86c864c995c6beb081d2943263a2fca28491b9fe0eaea5e3ff401","src/color_space.rs":"deef20773dc8ef0e75654ca730876ee25b2914539a0dc587755dfd5301584da7","src/context.rs":"4a19c23444d1d1df8bba4228053636c89d9209e7abe255f774afc0ab6317dd72","src/data_provider.rs":"a5dd6593af681aace97ef9a2eed006d11fe44039d40d37c1780d01969cd145fe","src/display.rs":"fe253013b5c8e2a57a242dec90236753011e8d99b827a7bc404b1a483f9f0332","src/event.rs":"36052e6ea7db7606060e088e507499d4e4125825513735b495062d991bbad8e7","src/event_source.rs":"8a8282e944208db52839a56f0d55d687358264f1458eebf6fefcd9e42c7ddeac","src/font.rs":"27fc377a1e2bb08cada16da7ff0ff6c13d9cfaee0a33524580987549e6b02e3e","src/geometry.rs":"58758d6f3b58fb472f14d4ec694882d41e5e1f6dbb1ed766f241ad39eff56c36","src/image.rs":"de0797097d52dd8fd2bc5816357ba614b734a69834155c39c17f90468bb1bf7b","src/lib.rs":"e46cd5770ef451f7502a6dd39bd0f14632634e10abd668700fcdea35e6e48212","src/private.rs":"87c96ed2002bd567bf02535b4c6e8e3f22827afb2dd92ee17d91cfb45bc6072c"},"package":"2fd47addfc77b7e574d24e5434f95bb64a863769dfd4f1d451ca4ff5530ba01a"}
\ No newline at end of file
--- a/third_party/rust/core-graphics/Cargo.toml
+++ b/third_party/rust/core-graphics/Cargo.toml
@@ -1,17 +1,32 @@
+# THIS FILE IS AUTOMATICALLY GENERATED BY CARGO
+#
+# When uploading crates to the registry Cargo will automatically
+# "normalize" Cargo.toml files for maximal compatibility
+# with all versions of Cargo and also rewrite `path` dependencies
+# to registry (e.g. crates.io) dependencies
+#
+# If you believe there's an error in this file please file an
+# issue against the rust-lang/cargo repository. If you're
+# editing this file be aware that the upstream Cargo.toml
+# will likely look very different (and much more reasonable)
+
 [package]
 name = "core-graphics"
+version = "0.9.1"
+authors = ["The Servo Project Developers"]
 description = "Bindings to Core Graphics for OS X"
 homepage = "https://github.com/servo/core-graphics-rs"
+license = "MIT / Apache-2.0"
 repository = "https://github.com/servo/core-graphics-rs"
-version = "0.8.1"
-authors = ["The Servo Project Developers"]
-license = "MIT / Apache-2.0"
+[dependencies.libc]
+version = "0.2"
+
+[dependencies.core-foundation]
+version = "0.4"
+
+[dependencies.bitflags]
+version = "0.9"
 
 [features]
 default = []
 elcapitan = []
-
-[dependencies]
-libc = "0.2"
-core-foundation = "0.3"
-bitflags = "0.8"
--- a/third_party/rust/core-graphics/src/base.rs
+++ b/third_party/rust/core-graphics/src/base.rs
@@ -23,17 +23,19 @@ pub type boolean_t = libc::c_uint;
 
 #[cfg(target_pointer_width = "64")]
 pub type CGFloat = libc::c_double;
 #[cfg(not(target_pointer_width = "64"))]
 pub type CGFloat = libc::c_float;
 
 pub type CGError = libc::int32_t;
 
-pub type CGAffineTransform = ();
+// This is an enum due to zero-sized types warnings.
+// For more details see https://github.com/rust-lang/rust/issues/27303
+pub enum CGAffineTransform {}
 
 pub const kCGImageAlphaNone: u32 = 0;
 pub const kCGImageAlphaPremultipliedLast: u32 = 1;
 pub const kCGImageAlphaPremultipliedFirst: u32 = 2;
 pub const kCGImageAlphaLast: u32 = 3;
 pub const kCGImageAlphaFirst: u32 = 4;
 pub const kCGImageAlphaNoneSkipLast: u32 = 5;
 pub const kCGImageAlphaNoneSkipFirst: u32 = 6;
--- a/third_party/rust/core-graphics/src/color_space.rs
+++ b/third_party/rust/core-graphics/src/color_space.rs
@@ -5,18 +5,19 @@
 // http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
 // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
 use core_foundation::base::{CFRelease, CFRetain, CFTypeID, CFTypeRef, TCFType};
 use std::mem;
 
-#[repr(C)]
-pub struct __CGColorSpace;
+// This is an enum due to zero-sized types warnings.
+// For more details see https://github.com/rust-lang/rust/issues/27303
+pub enum __CGColorSpace {}
 
 pub type CGColorSpaceRef = *const __CGColorSpace;
 
 pub struct CGColorSpace {
     obj: CGColorSpaceRef,
 }
 
 impl Drop for CGColorSpace {
--- a/third_party/rust/core-graphics/src/context.rs
+++ b/third_party/rust/core-graphics/src/context.rs
@@ -23,18 +23,19 @@ pub enum CGTextDrawingMode {
     CGTextStroke,
     CGTextFillStroke,
     CGTextInvisible,
     CGTextFillClip,
     CGTextStrokeClip,
     CGTextClip
 }
 
-#[repr(C)]
-pub struct __CGContext;
+// This is an enum due to zero-sized types warnings.
+// For more details see https://github.com/rust-lang/rust/issues/27303
+pub enum __CGContext {}
 
 pub type CGContextRef = *const __CGContext;
 
 pub struct CGContext {
     obj: CGContextRef,
 }
 
 impl Drop for CGContext {
--- a/third_party/rust/core-graphics/src/data_provider.rs
+++ b/third_party/rust/core-graphics/src/data_provider.rs
@@ -21,18 +21,19 @@ pub type CGDataProviderSkipBytesCallback
 pub type CGDataProviderSkipForwardCallback = Option<unsafe extern fn (*mut c_void, off_t) -> off_t>;
 
 pub type CGDataProviderGetBytePointerCallback = Option<unsafe extern fn (*mut c_void) -> *mut c_void>;
 pub type CGDataProviderGetBytesAtOffsetCallback = Option<unsafe extern fn (*mut c_void, *mut c_void, size_t, size_t)>;
 pub type CGDataProviderReleaseBytePointerCallback = Option<unsafe extern fn (*mut c_void, *const c_void)>;
 pub type CGDataProviderReleaseDataCallback = Option<unsafe extern fn (*mut c_void, *const c_void, size_t)>;
 pub type CGDataProviderGetBytesAtPositionCallback = Option<unsafe extern fn (*mut c_void, *mut c_void, off_t, size_t)>;
 
-#[repr(C)]
-pub struct __CGDataProvider;
+// This is an enum due to zero-sized types warnings.
+// For more details see https://github.com/rust-lang/rust/issues/27303
+pub enum __CGDataProvider {}
 
 pub type CGDataProviderRef = *const __CGDataProvider;
 
 pub struct CGDataProvider {
     obj: CGDataProviderRef,
 }
 
 impl Drop for CGDataProvider {
--- a/third_party/rust/core-graphics/src/display.rs
+++ b/third_party/rust/core-graphics/src/display.rs
@@ -71,24 +71,27 @@ extern {
     pub fn CGDisplayVendorNumber(display: CGDirectDisplayID) -> libc::uint32_t;
     pub fn CGGetActiveDisplayList(max_displays: libc::uint32_t,
                                   active_displays: *mut CGDirectDisplayID,
                                   display_count: *mut libc::uint32_t) -> CGError;
     pub fn CGDisplayModelNumber(display: CGDirectDisplayID) -> libc::uint32_t;
     pub fn CGDisplayPixelsHigh(display: CGDirectDisplayID) -> libc::size_t;
     pub fn CGDisplayPixelsWide(display: CGDirectDisplayID) -> libc::size_t;
     pub fn CGDisplayBounds(display: CGDirectDisplayID) -> CGRect;
+    pub fn CGDisplayCreateImage(display: CGDirectDisplayID) -> CGImageRef;
 
     // mouse stuff
     pub fn CGDisplayHideCursor(display: CGDirectDisplayID) -> CGError;
     pub fn CGDisplayShowCursor(display: CGDirectDisplayID) -> CGError;
     pub fn CGDisplayMoveCursorToPoint(display: CGDirectDisplayID, point: CGPoint) -> CGError;
     pub fn CGWarpMouseCursorPosition(point: CGPoint) -> CGError;
     pub fn CGAssociateMouseAndMouseCursorPosition(connected: bool) -> CGError;
 
     // Window Services Reference
     pub fn CGWindowListCopyWindowInfo(option: CGWindowListOption, relativeToWindow: CGWindowID ) -> CFArrayRef;
     pub fn CGWindowListCreateImage(screenBounds: CGRect,
                                    listOptions: CGWindowListOption,
                                    windowId: CGWindowID,
                                    imageOptions: CGWindowImageOption) -> CGImageRef;
-
+    pub fn CGWindowListCreateImageFromArray(screenBounds: CGRect,
+                                            windowArray: CFArrayRef,
+                                            imageOptions: CGWindowImageOption) -> CGImageRef;
 }
--- a/third_party/rust/core-graphics/src/event.rs
+++ b/third_party/rust/core-graphics/src/event.rs
@@ -7,35 +7,36 @@ use std::mem;
 use std::ptr;
 
 pub type CGKeyCode = libc::uint16_t;
 
 /// Flags for events
 ///
 /// [Ref](http://opensource.apple.com/source/IOHIDFamily/IOHIDFamily-700/IOHIDSystem/IOKit/hidsystem/IOLLEvent.h)
 bitflags! {
-    pub flags CGEventFlags: u64 {
-        const CGEventFlagNull = 0,
+    #[repr(C)]
+    pub struct CGEventFlags: u64 {
+        const CGEventFlagNull = 0;
 
         // Device-independent modifier key bits.
-        const CGEventFlagAlphaShift = 0x00010000,
-        const CGEventFlagShift = 0x00020000,
-        const CGEventFlagControl = 0x00040000,
-        const CGEventFlagAlternate = 0x00080000,
-        const CGEventFlagCommand = 0x00100000,
+        const CGEventFlagAlphaShift = 0x00010000;
+        const CGEventFlagShift = 0x00020000;
+        const CGEventFlagControl = 0x00040000;
+        const CGEventFlagAlternate = 0x00080000;
+        const CGEventFlagCommand = 0x00100000;
 
         // Special key identifiers.
-        const CGEventFlagHelp = 0x00400000,
-        const CGEventFlagSecondaryFn = 0x00800000,
+        const CGEventFlagHelp = 0x00400000;
+        const CGEventFlagSecondaryFn = 0x00800000;
 
         // Identifies key events from numeric keypad area on extended keyboards.
-        const CGEventFlagNumericPad = 0x00200000,
+        const CGEventFlagNumericPad = 0x00200000;
 
         // Indicates if mouse/pen movement events are not being coalesced
-        const CGEventFlagNonCoalesced = 0x00000100,
+        const CGEventFlagNonCoalesced = 0x00000100;
     }
 }
 
 /// Constants that specify the different types of input events.
 ///
 /// [Ref](http://opensource.apple.com/source/IOHIDFamily/IOHIDFamily-700/IOHIDSystem/IOKit/hidsystem/IOLLEvent.h)
 #[repr(C)]
 #[derive(Clone, Copy, Debug)]
@@ -83,18 +84,19 @@ pub enum CGMouseButton {
 #[repr(C)]
 #[derive(Clone, Copy, Debug)]
 pub enum CGEventTapLocation {
     HID,
     Session,
     AnnotatedSession,
 }
 
-#[repr(C)]
-pub struct __CGEvent;
+// This is an enum due to zero-sized types warnings.
+// For more details see https://github.com/rust-lang/rust/issues/27303
+pub enum __CGEvent {}
 
 pub type CGEventRef = *const __CGEvent;
 
 pub struct CGEvent {
     obj: CGEventRef,
 }
 
 impl Clone for CGEvent {
--- a/third_party/rust/core-graphics/src/event_source.rs
+++ b/third_party/rust/core-graphics/src/event_source.rs
@@ -7,18 +7,19 @@ use std::ptr;
 #[repr(C)]
 #[derive(Clone, Copy, Debug)]
 pub enum CGEventSourceStateID {
     Private = -1,
     CombinedSessionState = 0,
     HIDSystemState = 1,
 }
 
-#[repr(C)]
-pub struct __CGEventSource;
+// This is an enum due to zero-sized types warnings.
+// For more details see https://github.com/rust-lang/rust/issues/27303
+pub enum __CGEventSource {}
 
 pub type CGEventSourceRef = *const __CGEventSource;
 
 pub struct CGEventSource {
     obj: CGEventSourceRef,
 }
 
 impl Clone for CGEventSource {
--- a/third_party/rust/core-graphics/src/font.rs
+++ b/third_party/rust/core-graphics/src/font.rs
@@ -12,18 +12,19 @@ use core_foundation::string::{CFString, 
 use data_provider::{CGDataProvider, CGDataProviderRef};
 
 use libc;
 use std::mem;
 use std::ptr;
 
 pub type CGGlyph = libc::c_ushort;
 
-#[repr(C)]
-pub struct __CGFont;
+// This is an enum due to zero-sized types warnings.
+// For more details see https://github.com/rust-lang/rust/issues/27303
+pub enum __CGFont {}
 
 pub type CGFontRef = *const __CGFont;
 
 pub struct CGFont {
     obj: CGFontRef,
 }
 
 unsafe impl Send for CGFont {}
--- a/third_party/rust/core-graphics/src/geometry.rs
+++ b/third_party/rust/core-graphics/src/geometry.rs
@@ -80,23 +80,41 @@ impl CGRect {
             ffi::CGRectMakeWithDictionaryRepresentation(dict.as_concrete_TypeRef(), &mut rect)
         };
         if result == 0 {
             None
         } else {
             Some(rect)
         }
     }
+
+    #[inline]
+    pub fn is_empty(&self) -> bool {
+        unsafe {
+            // I use one, as it seems that `YES` is not available from this crate.
+            ffi::CGRectIsEmpty(*self) == 1
+        }
+    }
+
+    #[inline]
+    pub fn is_intersects(&self, other: &CGRect) -> bool {
+        unsafe {
+            // I use one, as it seems that `YES` is not available from this crate.
+            ffi::CGRectIntersectsRect(*self, *other) == 1
+        }
+    }
 }
 
 mod ffi {
     use base::{CGFloat, boolean_t};
     use geometry::CGRect;
     use core_foundation::dictionary::CFDictionaryRef;
 
     #[link(name = "ApplicationServices", kind = "framework")]
     extern {
         pub fn CGRectInset(rect: CGRect, dx: CGFloat, dy: CGFloat) -> CGRect;
         pub fn CGRectMakeWithDictionaryRepresentation(dict: CFDictionaryRef,
                                                       rect: *mut CGRect) -> boolean_t;
+        pub fn CGRectIsEmpty(rect: CGRect) -> boolean_t;
+        pub fn CGRectIntersectsRect(rect1: CGRect, rect2: CGRect) -> boolean_t;
     }
 }
 
--- a/third_party/rust/core-graphics/src/image.rs
+++ b/third_party/rust/core-graphics/src/image.rs
@@ -22,18 +22,19 @@ pub enum CGImageAlphaInfo {
 pub enum CGImageByteOrderInfo {
     CGImageByteOrderMask = 0x7000,
     CGImageByteOrder16Little = (1 << 12),
     CGImageByteOrder32Little = (2 << 12),
     CGImageByteOrder16Big = (3 << 12),
     CGImageByteOrder32Big = (4 << 12)
 }
 
-#[repr(C)]
-pub struct __CGImage;
+// This is an enum due to zero-sized types warnings.
+// For more details see https://github.com/rust-lang/rust/issues/27303
+pub enum __CGImage {}
 
 pub type CGImageRef = *const __CGImage;
 
 pub struct CGImage {
     obj: CGImageRef,
 }
 
 impl Drop for CGImage {
--- a/third_party/rust/core-graphics/src/lib.rs
+++ b/third_party/rust/core-graphics/src/lib.rs
@@ -3,17 +3,16 @@
 //
 // Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
 // http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
 // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
 extern crate libc;
-#[macro_use]
 extern crate core_foundation;
 
 #[macro_use]
 extern crate bitflags;
 
 pub mod base;
 pub mod color_space;
 pub mod context;
--- a/third_party/rust/core-text/.cargo-checksum.json
+++ b/third_party/rust/core-text/.cargo-checksum.json
@@ -1,1 +1,1 @@
-{"files":{".cargo-ok":"e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",".travis.yml":"6aad961651169d31d79c0595624d1777b5c4cbb4cf2bed9a126c7e72d29411fd","COPYRIGHT":"ec82b96487e9e778ee610c7ab245162464782cfa1f555c2299333f8dbe5c036a","Cargo.toml":"9e9639b287ac1c3d14c28a4467d029a9d642f5d996297dc557f6274eaa05a8f3","LICENSE-APACHE":"a60eea817514531668d7e00765731449fe14d059d3249e0bc93b36de45f759f2","LICENSE-MIT":"62065228e42caebca7e7d7db1204cbb867033de5982ca4009928915e4095f3a3","README.md":"0c82015d302c9937e6376debd961350afeaeb6dde228aac95e3a3115c5813613","src/font.rs":"d73139838b7dc15319645a3b03bd3692a3b453fcd6304c7ebdeb454166e22db2","src/font_collection.rs":"5a8f5a17aec1dccf858ef1205c21d035fc5a8c7ac8ed7c089896a1f779bef126","src/font_descriptor.rs":"f932e5626ad8f93d88d82ed3bec9b249bdeccf3c44b1d5abfaed91e018e537d9","src/font_manager.rs":"de5e22620528322d6811d01f03975c53b676ec743297590de5e17a45393df0f1","src/lib.rs":"b1fc720a9ab7ae4f054f0767e05ba5640b2d9fc8c34d05ae04f25b9dd44f6b81"},"package":"16ce16d9ed00181016c11ff48e561314bec92bfbce9fe48f319366618d4e5de6"}
\ No newline at end of file
+{"files":{".cargo-ok":"e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",".travis.yml":"6aad961651169d31d79c0595624d1777b5c4cbb4cf2bed9a126c7e72d29411fd","COPYRIGHT":"ec82b96487e9e778ee610c7ab245162464782cfa1f555c2299333f8dbe5c036a","Cargo.toml":"227a4fb6741d1bcf824afe7cfff7a716a8983543a5c4939a16edbf8ef7eab30d","LICENSE-APACHE":"a60eea817514531668d7e00765731449fe14d059d3249e0bc93b36de45f759f2","LICENSE-MIT":"62065228e42caebca7e7d7db1204cbb867033de5982ca4009928915e4095f3a3","README.md":"0c82015d302c9937e6376debd961350afeaeb6dde228aac95e3a3115c5813613","src/font.rs":"d73139838b7dc15319645a3b03bd3692a3b453fcd6304c7ebdeb454166e22db2","src/font_collection.rs":"5a8f5a17aec1dccf858ef1205c21d035fc5a8c7ac8ed7c089896a1f779bef126","src/font_descriptor.rs":"f932e5626ad8f93d88d82ed3bec9b249bdeccf3c44b1d5abfaed91e018e537d9","src/font_manager.rs":"de5e22620528322d6811d01f03975c53b676ec743297590de5e17a45393df0f1","src/lib.rs":"b1fc720a9ab7ae4f054f0767e05ba5640b2d9fc8c34d05ae04f25b9dd44f6b81"},"package":"2a23bef779fab70e5e6af23e36eed03a48e1c1687dea8929505d405ea48d1f5e"}
\ No newline at end of file
--- a/third_party/rust/core-text/Cargo.toml
+++ b/third_party/rust/core-text/Cargo.toml
@@ -1,20 +1,30 @@
+# THIS FILE IS AUTOMATICALLY GENERATED BY CARGO
+#
+# When uploading crates to the registry Cargo will automatically
+# "normalize" Cargo.toml files for maximal compatibility
+# with all versions of Cargo and also rewrite `path` dependencies
+# to registry (e.g. crates.io) dependencies
+#
+# If you believe there's an error in this file please file an
+# issue against the rust-lang/cargo repository. If you're
+# editing this file be aware that the upstream Cargo.toml
+# will likely look very different (and much more reasonable)
+
 [package]
 name = "core-text"
-version = "6.1.0"
+version = "7.0.0"
 authors = ["The Servo Project Developers"]
 description = "Bindings to the Core Text framework."
 license = "MIT/Apache-2.0"
 repository = "https://github.com/servo/core-text-rs"
+[dependencies.libc]
+version = "0.2"
 
 [features]
 default = ["mountainlion"]
-# For OS X 10.7 compat, exclude this feature. It will exclude some things from
-# the exposed APIs in the crate.
 mountainlion = []
+[target.x86_64-apple-darwin.dependencies.core-foundation]
+version = "0.4"
 
-[dependencies]
-libc = "0.2"
-
-[target.x86_64-apple-darwin.dependencies]
-core-foundation = "0.3"
-core-graphics = "0.8"
+[target.x86_64-apple-darwin.dependencies.core-graphics]
+version = "0.9"
--- a/toolkit/library/gtest/rust/Cargo.lock
+++ b/toolkit/library/gtest/rust/Cargo.lock
@@ -237,48 +237,56 @@ version = "0.1.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "either 1.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "scopeguard 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "core-foundation"
-version = "0.3.0"
+version = "0.4.4"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "core-foundation-sys 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)",
+ "core-foundation-sys 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "libc 0.2.24 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "core-foundation-sys"
 version = "0.3.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "libc 0.2.24 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
-name = "core-graphics"
-version = "0.8.1"
+name = "core-foundation-sys"
+version = "0.4.4"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "bitflags 0.8.2 (registry+https://github.com/rust-lang/crates.io-index)",
- "core-foundation 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.24 (registry+https://github.com/rust-lang/crates.io-index)",
+]
+
+[[package]]
+name = "core-graphics"
+version = "0.9.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+dependencies = [
+ "bitflags 0.9.1 (registry+https://github.com/rust-lang/crates.io-index)",
+ "core-foundation 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "libc 0.2.24 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "core-text"
-version = "6.1.0"
+version = "7.0.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "core-foundation 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "core-graphics 0.8.1 (registry+https://github.com/rust-lang/crates.io-index)",
+ "core-foundation 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)",
+ "core-graphics 0.9.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "libc 0.2.24 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "cssparser"
 version = "0.21.2"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
@@ -1544,50 +1552,50 @@ source = "registry+https://github.com/ru
 dependencies = [
  "kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "same-file 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "webrender"
-version = "0.51.0"
+version = "0.52.0"
 dependencies = [
  "app_units 0.5.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "bincode 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "bitflags 0.9.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "byteorder 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "core-foundation 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "core-graphics 0.8.1 (registry+https://github.com/rust-lang/crates.io-index)",
- "core-text 6.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "core-foundation 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)",
+ "core-graphics 0.9.1 (registry+https://github.com/rust-lang/crates.io-index)",
+ "core-text 7.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "dwrote 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.15.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "freetype 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "fxhash 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "gamma-lut 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "gleam 0.4.8 (registry+https://github.com/rust-lang/crates.io-index)",
  "lazy_static 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "num-traits 0.1.37 (registry+https://github.com/rust-lang/crates.io-index)",
  "plane-split 0.6.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "rayon 0.8.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "thread_profiler 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "time 0.1.36 (registry+https://github.com/rust-lang/crates.io-index)",
- "webrender_api 0.51.0",
+ "webrender_api 0.52.0",
 ]
 
 [[package]]
 name = "webrender_api"
-version = "0.51.0"
+version = "0.52.0"
 dependencies = [
  "app_units 0.5.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "bincode 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "byteorder 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "core-foundation 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "core-graphics 0.8.1 (registry+https://github.com/rust-lang/crates.io-index)",
+ "core-foundation 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)",
+ "core-graphics 0.9.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "dwrote 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.15.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "fxhash 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "heapsize 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 1.0.8 (registry+https://github.com/rust-lang/crates.io-index)",
  "time 0.1.36 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
@@ -1596,18 +1604,18 @@ name = "webrender_bindings"
 version = "0.1.0"
 dependencies = [
  "app_units 0.5.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "bincode 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.15.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "gleam 0.4.8 (registry+https://github.com/rust-lang/crates.io-index)",
  "rayon 0.8.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "thread_profiler 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
- "webrender 0.51.0",
- "webrender_api 0.51.0",
+ "webrender 0.52.0",
+ "webrender_api 0.52.0",
 ]
 
 [[package]]
 name = "winapi"
 version = "0.2.8"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 
 [[package]]
@@ -1651,20 +1659,21 @@ dependencies = [
 "checksum bitreader 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)" = "80b13e2ab064ff3aa0bdbf1eff533f9822dc37899821f5f98c67f263eab51707"
 "checksum boxfnonce 0.0.3 (registry+https://github.com/rust-lang/crates.io-index)" = "8380105befe91099e6f69206164072c05bc92427ff6aa8a5171388317346dd75"
 "checksum byteorder 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "c40977b0ee6b9885c9013cd41d9feffdd22deb3bb4dc3a71d901cc7a77de18c8"
 "checksum cexpr 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "393a5f0088efbe41f9d1fcd062f24e83c278608420e62109feb2c8abee07de7d"
 "checksum cfg-if 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "de1e760d7b6535af4241fca8bd8adf68e2e7edacc6b29f5d399050c5e48cf88c"
 "checksum clang-sys 0.19.0 (registry+https://github.com/rust-lang/crates.io-index)" = "611ec2e3a7623afd8a8c0d027887b6b55759d894abbf5fe11b9dc11b50d5b49a"
 "checksum clap 2.24.2 (registry+https://github.com/rust-lang/crates.io-index)" = "6b8f69e518f967224e628896b54e41ff6acfb4dcfefc5076325c36525dac900f"
 "checksum coco 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "c06169f5beb7e31c7c67ebf5540b8b472d23e3eade3b2ec7d1f5b504a85f91bd"
-"checksum core-foundation 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)" = "f51ce3b8ebe311c56de14231eb57572c15abebd2d32b3bcb99bcdb9c101f5ac3"
+"checksum core-foundation 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)" = "5909502e547762013619f4c4e01cc7393c20fe2d52d7fa471c1210adb2320dc7"
 "checksum core-foundation-sys 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)" = "41115a6aa5d3e1e5ef98148373f25971d1fad53818553f216495f9e67e90a624"
-"checksum core-graphics 0.8.1 (registry+https://github.com/rust-lang/crates.io-index)" = "a9f841e9637adec70838c537cae52cb4c751cc6514ad05669b51d107c2021c79"
-"checksum core-text 6.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "16ce16d9ed00181016c11ff48e561314bec92bfbce9fe48f319366618d4e5de6"
+"checksum core-foundation-sys 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)" = "bc9fb3d6cb663e6fd7cf1c63f9b144ee2b1e4a78595a0451dd34bff85b9a3387"
+"checksum core-graphics 0.9.1 (registry+https://github.com/rust-lang/crates.io-index)" = "2fd47addfc77b7e574d24e5434f95bb64a863769dfd4f1d451ca4ff5530ba01a"
+"checksum core-text 7.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "2a23bef779fab70e5e6af23e36eed03a48e1c1687dea8929505d405ea48d1f5e"
 "checksum cssparser 0.21.2 (registry+https://github.com/rust-lang/crates.io-index)" = "05012fcdbdeb4c6f59f67db47c1f879929339274a691ee1fb90c26b297783629"
 "checksum cssparser-macros 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)" = "079adec4af52bb5275eadd004292028c79eb3c5f5b4ee8086a36d4197032f6df"
 "checksum darling 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "9861a8495606435477df581bc858ccf15a3469747edf175b94a4704fd9aaedac"
 "checksum darling_core 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "1486a8b00b45062c997f767738178b43219133dd0c8c826cb811e60563810821"
 "checksum darling_macro 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "8a86ec160aa0c3dd492dd4a14ec8104ad8f1a9400a820624db857998cc1f80f9"
 "checksum dbghelp-sys 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "97590ba53bcb8ac28279161ca943a924d1fd4a8fb3fa63302591647c4fc5b850"
 "checksum dtoa 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)" = "09c3753c3db574d215cba4ea76018483895d7bff25a31b49ba45db21c48e50ab"
 "checksum dtoa-short 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)" = "fe6f727b406462fd57c95fed84d1b0dbfb5f0136fcac005adba9ea0367c05cc8"
--- a/toolkit/library/rust/Cargo.lock
+++ b/toolkit/library/rust/Cargo.lock
@@ -235,48 +235,56 @@ version = "0.1.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "either 1.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "scopeguard 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "core-foundation"
-version = "0.3.0"
+version = "0.4.4"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "core-foundation-sys 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)",
+ "core-foundation-sys 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "libc 0.2.24 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "core-foundation-sys"
 version = "0.3.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "libc 0.2.24 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
-name = "core-graphics"
-version = "0.8.1"
+name = "core-foundation-sys"
+version = "0.4.4"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "bitflags 0.8.2 (registry+https://github.com/rust-lang/crates.io-index)",
- "core-foundation 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.24 (registry+https://github.com/rust-lang/crates.io-index)",
+]
+
+[[package]]
+name = "core-graphics"
+version = "0.9.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+dependencies = [
+ "bitflags 0.9.1 (registry+https://github.com/rust-lang/crates.io-index)",
+ "core-foundation 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "libc 0.2.24 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "core-text"
-version = "6.1.0"
+version = "7.0.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "core-foundation 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "core-graphics 0.8.1 (registry+https://github.com/rust-lang/crates.io-index)",
+ "core-foundation 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)",
+ "core-graphics 0.9.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "libc 0.2.24 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "cssparser"
 version = "0.21.2"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
@@ -1531,50 +1539,50 @@ source = "registry+https://github.com/ru
 dependencies = [
  "kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "same-file 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "webrender"
-version = "0.51.0"
+version = "0.52.0"
 dependencies = [
  "app_units 0.5.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "bincode 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "bitflags 0.9.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "byteorder 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "core-foundation 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "core-graphics 0.8.1 (registry+https://github.com/rust-lang/crates.io-index)",
- "core-text 6.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "core-foundation 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)",
+ "core-graphics 0.9.1 (registry+https://github.com/rust-lang/crates.io-index)",
+ "core-text 7.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "dwrote 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.15.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "freetype 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "fxhash 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "gamma-lut 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "gleam 0.4.8 (registry+https://github.com/rust-lang/crates.io-index)",
  "lazy_static 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "num-traits 0.1.37 (registry+https://github.com/rust-lang/crates.io-index)",
  "plane-split 0.6.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "rayon 0.8.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "thread_profiler 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "time 0.1.36 (registry+https://github.com/rust-lang/crates.io-index)",
- "webrender_api 0.51.0",
+ "webrender_api 0.52.0",
 ]
 
 [[package]]
 name = "webrender_api"
-version = "0.51.0"
+version = "0.52.0"
 dependencies = [
  "app_units 0.5.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "bincode 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "byteorder 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "core-foundation 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "core-graphics 0.8.1 (registry+https://github.com/rust-lang/crates.io-index)",
+ "core-foundation 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)",
+ "core-graphics 0.9.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "dwrote 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.15.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "fxhash 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "heapsize 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 1.0.8 (registry+https://github.com/rust-lang/crates.io-index)",
  "time 0.1.36 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
@@ -1583,18 +1591,18 @@ name = "webrender_bindings"
 version = "0.1.0"
 dependencies = [
  "app_units 0.5.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "bincode 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.15.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "gleam 0.4.8 (registry+https://github.com/rust-lang/crates.io-index)",
  "rayon 0.8.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "thread_profiler 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
- "webrender 0.51.0",
- "webrender_api 0.51.0",
+ "webrender 0.52.0",
+ "webrender_api 0.52.0",
 ]
 
 [[package]]
 name = "winapi"
 version = "0.2.8"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 
 [[package]]
@@ -1638,20 +1646,21 @@ dependencies = [
 "checksum bitreader 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)" = "80b13e2ab064ff3aa0bdbf1eff533f9822dc37899821f5f98c67f263eab51707"
 "checksum boxfnonce 0.0.3 (registry+https://github.com/rust-lang/crates.io-index)" = "8380105befe91099e6f69206164072c05bc92427ff6aa8a5171388317346dd75"
 "checksum byteorder 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "c40977b0ee6b9885c9013cd41d9feffdd22deb3bb4dc3a71d901cc7a77de18c8"
 "checksum cexpr 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "393a5f0088efbe41f9d1fcd062f24e83c278608420e62109feb2c8abee07de7d"
 "checksum cfg-if 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "de1e760d7b6535af4241fca8bd8adf68e2e7edacc6b29f5d399050c5e48cf88c"
 "checksum clang-sys 0.19.0 (registry+https://github.com/rust-lang/crates.io-index)" = "611ec2e3a7623afd8a8c0d027887b6b55759d894abbf5fe11b9dc11b50d5b49a"
 "checksum clap 2.24.2 (registry+https://github.com/rust-lang/crates.io-index)" = "6b8f69e518f967224e628896b54e41ff6acfb4dcfefc5076325c36525dac900f"
 "checksum coco 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "c06169f5beb7e31c7c67ebf5540b8b472d23e3eade3b2ec7d1f5b504a85f91bd"
-"checksum core-foundation 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)" = "f51ce3b8ebe311c56de14231eb57572c15abebd2d32b3bcb99bcdb9c101f5ac3"
+"checksum core-foundation 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)" = "5909502e547762013619f4c4e01cc7393c20fe2d52d7fa471c1210adb2320dc7"
 "checksum core-foundation-sys 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)" = "41115a6aa5d3e1e5ef98148373f25971d1fad53818553f216495f9e67e90a624"
-"checksum core-graphics 0.8.1 (registry+https://github.com/rust-lang/crates.io-index)" = "a9f841e9637adec70838c537cae52cb4c751cc6514ad05669b51d107c2021c79"
-"checksum core-text 6.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "16ce16d9ed00181016c11ff48e561314bec92bfbce9fe48f319366618d4e5de6"
+"checksum core-foundation-sys 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)" = "bc9fb3d6cb663e6fd7cf1c63f9b144ee2b1e4a78595a0451dd34bff85b9a3387"
+"checksum core-graphics 0.9.1 (registry+https://github.com/rust-lang/crates.io-index)" = "2fd47addfc77b7e574d24e5434f95bb64a863769dfd4f1d451ca4ff5530ba01a"
+"checksum core-text 7.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "2a23bef779fab70e5e6af23e36eed03a48e1c1687dea8929505d405ea48d1f5e"
 "checksum cssparser 0.21.2 (registry+https://github.com/rust-lang/crates.io-index)" = "05012fcdbdeb4c6f59f67db47c1f879929339274a691ee1fb90c26b297783629"
 "checksum cssparser-macros 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)" = "079adec4af52bb5275eadd004292028c79eb3c5f5b4ee8086a36d4197032f6df"
 "checksum darling 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "9861a8495606435477df581bc858ccf15a3469747edf175b94a4704fd9aaedac"
 "checksum darling_core 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "1486a8b00b45062c997f767738178b43219133dd0c8c826cb811e60563810821"
 "checksum darling_macro 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "8a86ec160aa0c3dd492dd4a14ec8104ad8f1a9400a820624db857998cc1f80f9"
 "checksum dbghelp-sys 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "97590ba53bcb8ac28279161ca943a924d1fd4a8fb3fa63302591647c4fc5b850"
 "checksum dtoa 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)" = "09c3753c3db574d215cba4ea76018483895d7bff25a31b49ba45db21c48e50ab"
 "checksum dtoa-short 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)" = "fe6f727b406462fd57c95fed84d1b0dbfb5f0136fcac005adba9ea0367c05cc8"