diff --git a/libraries/tools/kotlin-gradle-plugin-api/src/common/kotlin/org/jetbrains/kotlin/gradle/plugin/KotlinTargetHierarchyBuilder.kt b/libraries/tools/kotlin-gradle-plugin-api/src/common/kotlin/org/jetbrains/kotlin/gradle/plugin/KotlinTargetHierarchyBuilder.kt index 29ef76b8193..17c72a99d4d 100644 --- a/libraries/tools/kotlin-gradle-plugin-api/src/common/kotlin/org/jetbrains/kotlin/gradle/plugin/KotlinTargetHierarchyBuilder.kt +++ b/libraries/tools/kotlin-gradle-plugin-api/src/common/kotlin/org/jetbrains/kotlin/gradle/plugin/KotlinTargetHierarchyBuilder.kt @@ -167,21 +167,21 @@ interface KotlinTargetHierarchyBuilder { fun withMacosArm64() fun withLinuxArm64() - @Deprecated(DEPRECATED_TARGET_MESSAGE) + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) fun withWatchosX86() - @Deprecated(DEPRECATED_TARGET_MESSAGE) + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) fun withMingwX86() - @Deprecated(DEPRECATED_TARGET_MESSAGE) + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) fun withLinuxArm32Hfp() - @Deprecated(DEPRECATED_TARGET_MESSAGE) + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) fun withLinuxMips32() - @Deprecated(DEPRECATED_TARGET_MESSAGE) + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) fun withLinuxMipsel32() - @Deprecated(DEPRECATED_TARGET_MESSAGE) + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) fun withWasm32() } diff --git a/libraries/tools/kotlin-gradle-plugin-dsl-codegen/src/main/kotlin/org/jetbrains/kotlin/generators/gradle/dsl/KotlinArtifactsDSLCodegen.kt b/libraries/tools/kotlin-gradle-plugin-dsl-codegen/src/main/kotlin/org/jetbrains/kotlin/generators/gradle/dsl/KotlinArtifactsDSLCodegen.kt index 63fd74c823c..f5812a2e21e 100644 --- a/libraries/tools/kotlin-gradle-plugin-dsl-codegen/src/main/kotlin/org/jetbrains/kotlin/generators/gradle/dsl/KotlinArtifactsDSLCodegen.kt +++ b/libraries/tools/kotlin-gradle-plugin-dsl-codegen/src/main/kotlin/org/jetbrains/kotlin/generators/gradle/dsl/KotlinArtifactsDSLCodegen.kt @@ -62,7 +62,7 @@ private fun generateAbstractKotlinArtifactsExtensionImplementation() { val deprecatedKonanTargetConstants = KonanTarget.predefinedTargets.values.filter { KonanTarget.deprecatedTargets.contains(it) } .joinToString("\n") { - "\n@Deprecated(DEPRECATED_TARGET_MESSAGE)\n" + it.generateKonanTargetVal() + "\n@Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR)\n" + it.generateKonanTargetVal() }.indented(4) val code = listOf( diff --git a/libraries/tools/kotlin-gradle-plugin-dsl-codegen/src/main/kotlin/org/jetbrains/kotlin/generators/gradle/dsl/mppPresetFunctionsCodegen.kt b/libraries/tools/kotlin-gradle-plugin-dsl-codegen/src/main/kotlin/org/jetbrains/kotlin/generators/gradle/dsl/mppPresetFunctionsCodegen.kt index 9a668d94af5..94351798943 100644 --- a/libraries/tools/kotlin-gradle-plugin-dsl-codegen/src/main/kotlin/org/jetbrains/kotlin/generators/gradle/dsl/mppPresetFunctionsCodegen.kt +++ b/libraries/tools/kotlin-gradle-plugin-dsl-codegen/src/main/kotlin/org/jetbrains/kotlin/generators/gradle/dsl/mppPresetFunctionsCodegen.kt @@ -21,7 +21,7 @@ private fun generateKotlinTargetContainerWithPresetFunctionsInterface() { // Generate KotlinMultiplatformExtension subclass with member functions for the presets: val functions = nativePresetEntries.map { kotlinPreset -> // magic indent is needed to make the result look pretty - val funPrefix = kotlinPreset.deprecation?.let { "\n $it\n @Suppress(\"DEPRECATION\")\n " } ?: "" + val funPrefix = kotlinPreset.deprecation?.let { "\n $it\n @Suppress(\"DEPRECATION_ERROR\")\n " } ?: "" generatePresetFunctions(kotlinPreset, presetsProperty, "configureOrCreate", funPrefix) } diff --git a/libraries/tools/kotlin-gradle-plugin-dsl-codegen/src/main/kotlin/org/jetbrains/kotlin/generators/gradle/dsl/presetEntries.kt b/libraries/tools/kotlin-gradle-plugin-dsl-codegen/src/main/kotlin/org/jetbrains/kotlin/generators/gradle/dsl/presetEntries.kt index 75d38352f7a..fc6dde44a61 100644 --- a/libraries/tools/kotlin-gradle-plugin-dsl-codegen/src/main/kotlin/org/jetbrains/kotlin/generators/gradle/dsl/presetEntries.kt +++ b/libraries/tools/kotlin-gradle-plugin-dsl-codegen/src/main/kotlin/org/jetbrains/kotlin/generators/gradle/dsl/presetEntries.kt @@ -63,7 +63,7 @@ internal val nativePresetEntries = HostManager().targets else -> Presets.simple to Targets.base } - val deprecation = "@Deprecated(DEPRECATED_TARGET_MESSAGE)".takeIf { target in KonanTarget.deprecatedTargets } + val deprecation = "@Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR)".takeIf { target in KonanTarget.deprecatedTargets } KotlinPresetEntry(target.presetName, typeName(presetType), typeName(targetType), deprecation) } diff --git a/libraries/tools/kotlin-gradle-plugin/src/common/kotlin/org/jetbrains/kotlin/gradle/dsl/KotlinTargetContainerWithNativePresetFunctions.kt b/libraries/tools/kotlin-gradle-plugin/src/common/kotlin/org/jetbrains/kotlin/gradle/dsl/KotlinTargetContainerWithNativePresetFunctions.kt index b7a9189ae98..a21345be4fb 100644 --- a/libraries/tools/kotlin-gradle-plugin/src/common/kotlin/org/jetbrains/kotlin/gradle/dsl/KotlinTargetContainerWithNativePresetFunctions.kt +++ b/libraries/tools/kotlin-gradle-plugin/src/common/kotlin/org/jetbrains/kotlin/gradle/dsl/KotlinTargetContainerWithNativePresetFunctions.kt @@ -75,8 +75,8 @@ interface KotlinTargetContainerWithNativePresetFunctions : KotlinTargetsContaine fun androidNativeArm64(configure: Action) = androidNativeArm64 { configure.execute(this) } - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun iosArm32( name: String = "iosArm32", configure: KotlinNativeTarget.() -> Unit = { } @@ -88,20 +88,20 @@ interface KotlinTargetContainerWithNativePresetFunctions : KotlinTargetsContaine ) - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun iosArm32() = iosArm32("iosArm32") { } - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun iosArm32(name: String) = iosArm32(name) { } - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun iosArm32(name: String, configure: Action) = iosArm32(name) { configure.execute(this) } - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun iosArm32(configure: Action) = iosArm32 { configure.execute(this) } fun iosArm64( @@ -180,8 +180,8 @@ interface KotlinTargetContainerWithNativePresetFunctions : KotlinTargetsContaine fun watchosArm64(configure: Action) = watchosArm64 { configure.execute(this) } - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun watchosX86( name: String = "watchosX86", configure: KotlinNativeTargetWithSimulatorTests.() -> Unit = { } @@ -193,20 +193,20 @@ interface KotlinTargetContainerWithNativePresetFunctions : KotlinTargetsContaine ) - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun watchosX86() = watchosX86("watchosX86") { } - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun watchosX86(name: String) = watchosX86(name) { } - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun watchosX86(name: String, configure: Action) = watchosX86(name) { configure.execute(this) } - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun watchosX86(configure: Action) = watchosX86 { configure.execute(this) } fun watchosX64( @@ -315,8 +315,8 @@ interface KotlinTargetContainerWithNativePresetFunctions : KotlinTargetsContaine fun linuxX64(configure: Action) = linuxX64 { configure.execute(this) } - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun mingwX86( name: String = "mingwX86", configure: KotlinNativeTarget.() -> Unit = { } @@ -328,20 +328,20 @@ interface KotlinTargetContainerWithNativePresetFunctions : KotlinTargetsContaine ) - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun mingwX86() = mingwX86("mingwX86") { } - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun mingwX86(name: String) = mingwX86(name) { } - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun mingwX86(name: String, configure: Action) = mingwX86(name) { configure.execute(this) } - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun mingwX86(configure: Action) = mingwX86 { configure.execute(this) } fun mingwX64( @@ -405,8 +405,8 @@ interface KotlinTargetContainerWithNativePresetFunctions : KotlinTargetsContaine fun linuxArm64(configure: Action) = linuxArm64 { configure.execute(this) } - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun linuxArm32Hfp( name: String = "linuxArm32Hfp", configure: KotlinNativeTarget.() -> Unit = { } @@ -418,25 +418,25 @@ interface KotlinTargetContainerWithNativePresetFunctions : KotlinTargetsContaine ) - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun linuxArm32Hfp() = linuxArm32Hfp("linuxArm32Hfp") { } - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun linuxArm32Hfp(name: String) = linuxArm32Hfp(name) { } - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun linuxArm32Hfp(name: String, configure: Action) = linuxArm32Hfp(name) { configure.execute(this) } - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun linuxArm32Hfp(configure: Action) = linuxArm32Hfp { configure.execute(this) } - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun linuxMips32( name: String = "linuxMips32", configure: KotlinNativeTarget.() -> Unit = { } @@ -448,25 +448,25 @@ interface KotlinTargetContainerWithNativePresetFunctions : KotlinTargetsContaine ) - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun linuxMips32() = linuxMips32("linuxMips32") { } - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun linuxMips32(name: String) = linuxMips32(name) { } - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun linuxMips32(name: String, configure: Action) = linuxMips32(name) { configure.execute(this) } - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun linuxMips32(configure: Action) = linuxMips32 { configure.execute(this) } - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun linuxMipsel32( name: String = "linuxMipsel32", configure: KotlinNativeTarget.() -> Unit = { } @@ -478,25 +478,25 @@ interface KotlinTargetContainerWithNativePresetFunctions : KotlinTargetsContaine ) - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun linuxMipsel32() = linuxMipsel32("linuxMipsel32") { } - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun linuxMipsel32(name: String) = linuxMipsel32(name) { } - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun linuxMipsel32(name: String, configure: Action) = linuxMipsel32(name) { configure.execute(this) } - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun linuxMipsel32(configure: Action) = linuxMipsel32 { configure.execute(this) } - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun wasm32( name: String = "wasm32", configure: KotlinNativeTarget.() -> Unit = { } @@ -508,20 +508,20 @@ interface KotlinTargetContainerWithNativePresetFunctions : KotlinTargetsContaine ) - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun wasm32() = wasm32("wasm32") { } - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun wasm32(name: String) = wasm32(name) { } - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun wasm32(name: String, configure: Action) = wasm32(name) { configure.execute(this) } - @Deprecated(DEPRECATED_TARGET_MESSAGE) - @Suppress("DEPRECATION") + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) + @Suppress("DEPRECATION_ERROR") fun wasm32(configure: Action) = wasm32 { configure.execute(this) } } \ No newline at end of file diff --git a/libraries/tools/kotlin-gradle-plugin/src/common/kotlin/org/jetbrains/kotlin/gradle/plugin/diagnostics/KotlinToolingDiagnostics.kt b/libraries/tools/kotlin-gradle-plugin/src/common/kotlin/org/jetbrains/kotlin/gradle/plugin/diagnostics/KotlinToolingDiagnostics.kt index 4aaebe93d16..ebdfda29d1b 100644 --- a/libraries/tools/kotlin-gradle-plugin/src/common/kotlin/org/jetbrains/kotlin/gradle/plugin/diagnostics/KotlinToolingDiagnostics.kt +++ b/libraries/tools/kotlin-gradle-plugin/src/common/kotlin/org/jetbrains/kotlin/gradle/plugin/diagnostics/KotlinToolingDiagnostics.kt @@ -22,9 +22,9 @@ object KotlinToolingDiagnostics { ) } - object DeprecatedKotlinNativeTargetsDiagnostic : ToolingDiagnosticFactory(WARNING) { + object DeprecatedKotlinNativeTargetsDiagnostic : ToolingDiagnosticFactory(ERROR) { operator fun invoke(usedTargetIds: List) = build( - "The following deprecated Kotlin/Native targets were used in the project: ${usedTargetIds.joinToString()}" + "The following removed Kotlin/Native targets were used in the project: ${usedTargetIds.joinToString()}" ) } diff --git a/libraries/tools/kotlin-gradle-plugin/src/common/kotlin/org/jetbrains/kotlin/gradle/plugin/mpp/targetHierarchy/KotlinTargetHierarchyBuilderImpl.kt b/libraries/tools/kotlin-gradle-plugin/src/common/kotlin/org/jetbrains/kotlin/gradle/plugin/mpp/targetHierarchy/KotlinTargetHierarchyBuilderImpl.kt index 8213d43e29a..a76f1c92d70 100644 --- a/libraries/tools/kotlin-gradle-plugin/src/common/kotlin/org/jetbrains/kotlin/gradle/plugin/mpp/targetHierarchy/KotlinTargetHierarchyBuilderImpl.kt +++ b/libraries/tools/kotlin-gradle-plugin/src/common/kotlin/org/jetbrains/kotlin/gradle/plugin/mpp/targetHierarchy/KotlinTargetHierarchyBuilderImpl.kt @@ -250,32 +250,32 @@ private class KotlinTargetHierarchyBuilderImpl( it is KotlinNativeTarget && it.konanTarget == KonanTarget.LINUX_ARM64 } - @Deprecated(DEPRECATED_TARGET_MESSAGE) + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) override fun withWatchosX86() = withTargets { it is KotlinNativeTarget && it.konanTarget == KonanTarget.WATCHOS_X86 } - @Deprecated(DEPRECATED_TARGET_MESSAGE) + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) override fun withMingwX86() = withTargets { it is KotlinNativeTarget && it.konanTarget == KonanTarget.MINGW_X86 } - @Deprecated(DEPRECATED_TARGET_MESSAGE) + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) override fun withLinuxArm32Hfp() = withTargets { it is KotlinNativeTarget && it.konanTarget == KonanTarget.LINUX_ARM32_HFP } - @Deprecated(DEPRECATED_TARGET_MESSAGE) + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) override fun withLinuxMips32() = withTargets { it is KotlinNativeTarget && it.konanTarget == KonanTarget.LINUX_MIPS32 } - @Deprecated(DEPRECATED_TARGET_MESSAGE) + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) override fun withLinuxMipsel32() = withTargets { it is KotlinNativeTarget && it.konanTarget == KonanTarget.LINUX_MIPSEL32 } - @Deprecated(DEPRECATED_TARGET_MESSAGE) + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) override fun withWasm32() = withTargets { it is KotlinNativeTarget && it.konanTarget == KonanTarget.WASM32 } diff --git a/libraries/tools/kotlin-gradle-plugin/src/common/kotlin/org/jetbrains/kotlin/gradle/targets/native/tasks/artifact/KotlinArtifactsExtensionImpl.kt b/libraries/tools/kotlin-gradle-plugin/src/common/kotlin/org/jetbrains/kotlin/gradle/targets/native/tasks/artifact/KotlinArtifactsExtensionImpl.kt index 9fee793a8dd..aad22dff23d 100644 --- a/libraries/tools/kotlin-gradle-plugin/src/common/kotlin/org/jetbrains/kotlin/gradle/targets/native/tasks/artifact/KotlinArtifactsExtensionImpl.kt +++ b/libraries/tools/kotlin-gradle-plugin/src/common/kotlin/org/jetbrains/kotlin/gradle/targets/native/tasks/artifact/KotlinArtifactsExtensionImpl.kt @@ -52,25 +52,25 @@ abstract class KotlinArtifactsExtensionImpl @Inject constructor(project: Project val linuxArm64 = KonanTarget.LINUX_ARM64 - @Deprecated(DEPRECATED_TARGET_MESSAGE) + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) val iosArm32 = KonanTarget.IOS_ARM32 - @Deprecated(DEPRECATED_TARGET_MESSAGE) + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) val watchosX86 = KonanTarget.WATCHOS_X86 - @Deprecated(DEPRECATED_TARGET_MESSAGE) + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) val mingwX86 = KonanTarget.MINGW_X86 - @Deprecated(DEPRECATED_TARGET_MESSAGE) + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) val linuxArm32Hfp = KonanTarget.LINUX_ARM32_HFP - @Deprecated(DEPRECATED_TARGET_MESSAGE) + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) val linuxMips32 = KonanTarget.LINUX_MIPS32 - @Deprecated(DEPRECATED_TARGET_MESSAGE) + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) val linuxMipsel32 = KonanTarget.LINUX_MIPSEL32 - @Deprecated(DEPRECATED_TARGET_MESSAGE) + @Deprecated(DEPRECATED_TARGET_MESSAGE, level = DeprecationLevel.ERROR) val wasm32 = KonanTarget.WASM32 } \ No newline at end of file diff --git a/native/utils/src/org/jetbrains/kotlin/konan/target/KonanTarget.kt b/native/utils/src/org/jetbrains/kotlin/konan/target/KonanTarget.kt index 1547b7379c2..11f059a7ecd 100644 --- a/native/utils/src/org/jetbrains/kotlin/konan/target/KonanTarget.kt +++ b/native/utils/src/org/jetbrains/kotlin/konan/target/KonanTarget.kt @@ -9,7 +9,7 @@ import org.jetbrains.kotlin.konan.util.Named import java.io.Serializable private const val DEPRECATION_LINK = "https://kotl.in/native-targets-tiers" -const val DEPRECATED_TARGET_MESSAGE = "Target is deprecated and will be removed soon. See: $DEPRECATION_LINK" +const val DEPRECATED_TARGET_MESSAGE = "Target is no longer available. See: $DEPRECATION_LINK" sealed class KonanTarget(override val name: String, val family: Family, val architecture: Architecture) : Named, Serializable { object ANDROID_X64 : KonanTarget("android_x64", Family.ANDROID, Architecture.X64)