Joao's changes

This commit is contained in:
Ravindhran Sankar 2023-06-01 11:06:05 -07:00
parent f21ee4c197
commit aac7e4c87e
3 changed files with 28 additions and 0 deletions

View File

@ -103,3 +103,7 @@ try-import %workspace%/.configure.bazelrc
# This bazelrc file can be used for user-specific custom build settings. # This bazelrc file can be used for user-specific custom build settings.
try-import %workspace%/.user.bazelrc try-import %workspace%/.user.bazelrc
##### WASM #####
build --incompatible_enable_cc_toolchain_resolution

View File

@ -612,3 +612,19 @@ http_archive(
urls = ["https://github.com/halide/Halide/releases/download/v15.0.1/Halide-15.0.1-x86-64-windows-4c63f1befa1063184c5982b11b6a2cc17d4e5815.zip"], urls = ["https://github.com/halide/Halide/releases/download/v15.0.1/Halide-15.0.1-x86-64-windows-4c63f1befa1063184c5982b11b6a2cc17d4e5815.zip"],
build_file = "@//third_party:halide.BUILD", build_file = "@//third_party:halide.BUILD",
) )
# Emscripten toolchain
http_archive(
name = "emsdk",
sha256 = "e55704006765ea8e127d76278b1573b114204d19e6972d8a3a2a18f2f2ee4c10",
strip_prefix = "emsdk-b113f24842c6e97fe3e352084db09a6e278593ae/bazel",
url = "https://github.com/emscripten-core/emsdk/archive/b113f24842c6e97fe3e352084db09a6e278593ae.tar.gz",
)
load("@emsdk//:deps.bzl", emsdk_deps = "deps")
emsdk_deps()
load("@emsdk//:emscripten_deps.bzl", emsdk_emscripten_deps = "emscripten_deps")
emsdk_emscripten_deps(emscripten_version = "3.1.37")
load("@emsdk//:toolchains.bzl", "register_emscripten_toolchains")
register_emscripten_toolchains()

View File

@ -12,6 +12,9 @@
# See the License for the specific language governing permissions and # See the License for the specific language governing permissions and
# limitations under the License. # limitations under the License.
load("@rules_cc//cc:defs.bzl", "cc_binary")
load("@emsdk//emscripten_toolchain:wasm_rules.bzl", "wasm_cc_binary")
licenses(["notice"]) licenses(["notice"])
package(default_visibility = ["//visibility:public"]) package(default_visibility = ["//visibility:public"])
@ -27,3 +30,8 @@ cc_binary(
"//mediapipe/framework/port:status", "//mediapipe/framework/port:status",
], ],
) )
wasm_cc_binary(
name = "hello_world_wasm",
cc_target = ":hello_world",
)