summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--BUILD.gn1
-rw-r--r--Cargo.toml1
-rw-r--r--build_extra/rust/BUILD.gn99
-rw-r--r--src/main.rs1
m---------third_party0
5 files changed, 92 insertions, 10 deletions
diff --git a/BUILD.gn b/BUILD.gn
index 6c8172103..6f814c602 100644
--- a/BUILD.gn
+++ b/BUILD.gn
@@ -68,6 +68,7 @@ main_extern = [
"$rust_build:tokio_executor",
"$rust_build:tokio_fs",
"$rust_build:tokio_io",
+ "$rust_build:tokio_process",
"$rust_build:tokio_threadpool",
"$rust_build:url",
"//build_extra/flatbuffers/rust:flatbuffers",
diff --git a/Cargo.toml b/Cargo.toml
index 6c70dbe73..869a63c83 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -29,5 +29,6 @@ tokio = "0.1.11"
tokio-executor = "0.1.5"
tokio-fs = "0.1.4"
tokio-io = "0.1.10"
+tokio-process = "0.2.3"
tokio-threadpool = "0.1.8"
url = "1.7.1"
diff --git a/build_extra/rust/BUILD.gn b/build_extra/rust/BUILD.gn
index 05c93ed21..0db09052b 100644
--- a/build_extra/rust/BUILD.gn
+++ b/build_extra/rust/BUILD.gn
@@ -114,8 +114,8 @@ rust_crate("winapi") {
"basetsd",
"cfg",
"cfgmgr32",
- "consoleapi",
"combaseapi",
+ "consoleapi",
"errhandlingapi",
"excpt",
"fileapi",
@@ -123,6 +123,7 @@ rust_crate("winapi") {
"handleapi",
"in6addr",
"inaddr",
+ "ioapiset",
"knownfolders",
"ktmtypes",
"libloaderapi",
@@ -130,6 +131,7 @@ rust_crate("winapi") {
"minwinbase",
"minwindef",
"mstcpip",
+ "namedpipeapi",
"ntdef",
"ntsecapi",
"ntstatus",
@@ -149,7 +151,9 @@ rust_crate("winapi") {
"sspi",
"std",
"subauth",
+ "synchapi",
"sysinfoapi",
+ "threadpoollegacyapiset",
"timezoneapi",
"unknwnbase",
"vadefs",
@@ -158,8 +162,8 @@ rust_crate("winapi") {
"wincon",
"wincred",
"windef",
- "wingdi",
"winerror",
+ "wingdi",
"winnt",
"winreg",
"winsock2",
@@ -222,6 +226,10 @@ rust_crate("futures") {
]
}
+# TODO: 'mio' currently pulls in dozen of outdated winapi related dependencies.
+# 'miow' has already moved beyond that, and 'mio' itself has been upgraded on
+# the v0.7 branch some time ago. However there are no signs that version 0.7 is
+# going to be released any time soon. We should consider floating these patches.
rust_crate("mio") {
source_root = "$registry_github/mio-0.6.16/src/lib.rs"
features = [
@@ -234,15 +242,15 @@ rust_crate("mio") {
":lazycell",
":libc",
":log",
- ":miow",
":net2",
":slab",
]
-
- # TODO: Upgrade to a current version of the 'winapi' crate.
- # See https://github.com/denoland/deno/issues/484.
extern_version = [
{
+ crate_name = "miow"
+ crate_version = "0.2"
+ },
+ {
crate_name = "winapi"
crate_version = "0.2"
},
@@ -258,16 +266,16 @@ rust_crate("mio_uds") {
]
}
-rust_crate("miow") {
+# Outdated version of 'miow' - see comments by the 'mio' crate.
+rust_crate("miow-0.2") {
+ crate_name = "miow"
+ crate_version = "0.2"
source_root = "$registry_github/miow-0.2.1/src/lib.rs"
extern = [
":kernel32",
":net2",
":ws2_32",
]
-
- # TODO: Upgrade to a current version of the 'winapi' crate.
- # See https://github.com/denoland/deno/issues/484.
extern_version = [
{
crate_name = "winapi"
@@ -941,3 +949,74 @@ rust_crate("getopts") {
source_root = "$registry_github/getopts-0.2.18/src/lib.rs"
extern = [ ":unicode_width" ]
}
+
+rust_crate("arc_swap") {
+ source_root = "$registry_github/arc-swap-0.3.4/src/lib.rs"
+}
+
+rust_crate("mio_named_pipes") {
+ source_root = "$registry_github/mio-named-pipes-0.1.6/src/lib.rs"
+ extern = [
+ ":log",
+ ":mio",
+ ":miow",
+ ":winapi",
+ ]
+}
+
+rust_crate("miow") {
+ source_root = "$registry_github/miow-0.3.3/src/lib.rs"
+ extern = [
+ ":socket2",
+ ":winapi",
+ ]
+}
+
+rust_crate("signal_hook") {
+ source_root = "$registry_github/signal-hook-0.1.5/src/lib.rs"
+ extern = [
+ ":arc_swap",
+ ":libc",
+ ]
+}
+
+rust_crate("socket2") {
+ source_root = "$registry_github/socket2-0.3.8/src/lib.rs"
+ extern = [ ":winapi" ]
+}
+
+rust_crate("tokio_signal") {
+ source_root = "$registry_github/tokio-signal-0.2.6/src/lib.rs"
+ extern = [
+ ":futures",
+ ":libc",
+ ":mio",
+ ":mio_uds",
+ ":signal_hook",
+ ":tokio_executor",
+ ":tokio_io",
+ ":tokio_reactor",
+ ]
+}
+
+rust_crate("tokio_process") {
+ source_root = "$registry_github/tokio-process-0.2.3/src/lib.rs"
+ extern = [
+ ":futures",
+ ":mio",
+ ":tokio_io",
+ ":tokio_reactor",
+ ]
+
+ if (is_win) {
+ extern += [
+ ":mio_named_pipes",
+ ":winapi",
+ ]
+ } else {
+ extern += [
+ ":libc",
+ ":tokio_signal",
+ ]
+ }
+}
diff --git a/src/main.rs b/src/main.rs
index b7efd40af..c616c40d7 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -13,6 +13,7 @@ extern crate tokio;
extern crate tokio_executor;
extern crate tokio_fs;
extern crate tokio_io;
+extern crate tokio_process;
extern crate tokio_threadpool;
extern crate url;
diff --git a/third_party b/third_party
-Subproject 1db20c5ca7b5db229a0c6a42c8d43b0310c55f8
+Subproject 96d35734a47e5b63d98ba7f7cbd01dfe4cbc435