summaryrefslogtreecommitdiff
path: root/build_extra/rust
diff options
context:
space:
mode:
Diffstat (limited to 'build_extra/rust')
-rw-r--r--build_extra/rust/BUILD.gn99
1 files changed, 89 insertions, 10 deletions
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",
+ ]
+ }
+}