Mike Dawson
01/27/2024, 8:10 PMMichael Paus
01/28/2024, 9:08 AMproguard {
version.set("7.4.0")
isEnabled.set(true)
optimize.set(false)
obfuscate.set(false)
configurationFiles.from(project.file("<http://compose-desktop.pro|compose-desktop.pro>"))
}
The main point is to enable ProGuard. I then switch off obfuscation and optimization because I found that their benefit is small on desktop and they are causing their own problems which are just not worth the effort.
To further shrink your code it would be much better to repack the sqlite library so that it just contains the binary for the respective platform you are building for. (I did that and it works nicely. I wonder why ProGuard can’t do that itself.)
Yet another option would be to vote to get this issue fixed which just wastes more than 20 MB on ARM macs. https://github.com/JetBrains/compose-multiplatform/issues/3859Mike Dawson
01/28/2024, 9:24 AMMichael Paus
01/28/2024, 9:29 AMMike Dawson
01/28/2024, 9:31 AMMichael Paus
01/28/2024, 9:37 AMMike Dawson
01/28/2024, 9:40 AMMichael Paus
01/28/2024, 9:43 AMMike Dawson
01/28/2024, 9:45 AMMike Dawson
01/28/2024, 9:46 AMMike Dawson
01/28/2024, 9:47 AMMichael Paus
01/28/2024, 9:51 AMMike Dawson
01/28/2024, 10:48 AMMichael Paus
01/28/2024, 7:05 PMmikehearn
02/01/2024, 10:44 AMmikehearn
02/01/2024, 10:45 AMmikehearn
02/01/2024, 10:45 AM