JetBrains / compose-multiplatform

Compose Multiplatform, a modern UI framework for Kotlin that makes building performant and beautiful user interfaces easy and enjoyable.
https://jetbrains.com/lp/compose-multiplatform
Apache License 2.0
16.32k stars 1.18k forks source link

Fatal error signing Mac App #3060

Closed mgroth0 closed 1 year ago

mgroth0 commented 1 year ago

Describe the bug

I am building a desktop application. The build works completely fine without signing. With signing, I get the following error:

Caused by: org.gradle.api.InvalidUserCodeException: Starting an external process '/usr/bin/security find-certificate -a -c Developer ID Application: <my dev id> <my-keychain-path>' during configuration time is unsupported.

Affected platforms

Desktop

Versions

To Reproduce

  1. Create a desktop project using the versions above. I suspect the gradle version is the most critical one.
  2. In the buildscript, configure the mac app to be signed
  3. Execute the build

Expected behavior

The build to succeed

Workaround

Use --no-configuration-cache in the gradle process. However, this prevents using the configuration cache.

Additional context

I suspect this issue is related to the latest Gradle version. Gradle has been tightening restrictions related to the configuration cache.

dima-avdeev-jb commented 1 year ago

What MacOS version do you have?

dima-avdeev-jb commented 1 year ago

Can you please create a minimal reproducible sample on GitHub?

mgroth0 commented 1 year ago

Mac OSX 13.3.1

mgroth0 commented 1 year ago

Here it is

https://github.com/mgroth0/minesweeper-mac-sign-gradle-config-cache-error

  1. Clone it
  2. Create identity.txt in the root folder with your Devloper ID identity
  3. Create keychain.txt with a path to your keychain.db file
  4. Run gradle desktopApp:createDistributable

You should see the error.

okushnikov commented 4 months ago

Please check the following ticket on YouTrack for follow-ups to this issue. GitHub issues will be closed in the coming weeks.