CLion/AppCode: Use LLDB bindings in Kotlin/Native debugger
This commit is contained in:
+11
@@ -244,8 +244,18 @@ class KotlinNativeTargetPreset(
|
||||
private val kotlinPluginVersion: String
|
||||
) : KotlinTargetPreset<KotlinNativeTarget> {
|
||||
|
||||
init {
|
||||
// This is required to obtain Kotlin/Native home in CLion plugin:
|
||||
setupNativeHomePrivateProperty()
|
||||
}
|
||||
|
||||
override fun getName(): String = name
|
||||
|
||||
private fun setupNativeHomePrivateProperty() = with(project) {
|
||||
if (!hasProperty(KOTLIN_NATIVE_HOME_PRIVATE_PROPERTY))
|
||||
extensions.extraProperties.set(KOTLIN_NATIVE_HOME_PRIVATE_PROPERTY, konanHome)
|
||||
}
|
||||
|
||||
private fun setupNativeCompiler() = with(project) {
|
||||
if (!hasProperty(KotlinNativeProjectProperty.KONAN_HOME_OVERRIDE)) {
|
||||
NativeCompilerDownloader(this).downloadIfNeeded()
|
||||
@@ -343,6 +353,7 @@ class KotlinNativeTargetPreset(
|
||||
|
||||
companion object {
|
||||
private const val KOTLIN_NATIVE_FAKE_REPO_NAME = "Kotlin/Native default libraries"
|
||||
private const val KOTLIN_NATIVE_HOME_PRIVATE_PROPERTY = "konanHome"
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user