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

Sam

08/23/2020, 9:22 PM
Hello everyone, Good day you guys, I’m researching about Kotlin / Native to build desktop and iOS apps So I want to ask about your experiences before presentation for my boss. 1. I want to build an desktop app for windows/macos, Can I use TornadoFX? or only Kotlin/Native is enough for build the app?. 2. How to create an Installer for Windows / MacOS ? ( like dmg or setup.exe) 3. Is it possible to use the Swift library (3rd) to integrate with Kotlin/Native? Thanks.
a

aleksey.tomin

08/24/2020, 3:15 AM
2. For MacOS you can use this example: https://github.com/KosalaHerath/macos-installer-builder All software in MacOS For Windows just use Inno Setup. GitHub actions contains it
s

Sam

08/24/2020, 3:20 AM
Thanks @aleksey.tomin.
l

louiscad

08/24/2020, 9:03 AM
1. TornadoFx is for JVM apps, so you'll not be able to access Swift libraries, but you can make it run on Linux, Windows and macOS with a JRE/JVM. 3. Only if that Swift library exposes its API to Obj-C (
@objcexport
IIRC). You can use it with the cocoapods plugin for Kotlin/Native.
s

Sam

08/25/2020, 8:26 AM
Thanks @louiscad. Can you explain more about build desktop app for Linux, Windows and macOS with Kotlin/Native? What kind of file to export to install on these OS?
l

louiscad

08/25/2020, 8:27 AM
I can't tell much as I didn't do it yet. I only tried library development for desktop targets of Kotlin/Native
a

aleksey.tomin

08/25/2020, 8:33 AM
Can you explain more about build desktop app for Linux, Windows and macOS with Kotlin/Native? What kind of file to export to install on these OS?
1. MacOS -
gradle build
will made an application file. You can create
pkg
(may be signed) file. You have to create a correct
Info.plist
. Someone can download and install this (with problems - https://it.nmu.edu/docs/allowing-third-party-applications-install-macbook ) 2. Windows -
gradle build
will made an application
exe
file. InnoSetup create
exe
installator. Someone can download and install this after warning.
❤️ 1