diff --git a/kotlin/internal/jvm/compile.bzl b/kotlin/internal/jvm/compile.bzl index 04fde4503..48fc21214 100644 --- a/kotlin/internal/jvm/compile.bzl +++ b/kotlin/internal/jvm/compile.bzl @@ -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) diff --git a/kotlin/internal/toolchains.bzl b/kotlin/internal/toolchains.bzl index 743c8f349..28a44fc60 100644 --- a/kotlin/internal/toolchains.bzl +++ b/kotlin/internal/toolchains.bzl @@ -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(