From 7fd8342b1c673bcaf07ca09fdbba6bbfdc51d1b2 Mon Sep 17 00:00:00 2001 From: Jason Steving Date: Thu, 4 Apr 2024 08:40:57 -0700 Subject: [PATCH] Prepare to Push to BCR Last bit of housecleaning before attempting to push this version to the BCR. Primarily just updates examples/bzlmod/ to use clarodocs(). Updates the JS related Module deps to not be considered "dev" dependencies as they need to be available for downstream Modules depending on claro-lang. Also fixes the stdlib/cache module so that it correctly builds. --- MODULE.bazel | 2 +- examples/bzlmod/MODULE.bazel | 2 +- src/java/com/claro/claro_build_rules_internal.bzl | 5 +++-- stdlib/cache/BUILD | 2 +- 4 files changed, 6 insertions(+), 5 deletions(-) diff --git a/MODULE.bazel b/MODULE.bazel index e2249c5f..6b95fc72 100644 --- a/MODULE.bazel +++ b/MODULE.bazel @@ -1,7 +1,7 @@ module( name = "claro-lang", repo_name = "claro-lang", - version = "0.1.501", + version = "0.1.502", ) bazel_dep(name = "aspect_bazel_lib", version = "2.0.1") diff --git a/examples/bzlmod/MODULE.bazel b/examples/bzlmod/MODULE.bazel index a6b556f9..7b956e74 100644 --- a/examples/bzlmod/MODULE.bazel +++ b/examples/bzlmod/MODULE.bazel @@ -1,4 +1,4 @@ module(name = "example-claro-module") -bazel_dep(name = "claro-lang", version = "0.1.501") +bazel_dep(name = "claro-lang", version = "0.1.502") diff --git a/src/java/com/claro/claro_build_rules_internal.bzl b/src/java/com/claro/claro_build_rules_internal.bzl index fb5e36b6..f52b1f1f 100644 --- a/src/java/com/claro/claro_build_rules_internal.bzl +++ b/src/java/com/claro/claro_build_rules_internal.bzl @@ -313,8 +313,9 @@ def bootstrapped_claro_module(name, module_api_file, srcs = ["@claro-lang//:empt # In order to avoid a circular dep back into the local build of the compiler, this compilation unit must be built using # the "bootstrapping compiler" based on a prior precompiled release of the compiler from github. -def bootstrapped_claro_module_internal(name, module_api_file, srcs = ["@claro-lang//:empty_claro_src"], deps = {}, resources = {}, exports = [], exported_custom_java_deps = [], debug = False, **kwargs): - native.exports_files([module_api_file]) +def bootstrapped_claro_module_internal(name, module_api_file, srcs = ["@claro-lang//:empty_claro_src"], deps = {}, resources = {}, exports = [], exported_custom_java_deps = [], debug = False, export_module_api = True, **kwargs): + if export_module_api: + native.exports_files([module_api_file]) _claro_module_internal( _invoke_claro_compiler_internal, name, module_api_file, srcs, deps, resources, exports, exported_custom_java_deps, optional_stdlib_deps = [], debug = debug, add_stdlib_deps = False, claro_compiler = "@claro-lang//:bootstrapping_claro_compiler_binary", diff --git a/stdlib/cache/BUILD b/stdlib/cache/BUILD index b62949a6..8e3b05a7 100644 --- a/stdlib/cache/BUILD +++ b/stdlib/cache/BUILD @@ -22,7 +22,7 @@ bootstrapped_claro_module_internal( "//:future_converter", ], visibility = ["//visibility:public"], - debug = True + export_module_api = False, ) # TODO(steving) `module_api_file` should be concatenative like `srcs`.