• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download

<lambda>null1 plugins {
2   kotlin("multiplatform") version "1.4.20"
3 }
4 
5 group = "com.google.flatbuffers.kotlin"
6 version = "2.0.0-SNAPSHOT"
7 
<lambda>null8 kotlin {
9   explicitApi()
10   jvm()
11   js {
12     browser {
13       binaries.executable()
14       testTask {
15         useKarma {
16           useChromeHeadless()
17         }
18       }
19     }
20   }
21   macosX64()
22   iosArm32()
23   iosArm64()
24   iosX64()
25 
26   sourceSets {
27     val commonMain by getting {
28       dependencies {
29         implementation(kotlin("stdlib-common"))
30       }
31     }
32 
33     val commonTest by getting {
34       dependencies {
35         implementation(kotlin("test-common"))
36         implementation(kotlin("test-annotations-common"))
37       }
38     }
39     val jvmTest by getting {
40       dependencies {
41         implementation(kotlin("test-junit"))
42       }
43     }
44     val jvmMain by getting {
45       kotlin.srcDir("java")
46       dependencies {
47         implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core-jvm:1.4.1")
48       }
49     }
50 
51     val jsMain by getting {
52       dependsOn(commonMain)
53     }
54     val jsTest by getting {
55       dependsOn(commonTest)
56       dependencies {
57         implementation(kotlin("test-js"))
58       }
59     }
60     val nativeMain by creating {
61         dependsOn(commonMain)
62     }
63     val nativeTest by creating {
64       dependsOn(commonMain)
65     }
66     val macosX64Main by getting {
67       dependsOn(nativeMain)
68     }
69 
70     val iosArm32Main by getting {
71       dependsOn(nativeMain)
72     }
73     val iosArm64Main by getting {
74       dependsOn(nativeMain)
75     }
76     val iosX64Main by getting {
77       dependsOn(nativeMain)
78     }
79 
80     all {
81       languageSettings.enableLanguageFeature("InlineClasses")
82       languageSettings.useExperimentalAnnotation("kotlin.ExperimentalUnsignedTypes")
83     }
84   }
85 
86   /* Targets configuration omitted.
87    *  To find out how to configure the targets, please follow the link:
88    *  https://kotlinlang.org/docs/reference/building-mpp-with-gradle.html#setting-up-targets */
89   targets {
90     targetFromPreset(presets.getAt("jvm"))
91     targetFromPreset(presets.getAt("js"))
92     targetFromPreset(presets.getAt("macosX64"))
93     targetFromPreset(presets.getAt("iosArm32"))
94     targetFromPreset(presets.getAt("iosArm64"))
95     targetFromPreset(presets.getAt("iosX64"))
96   }
97 }
98