diff --git a/bazel/external/wasm-c-api.BUILD b/bazel/external/wasm-c-api.BUILD deleted file mode 100644 index 8fd92e4ac7c19..0000000000000 --- a/bazel/external/wasm-c-api.BUILD +++ /dev/null @@ -1,14 +0,0 @@ -licenses(["notice"]) # Apache 2 - -package(default_visibility = ["//visibility:public"]) - -cc_library( - name = "wasmtime_lib", - hdrs = [ - "include/wasm.h", - ], - include_prefix = "wasmtime", - deps = [ - "@com_github_wasmtime//:rust_c_api", - ], -) diff --git a/bazel/external/wasmtime.BUILD b/bazel/external/wasmtime.BUILD index 525c9a20c0b1e..a5b6f875de725 100644 --- a/bazel/external/wasmtime.BUILD +++ b/bazel/external/wasmtime.BUILD @@ -4,6 +4,16 @@ licenses(["notice"]) # Apache 2 package(default_visibility = ["//visibility:public"]) +cc_library( + name = "wasmtime_lib", + hdrs = [ + "crates/c-api/include/wasm.h", + ], + deps = [ + ":rust_c_api", + ], +) + cc_library( name = "helpers_lib", srcs = [ diff --git a/bazel/repositories.bzl b/bazel/repositories.bzl index 3eabd0b2b7ae3..18a03cf47c726 100644 --- a/bazel/repositories.bzl +++ b/bazel/repositories.bzl @@ -244,7 +244,6 @@ def envoy_dependencies(skip_targets = []): _com_github_wamr() _com_github_wasmtime() - _com_github_wasm_c_api() switched_rules_by_language( name = "com_google_googleapis_imports", @@ -885,21 +884,16 @@ def _com_github_wasmtime(): build_file = "@envoy//bazel/external:wasmtime.BUILD", ) -def _com_github_wasm_c_api(): - external_http_archive( - name = "com_github_wasm_c_api", - build_file = "@envoy//bazel/external:wasm-c-api.BUILD", - ) native.bind( name = "wasmtime", - actual = "@com_github_wasm_c_api//:wasmtime_lib", + actual = "@com_github_wasmtime//:wasmtime_lib", ) # This isn't needed in builds with a single Wasm engine, but "bazel query" # complains about a missing dependency, so point it at the regular target. native.bind( name = "prefixed_wasmtime", - actual = "@com_github_wasm_c_api//:wasmtime_lib", + actual = "@com_github_wasmtime//:wasmtime_lib", ) def _intel_dlb(): diff --git a/bazel/repository_locations.bzl b/bazel/repository_locations.bzl index 3fb71dc670e14..d97031127e3a3 100644 --- a/bazel/repository_locations.bzl +++ b/bazel/repository_locations.bzl @@ -1137,23 +1137,6 @@ REPOSITORY_LOCATIONS_SPEC = dict( license = "Apache-2.0", license_url = "https://github.com/bytecodealliance/wasmtime/blob/v{version}/LICENSE", ), - com_github_wasm_c_api = dict( - project_name = "wasm-c-api", - project_desc = "WebAssembly C and C++ API", - project_url = "https://github.com/WebAssembly/wasm-c-api", - # this is the submodule's specific commit used by wasmtime - # https://github.com/bytecodealliance/wasmtime/tree/v0.25.0/crates/c-api - version = "c9d31284651b975f05ac27cee0bab1377560b87e", - sha256 = "c774044f51431429e878bd1b9e2a4e38932f861f9211df72f75e9427eb6b8d32", - strip_prefix = "wasm-c-api-{version}", - urls = ["https://github.com/WebAssembly/wasm-c-api/archive/{version}.tar.gz"], - release_date = "2021-01-11", - use_category = ["dataplane_ext"], - extensions = ["envoy.wasm.runtime.wasmtime"], - cpe = "N/A", - license = "Apache-2.0", - license_url = "https://github.com/WebAssembly/wasm-c-api/blob/{version}/LICENSE", - ), io_opencensus_cpp = dict( project_name = "OpenCensus C++", project_desc = "OpenCensus tracing library",