From 7b0618c20b5348230304323efd75bc65361bbe1e Mon Sep 17 00:00:00 2001 From: Thomas Ghysels Date: Mon, 6 Aug 2018 00:50:15 +0200 Subject: [PATCH] Add hyper dependencies --- BUILD.gn | 1 + Cargo.toml | 4 ++ build_extra/rust/BUILD.gn | 122 ++++++++++++++++++++++++++++++++++++++ third_party | 2 +- 4 files changed, 128 insertions(+), 1 deletion(-) diff --git a/BUILD.gn b/BUILD.gn index 7d283ab346..95640c7c88 100644 --- a/BUILD.gn +++ b/BUILD.gn @@ -35,6 +35,7 @@ config("deno_config") { } main_extern = [ + "$rust_build:hyper", "$rust_build:futures", "$rust_build:libc", "$rust_build:log", diff --git a/Cargo.toml b/Cargo.toml index ea3efec29b..7d73ede4c1 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -14,3 +14,7 @@ log = "0.4.3" sha1 = "0.6.0" tempfile = "3" tokio = {git = "https://github.com/tokio-rs/tokio.git", rev = "5d0d2a2e1214f856993df6965825c89bfcaa879e"} +hyper = "0.12.8" +crossbeam-deque = "= 0.5.1" +crossbeam-epoch = "= 0.5.1" +futures-core = "0.2.1" diff --git a/build_extra/rust/BUILD.gn b/build_extra/rust/BUILD.gn index 3f43a48501..6cc239fc8e 100644 --- a/build_extra/rust/BUILD.gn +++ b/build_extra/rust/BUILD.gn @@ -135,6 +135,8 @@ rust_crate("winapi") { "sspi", "std", "subauth", + "sysinfoapi", + "timezoneapi", "vadefs", "vcruntime", "winbase", @@ -342,6 +344,126 @@ rust_crate("num_cpus") { extern = [ ":libc" ] } +rust_crate("hyper") { + source_root = "$registry_github/hyper-0.12.8/src/lib.rs" + features = [ "runtime" ] + extern = [ + ":bytes", + ":futures", + ":futures_cpupool", + ":h2", + ":http", + ":httparse", + ":iovec", + ":itoa", + ":log", + ":net2", + ":time", + ":tokio", + ":tokio_executor", + ":tokio_io", + ":tokio_reactor", + ":tokio_tcp", + ":tokio_timer", + ":want", + ] +} + +rust_crate("tokio_core") { + source_root = "$registry_github/tokio-core-0.1.17/src/lib.rs" + extern = [ + ":mio", + ":futures", + ":tokio", + ":tokio_executor", + ":tokio_reactor", + ":tokio_timer", + ":tokio_io", + ":log", + ":iovec", + ":bytes", + ] +} + +rust_crate("h2") { + source_root = "$registry_github/h2-0.1.12/src/lib.rs" + extern = [ + ":byteorder", + ":bytes", + ":fnv", + ":futures", + ":http", + ":indexmap", + ":log", + ":slab", + ":string", + ":tokio_io", + ] +} + +rust_crate("http") { + source_root = "$registry_github/http-0.1.10/src/lib.rs" + extern = [ + ":bytes", + ":fnv", + ":itoa", + ] +} + +rust_crate("httparse") { + source_root = "$registry_github/httparse-1.3.2/src/lib.rs" +} + +rust_crate("fnv") { + source_root = "$registry_github/fnv-1.0.6/lib.rs" +} + +rust_crate("futures_core") { + source_root = "$registry_github/futures-core-0.2.1/src/lib.rs" +} + +rust_crate("futures_cpupool") { + source_root = "$registry_github/futures-cpupool-0.1.8/src/lib.rs" + extern = [ + ":futures", + ":num_cpus", + ] +} + +rust_crate("indexmap") { + source_root = "$registry_github/indexmap-1.0.1/src/lib.rs" +} + +rust_crate("itoa") { + source_root = "$registry_github/itoa-0.4.2/src/lib.rs" + features = [ "std" ] +} + +rust_crate("string") { + source_root = "$registry_github/string-0.1.1/src/lib.rs" +} + +rust_crate("time") { + source_root = "$registry_github/time-0.1.40/src/lib.rs" + extern = [ + ":libc", + ":winapi", + ] +} + +rust_crate("try_lock") { + source_root = "$registry_github/try-lock-0.2.2/src/lib.rs" +} + +rust_crate("want") { + source_root = "$registry_github/want-0.0.6/src/lib.rs" + extern = [ + ":futures", + ":try_lock", + ":log", + ] +} + tokio_root = "$crates/git/checkouts/tokio-377c595163f99a10/5d0d2a2/" rust_crate("tokio") { diff --git a/third_party b/third_party index cd487d4d50..a98b4d16fb 160000 --- a/third_party +++ b/third_party @@ -1 +1 @@ -Subproject commit cd487d4d507e8fb9b4ae8f114e98474e6f51bd8d +Subproject commit a98b4d16fb19682246a09f4c4a138e1362be3a94