Skip to content

Commit

Permalink
Build xtask with Bazel.
Browse files Browse the repository at this point in the history
Note: it does not run correctly yet but adding it to unlock bazelifying crates that depend on xtask.

BUG: 330178457,349587499
Change-Id: Ief86b89455fc6f016d095d7551b0fea7a9bc1916
  • Loading branch information
ernoc committed Jun 27, 2024
1 parent b36cd99 commit eecf436
Show file tree
Hide file tree
Showing 6 changed files with 815 additions and 94 deletions.
72 changes: 61 additions & 11 deletions Cargo.bazel.lock
Original file line number Diff line number Diff line change
Expand Up @@ -196,6 +196,17 @@ version = "7.0.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "0c24e9d990669fbd16806bff449e4ac644fd9b1fca014760087732fe4102f131"

[[package]]
name = "async-recursion"
version = "1.1.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "3b43422f69d8ff38f95f1b2bb76517c91589a924d1559a0e935d7c8ce0274c11"
dependencies = [
"proc-macro2",
"quote",
"syn 2.0.58",
]

[[package]]
name = "async-stream"
version = "0.3.5"
Expand Down Expand Up @@ -509,31 +520,40 @@ dependencies = [

[[package]]
name = "clap"
version = "4.5.4"
version = "4.5.7"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "90bc066a67923782aa8515dbaea16946c5bcc5addbd668bb80af688e53e548a0"
checksum = "5db83dced34638ad474f39f250d7fea9598bdd239eaced1bdf45d597da0f433f"
dependencies = [
"clap_builder",
"clap_derive",
]

[[package]]
name = "clap_builder"
version = "4.5.2"
version = "4.5.7"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "ae129e2e766ae0ec03484e609954119f123cc1fe650337e155d03b022f24f7b4"
checksum = "f7e204572485eb3fbf28f871612191521df159bc3e15a9f5064c66dba3a8c05f"
dependencies = [
"anstream",
"anstyle",
"clap_lex",
"strsim",
]

[[package]]
name = "clap_complete"
version = "4.5.6"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "fbca90c87c2a04da41e95d1856e8bcd22f159bdbfa147314d2ce5218057b0e58"
dependencies = [
"clap",
]

[[package]]
name = "clap_derive"
version = "4.5.4"
version = "4.5.5"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "528131438037fd55894f62d6e9f068b8f45ac57ffa77517819645d10aed04f64"
checksum = "c780290ccf4fb26629baa7a1081e68ced113f1d3ec302fa5948f1c381ebf06c6"
dependencies = [
"heck 0.5.0",
"proc-macro2",
Expand Down Expand Up @@ -1012,6 +1032,7 @@ dependencies = [
"anyhow",
"arrayvec",
"assertables",
"async-recursion",
"async-stream",
"async-trait",
"atomic_refcell",
Expand All @@ -1020,8 +1041,10 @@ dependencies = [
"bitvec",
"bmrng",
"bytes",
"chrono",
"ciborium",
"clap",
"clap_complete",
"colored",
"command-fds",
"coset",
Expand All @@ -1041,6 +1064,7 @@ dependencies = [
"http 1.1.0",
"hyper",
"ignore",
"itertools 0.12.1",
"lazy_static",
"libloading",
"libm",
Expand All @@ -1061,6 +1085,7 @@ dependencies = [
"parking_lot",
"pkcs8",
"port_check",
"portpicker",
"pprof",
"primeorder",
"procfs",
Expand Down Expand Up @@ -1089,6 +1114,7 @@ dependencies = [
"static_assertions",
"stderrlog",
"strum",
"strum_macros 0.25.3",
"subprocess",
"syn 2.0.58",
"syslog",
Expand All @@ -1100,6 +1126,7 @@ dependencies = [
"tokio-stream",
"tokio-util",
"tokio-vsock",
"toml",
"tonic",
"tonic-build",
"tonic-web",
Expand Down Expand Up @@ -2721,6 +2748,15 @@ version = "0.2.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "2110609fb863cdb367d4e69d6c43c81ba6a8c7d18e80082fe9f3ef16b23afeed"

[[package]]
name = "portpicker"
version = "0.1.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "be97d76faf1bfab666e1375477b23fde79eccf0276e9b63b92a39d676a889ba9"
dependencies = [
"rand",
]

[[package]]
name = "postcard"
version = "1.0.8"
Expand Down Expand Up @@ -3505,18 +3541,31 @@ checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f"

[[package]]
name = "strum"
version = "0.26.2"
version = "0.24.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "063e6045c0e62079840579a7e47a355ae92f60eb74daaf156fb1e84ba164e63f"
dependencies = [
"strum_macros 0.24.3",
]

[[package]]
name = "strum_macros"
version = "0.24.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "5d8cec3501a5194c432b2b7976db6b7d10ec95c253208b45f83f7136aa985e29"
checksum = "1e385be0d24f186b4ce2f9982191e7101bb737312ad61c1f2f984f34bcf85d59"
dependencies = [
"strum_macros",
"heck 0.4.1",
"proc-macro2",
"quote",
"rustversion",
"syn 1.0.109",
]

[[package]]
name = "strum_macros"
version = "0.26.2"
version = "0.25.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "c6cf59daf282c0a494ba14fd21610a0325f9f90ec9d1231dea26bcb1d696c946"
checksum = "23dc1fa9ac9c169a78ba62f0b841814b7abae11bdd047b9c58f893439e309ea0"
dependencies = [
"heck 0.4.1",
"proc-macro2",
Expand Down Expand Up @@ -3766,6 +3815,7 @@ dependencies = [
"libc",
"mio",
"num_cpus",
"parking_lot",
"pin-project-lite",
"signal-hook-registry",
"socket2",
Expand Down
20 changes: 18 additions & 2 deletions bazel/crates/oak_crates_index.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ def oak_crates_index(cargo_lockfile, lockfile):
default_features = False,
version = "*",
),
"async-recursion": crate.spec(version = "*"),
"async-stream": crate.spec(
version = "*",
),
Expand All @@ -98,6 +99,14 @@ def oak_crates_index(cargo_lockfile, lockfile):
),
"bmrng": crate.spec(version = "*"),
"bytes": crate.spec(version = "*"),
"chrono": crate.spec(
default_features = False,
features = [
"std",
"clock",
],
version = "*",
),
"ciborium": crate.spec(
default_features = False,
version = "*",
Expand All @@ -109,6 +118,7 @@ def oak_crates_index(cargo_lockfile, lockfile):
],
version = "*",
),
"clap_complete": crate.spec(version = "*"),
"colored": crate.spec(version = "*"),
"command-fds": crate.spec(
features = ["tokio"],
Expand Down Expand Up @@ -178,6 +188,7 @@ def oak_crates_index(cargo_lockfile, lockfile):
),
"http": crate.spec(version = "*"),
"ignore": crate.spec(version = "*"),
"itertools": crate.spec(version = "*"),
"lazy_static": crate.spec(version = "*"),
"libloading": crate.spec(version = "*"),
"libm": crate.spec(version = "*"),
Expand All @@ -196,7 +207,7 @@ def oak_crates_index(cargo_lockfile, lockfile):
),
"maplit": crate.spec(version = "*"),
"nix": crate.spec(
features = ["user", "process"],
features = ["user", "process", "signal"],
version = "*",
),
"oci-spec": crate.spec(version = "*"),
Expand All @@ -222,6 +233,7 @@ def oak_crates_index(cargo_lockfile, lockfile):
version = "*",
),
"ouroboros": crate.spec(version = "*"),
"portpicker": crate.spec(version = "*"),
"p256": crate.spec(
default_features = False,
features = [
Expand Down Expand Up @@ -322,8 +334,9 @@ def oak_crates_index(cargo_lockfile, lockfile):
"strum": crate.spec(
default_features = False,
features = ["derive"],
version = "*",
version = "0.24",
),
"strum_macros": crate.spec(version = "0.25"),
"subprocess": crate.spec(version = "*"),
"syn": crate.spec(
features = ["full"],
Expand All @@ -344,8 +357,10 @@ def oak_crates_index(cargo_lockfile, lockfile):
"tokio": crate.spec(
features = [
"fs",
"io-util",
"macros",
"net",
"parking_lot",
"process",
"rt-multi-thread",
"signal",
Expand Down Expand Up @@ -374,6 +389,7 @@ def oak_crates_index(cargo_lockfile, lockfile):
rev = "2a52faeb4ede7d9712adbc096e547ab7ea766f4b",
features = ["tonic-conn"],
),
"toml": crate.spec(version = "*"),
"tonic": crate.spec(version = "*"),
"tonic-build": crate.spec(version = "*"),
"tonic-web": crate.spec(version = "*"),
Expand Down
Loading

0 comments on commit eecf436

Please sign in to comment.