forked from yskopets/proxy-wasm-rust-sdk
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Show getrandom and chrono/time usage in examples. (proxy-wasm#51)
Signed-off-by: Piotr Sikora <piotrsikora@google.com>
- Loading branch information
1 parent
e923d68
commit c1edb21
Showing
9 changed files
with
305 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
""" | ||
@generated | ||
cargo-raze crate build file. | ||
|
||
DO NOT EDIT! Replaced on runs of cargo-raze | ||
""" | ||
|
||
# buildifier: disable=load | ||
load( | ||
"@io_bazel_rules_rust//rust:rust.bzl", | ||
"rust_binary", | ||
"rust_library", | ||
"rust_test", | ||
) | ||
|
||
# buildifier: disable=load | ||
load("@bazel_skylib//lib:selects.bzl", "selects") | ||
|
||
package(default_visibility = [ | ||
# Public for visibility by "@raze__crate__version//" targets. | ||
# | ||
# Prefer access through "//bazel/cargo", which limits external | ||
# visibility to explicit Cargo.toml dependencies. | ||
"//visibility:public", | ||
]) | ||
|
||
licenses([ | ||
"notice", # MIT from expression "MIT OR Apache-2.0" | ||
]) | ||
|
||
# Generated Targets | ||
|
||
rust_library( | ||
name = "cfg_if", | ||
srcs = glob(["**/*.rs"]), | ||
crate_features = [ | ||
], | ||
crate_root = "src/lib.rs", | ||
crate_type = "lib", | ||
edition = "2018", | ||
rustc_flags = [ | ||
"--cap-lints=allow", | ||
], | ||
tags = [ | ||
"cargo-raze", | ||
"manual", | ||
], | ||
version = "1.0.0", | ||
# buildifier: leave-alone | ||
deps = [ | ||
], | ||
) | ||
|
||
# Unsupported target "xcrate" with type "test" omitted |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,96 @@ | ||
""" | ||
@generated | ||
cargo-raze crate build file. | ||
|
||
DO NOT EDIT! Replaced on runs of cargo-raze | ||
""" | ||
|
||
# buildifier: disable=load | ||
load( | ||
"@io_bazel_rules_rust//rust:rust.bzl", | ||
"rust_binary", | ||
"rust_library", | ||
"rust_test", | ||
) | ||
|
||
# buildifier: disable=load | ||
load("@bazel_skylib//lib:selects.bzl", "selects") | ||
|
||
package(default_visibility = [ | ||
# Public for visibility by "@raze__crate__version//" targets. | ||
# | ||
# Prefer access through "//bazel/cargo", which limits external | ||
# visibility to explicit Cargo.toml dependencies. | ||
"//visibility:public", | ||
]) | ||
|
||
licenses([ | ||
"notice", # MIT from expression "MIT OR Apache-2.0" | ||
]) | ||
|
||
# Generated Targets | ||
|
||
# Unsupported target "mod" with type "bench" omitted | ||
|
||
# Unsupported target "build-script-build" with type "custom-build" omitted | ||
|
||
rust_library( | ||
name = "getrandom", | ||
srcs = glob(["**/*.rs"]), | ||
aliases = { | ||
}, | ||
crate_features = [ | ||
], | ||
crate_root = "src/lib.rs", | ||
crate_type = "lib", | ||
edition = "2018", | ||
rustc_flags = [ | ||
"--cap-lints=allow", | ||
], | ||
tags = [ | ||
"cargo-raze", | ||
"manual", | ||
], | ||
version = "0.2.0", | ||
# buildifier: leave-alone | ||
deps = [ | ||
"@raze__cfg_if__0_1_10//:cfg_if", | ||
] + selects.with_or({ | ||
# cfg(all(target_arch = "wasm32", target_os = "unknown", not(cargo_web))) | ||
( | ||
"@io_bazel_rules_rust//rust/platform:wasm32-unknown-unknown", | ||
): [ | ||
], | ||
"//conditions:default": [], | ||
}) + selects.with_or({ | ||
# cfg(target_os = "wasi") | ||
( | ||
"@io_bazel_rules_rust//rust/platform:wasm32-wasi", | ||
): [ | ||
"@raze__wasi__0_9_0_wasi_snapshot_preview1//:wasi", | ||
], | ||
"//conditions:default": [], | ||
}) + selects.with_or({ | ||
# cfg(unix) | ||
( | ||
"@io_bazel_rules_rust//rust/platform:aarch64-apple-ios", | ||
"@io_bazel_rules_rust//rust/platform:aarch64-linux-android", | ||
"@io_bazel_rules_rust//rust/platform:aarch64-unknown-linux-gnu", | ||
"@io_bazel_rules_rust//rust/platform:arm-unknown-linux-gnueabi", | ||
"@io_bazel_rules_rust//rust/platform:i686-apple-darwin", | ||
"@io_bazel_rules_rust//rust/platform:i686-linux-android", | ||
"@io_bazel_rules_rust//rust/platform:i686-unknown-freebsd", | ||
"@io_bazel_rules_rust//rust/platform:i686-unknown-linux-gnu", | ||
"@io_bazel_rules_rust//rust/platform:powerpc-unknown-linux-gnu", | ||
"@io_bazel_rules_rust//rust/platform:s390x-unknown-linux-gnu", | ||
"@io_bazel_rules_rust//rust/platform:x86_64-apple-darwin", | ||
"@io_bazel_rules_rust//rust/platform:x86_64-apple-ios", | ||
"@io_bazel_rules_rust//rust/platform:x86_64-linux-android", | ||
"@io_bazel_rules_rust//rust/platform:x86_64-unknown-freebsd", | ||
"@io_bazel_rules_rust//rust/platform:x86_64-unknown-linux-gnu", | ||
): [ | ||
"@raze__libc__0_2_80//:libc", | ||
], | ||
"//conditions:default": [], | ||
}), | ||
) |
54 changes: 54 additions & 0 deletions
54
bazel/cargo/remote/BUILD.wasi-0.9.0+wasi-snapshot-preview1.bazel
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
""" | ||
@generated | ||
cargo-raze crate build file. | ||
|
||
DO NOT EDIT! Replaced on runs of cargo-raze | ||
""" | ||
|
||
# buildifier: disable=load | ||
load( | ||
"@io_bazel_rules_rust//rust:rust.bzl", | ||
"rust_binary", | ||
"rust_library", | ||
"rust_test", | ||
) | ||
|
||
# buildifier: disable=load | ||
load("@bazel_skylib//lib:selects.bzl", "selects") | ||
|
||
package(default_visibility = [ | ||
# Public for visibility by "@raze__crate__version//" targets. | ||
# | ||
# Prefer access through "//bazel/cargo", which limits external | ||
# visibility to explicit Cargo.toml dependencies. | ||
"//visibility:public", | ||
]) | ||
|
||
licenses([ | ||
"notice", # Apache-2.0 from expression "Apache-2.0 OR (Apache-2.0 OR MIT)" | ||
]) | ||
|
||
# Generated Targets | ||
|
||
rust_library( | ||
name = "wasi", | ||
srcs = glob(["**/*.rs"]), | ||
crate_features = [ | ||
"default", | ||
"std", | ||
], | ||
crate_root = "src/lib.rs", | ||
crate_type = "lib", | ||
edition = "2018", | ||
rustc_flags = [ | ||
"--cap-lints=allow", | ||
], | ||
tags = [ | ||
"cargo-raze", | ||
"manual", | ||
], | ||
version = "0.9.0+wasi-snapshot-preview1", | ||
# buildifier: leave-alone | ||
deps = [ | ||
], | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.