Leonid Startsev | 9f6d3b4 | 2019-10-09 18:07:41 +0300 | [diff] [blame] | 1 | /* |
Leonid Startsev | 8cbdbfc | 2021-09-06 14:11:34 +0300 | [diff] [blame] | 2 | * Copyright 2017-2021 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license. |
Leonid Startsev | 9f6d3b4 | 2019-10-09 18:07:41 +0300 | [diff] [blame] | 3 | */ |
| 4 | |
Clara Fok | 93e1812 | 2024-04-23 10:28:10 -0700 | [diff] [blame] | 5 | static def doesNotDependOnOkio(project) { |
| 6 | return !project.name.contains("json-okio") && !project.name.contains("json-tests") |
Leonid Startsev | b2e9104 | 2020-10-02 15:44:18 +0300 | [diff] [blame] | 7 | } |
| 8 | |
Leonid Startsev | 9f6d3b4 | 2019-10-09 18:07:41 +0300 | [diff] [blame] | 9 | kotlin { |
Clara Fok | 93e1812 | 2024-04-23 10:28:10 -0700 | [diff] [blame] | 10 | applyDefaultHierarchyTemplate { |
Vsevolod Tolstopyatov | 608cbad | 2020-09-14 15:38:02 +0300 | [diff] [blame] | 11 | |
Clara Fok | 93e1812 | 2024-04-23 10:28:10 -0700 | [diff] [blame] | 12 | // According to https://kotlinlang.org/docs/native-target-support.html |
| 13 | // Tier 1 |
| 14 | macosX64() |
| 15 | macosArm64() |
| 16 | iosSimulatorArm64() |
| 17 | iosX64() |
Vsevolod Tolstopyatov | 608cbad | 2020-09-14 15:38:02 +0300 | [diff] [blame] | 18 | |
Clara Fok | 93e1812 | 2024-04-23 10:28:10 -0700 | [diff] [blame] | 19 | // Tier 2 |
| 20 | linuxX64() |
| 21 | linuxArm64() |
| 22 | watchosSimulatorArm64() |
| 23 | watchosX64() |
| 24 | watchosArm32() |
| 25 | watchosArm64() |
| 26 | tvosSimulatorArm64() |
| 27 | tvosX64() |
| 28 | tvosArm64() |
| 29 | iosArm64() |
Leonid Startsev | 9f6d3b4 | 2019-10-09 18:07:41 +0300 | [diff] [blame] | 30 | |
Clara Fok | 93e1812 | 2024-04-23 10:28:10 -0700 | [diff] [blame] | 31 | // Tier 3 |
| 32 | mingwX64() |
| 33 | // https://github.com/square/okio/issues/1242#issuecomment-1759357336 |
| 34 | if (doesNotDependOnOkio(project)) { |
| 35 | androidNativeArm32() |
| 36 | androidNativeArm64() |
| 37 | androidNativeX86() |
| 38 | androidNativeX64() |
| 39 | watchosDeviceArm64() |
Leonid Startsev | 9f6d3b4 | 2019-10-09 18:07:41 +0300 | [diff] [blame] | 40 | |
Clara Fok | 93e1812 | 2024-04-23 10:28:10 -0700 | [diff] [blame] | 41 | // Deprecated, but not removed |
| 42 | linuxArm32Hfp() |
Leonid Startsev | 9f6d3b4 | 2019-10-09 18:07:41 +0300 | [diff] [blame] | 43 | } |
| 44 | } |
| 45 | } |