https://kotlinlang.org logo
#multiplatform
Title
# multiplatform
y

ynsok

09/26/2023, 1:07 PM
Hi, How can I maps custom Xcode configuration to NativeBuildType without using cocoapods ?
Copy code
ios {
    binaries {
        framework {
            baseName = "shared"
        }
    }
}
j

jamshedalamqaderi

09/26/2023, 1:08 PM
Are you searching for this
y

ynsok

09/26/2023, 1:13 PM
yes, but it is available just in cocoapods block
j

jamshedalamqaderi

09/26/2023, 1:14 PM
then what do you need?
y

ynsok

09/26/2023, 1:15 PM
I want to achieve the same result without using cocoapods, so in this case, maps custom Xcode configuration to NativeBuildType
j

jamshedalamqaderi

09/26/2023, 1:17 PM
it is not possible. You need to configure scheme in xcode and then map the configuration in cocoapod plugin in shared module
I'm doing it like this and i don't need to use pod install command while building for ios
Copy code
androidTarget()

    iosX64()
    iosArm64()
    iosSimulatorArm64()

    cocoapods {
        version = "1.0"
        ios.deploymentTarget = "11.0"
        framework {
            isStatic = true
            baseName = "shared"
        }

        xcodeConfigurationToNativeBuildType["Debug-Staging"] =
            NativeBuildType.DEBUG
        xcodeConfigurationToNativeBuildType["Debug-Production"] =
            NativeBuildType.DEBUG
        xcodeConfigurationToNativeBuildType["Release-Staging"] =
            NativeBuildType.RELEASE
        xcodeConfigurationToNativeBuildType["Release-Production"] =
            NativeBuildType.RELEASE
    }
4 Views