Skip to content

Commit

Permalink
Add option to tag rule as kt_public_only_in_abi_plugin_incompatible
Browse files Browse the repository at this point in the history
  • Loading branch information
rbeazleyspot committed Dec 23, 2024
1 parent 31ce64b commit 7881d02
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion kotlin/internal/jvm/compile.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -536,7 +536,7 @@ def _run_kt_builder_action(
omit_if_empty = True,
)

if toolchains.kt.experimental_use_public_only_abi_jars == True:
if not "kt_public_only_in_abi_plugin_incompatible" in ctx.attr.tags and toolchains.kt.experimental_use_public_only_abi_jars == True:
args.add("--public_only_in_abi_jar", "true")

args.add("--build_kotlin", build_kotlin)
Expand Down
8 changes: 4 additions & 4 deletions kotlin/internal/toolchains.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -205,11 +205,11 @@ _kt_toolchain = rule(
),
"experimental_use_public_only_abi_jars": attr.bool(
doc = """Compile using public only abi jars.
This effectively applies the following two compiler plugin options.
plugin:org.jetbrains.kotlin.jvm.abi:treatInternalAsPrivate=true
plugin:org.jetbrains.kotlin.jvm.abi:removePrivateClasses=true
This effectively applies the following two compiler plugin options:
plugin:org.jetbrains.kotlin.jvm.abi:treatInternalAsPrivate=true
plugin:org.jetbrains.kotlin.jvm.abi:removePrivateClasses=true
Can be disabled for an individual target using the tag.
`kt_abi_plugin_incompatible`""",
`kt_public_only_in_abi_plugin_incompatible`""",
default = False,
),
"experimental_strict_kotlin_deps": attr.string(
Expand Down

0 comments on commit 7881d02

Please sign in to comment.