Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

424
Visualizações
How to configure an iOS Application for Kotlin Multiplatform in Android Studio?

I want to add a Run/Debug Configuration for an iOS Application for a Kotlin Multiplatform Mobile application in Android Studio 4.1.2. However, there seems to be a problem with the configuration for iOS.

In the screenshot below you can see the problem. In the dialog "Run/Debug Configuration" Android Studio complains about

Error: Please specify Xcode project location in xcodeproj property of gradle.properties

Using the "Fix" button does not solve the problem. Android Studio just adds an additional xcodeproj to gradle.properties and the complains about a duplicate parameter.

I also tried different paths (relative and absolute) for xcodeproj. No luck.

If I remember correctly, it used to work out of the box. A new Kotlin Multiplatform Mobile project was automatically configured for Android and iOS. I'm not sure what changed. Probably something was updated.

Is this a bug with the KMM plugin? Or is there something I can do on my system to fix this?

enter image description here

over 4 years ago · Hanz Gallego
6 Respostas
Responde à pergunta

0

don't do that with Android Studio.

Just open Xcode, click on 'open another project...', locate to the iosApp folder that named it when creating your project on Android Studio.

after that, just click run and have fun.

enter image description here

over 4 years ago · Hanz Gallego Relatório

0

If the project doesn't run right away even on opening it from Xcode and shows the shared framework is missing, Then try generating the shared framework for iOS platform using terminal. Navigate to the project folder and execute
Command: ./gradlew packForXcode Now the shared framework should have a xcode-frameworks product and you should be able to build and run the project through Xcode.

over 4 years ago · Hanz Gallego Relatório

0

I fixed it by downgrading the Kotlin version from 1.4.30 to 1.4.21. You can check this thread here. To downgrade, download the version you want from the plugin store and choose the install plugin from disk as in the picture below install plugin from disc screenshot

over 4 years ago · Hanz Gallego Relatório

0

Upgrading Android Studio version to 4.2.1, KMM plugin version to 0.2.6, creating new KMM project with KMM plugin, the problem can be fixed automatically.

over 4 years ago · Hanz Gallego Relatório

0

If you don't wanna use Xcode:

Look like there is some IDE issues in this versions, one option would be to downgrade the Kotlin version.

What worked for me was to download the latest Canary Android Studio and setup my KMM project there.

Hopefully soon this will be stable for the next versions

over 4 years ago · Hanz Gallego Relatório

0

Same as here: https://stackoverflow.com/a/66941077/3117650

Look like there is some IDE issues in this versions, one option would be to downgrade the Kotlin version.

What worked for me was to download the latest Canary Android Studio and setup my KMM project there.

Hopefully soon this will be stable for the next versions

over 4 years ago · Hanz Gallego Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda