blob: de80cd757eb0bb76f82b2c50897586a41b1dd7c4 [file] [log] [blame]
# Copyright 2018 The Fuchsia Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import("//build/package.gni")
import("//build/rust/rustc_binary.gni")
import("//build/test/test_package.gni")
import("//build/testing/environments.gni")
rustc_binary("bin") {
name = "netstack3"
edition = "2018"
with_unit_tests = true
deps = [
"core:netstack3-core",
"//garnet/lib/rust/ethernet",
"//garnet/lib/rust/fidl_fuchsia_hardware_ethernet_ext",
"//garnet/lib/rust/fidl_fuchsia_net_ext",
"//garnet/public/lib/fidl/rust/fidl",
"//garnet/public/rust/fuchsia-async",
"//garnet/public/rust/fuchsia-component",
"//garnet/public/rust/fuchsia-syslog",
"//garnet/public/rust/fuchsia-zircon",
"//third_party/rust_crates:byteorder",
"//third_party/rust_crates:failure",
"//third_party/rust_crates:futures-preview",
"//third_party/rust_crates:libc",
"//third_party/rust_crates:log",
"//zircon/public/fidl/fuchsia-hardware-ethernet:fuchsia-hardware-ethernet-rustc",
"//zircon/public/fidl/fuchsia-net:fuchsia-net-rustc",
"//zircon/public/fidl/fuchsia-net-stack:fuchsia-net-stack-rustc",
]
}
package("netstack3") {
deps = [
":bin",
]
binaries = [
{
name = "netstack3"
},
]
meta = [
{
path = rebase_path("meta/netstack3.cmx")
dest = "netstack3.cmx"
},
]
}
test_package("netstack3_tests") {
deps = [
":bin",
"core:netstack3-core",
"core/specialize-ip-macro/test:lib",
]
tests = [
{
name = "netstack3_bin_test"
environments = [ qemu_env ]
},
{
name = "netstack3_core_lib_test"
environments = [ qemu_env ]
},
{
name = "specialize_ip_macro_test_lib_test"
environments = [ qemu_env ]
},
]
}