[go: nahoru, domu]

blob: 2ac5989f9dcf91732853daff23a7dbdd977aaa65 [file] [log] [blame]
/**
* This file was created using the `create_project.py` script located in the
* `<AndroidX root>/development/project-creator` directory.
*
* Please use that script when creating a new project, rather than copying an existing project and
* modifying its settings.
*/
import androidx.build.KmpPlatformsKt
import androidx.build.PlatformIdentifier
import androidx.build.Publish
import org.jetbrains.kotlin.gradle.plugin.KotlinPlatformType
import org.jetbrains.kotlin.gradle.plugin.mpp.BitcodeEmbeddingMode
plugins {
id("AndroidXPlugin")
}
def enableNative = KmpPlatformsKt.enableNative(project)
androidXMultiplatform {
// needed for snapshot publishing to trigger component creation
jvm()
// default platform is not JVM but we need to use it because it is
// the only platform built on all machines
defaultPlatform(PlatformIdentifier.JVM)
ios {
compilations.main {
cinterops {
xcTestInterop {
defFile project.file("src/nativeInterop/cinterop/xcTestInterop.def")
// https://youtrack.jetbrains.com/issue/KT-48807#focus=Comments-27-5210791.0-0
compilerOpts("-DNS_FORMAT_ARGUMENT(A)=")
}
}
}
binaries.framework {
baseName = "AndroidXBenchmarkXCTest"
// https://youtrack.jetbrains.com/issue/KT-48552
embedBitcode = BitcodeEmbeddingMode.DISABLE
}
}
// put mac configuration inside an if to avoid warnings due to unused source sets
// when building on linux
if (enableNative) {
sourceSets {
// Need a source file to force a klib creation.
// see: https://youtrack.jetbrains.com/issue/KT-52344
darwinMain {}
targets.all { target ->
if (target.platformType == KotlinPlatformType.native) {
target.compilations["main"].defaultSourceSet {
dependsOn(darwinMain)
}
}
}
}
}
}
androidx {
name = "Benchmarks - Darwin Core"
inceptionYear = "2022"
description = "AndroidX Benchmarks - Darwin Core"
publish = Publish.SNAPSHOT_ONLY
}