fvarrui / JavaPackager

:package: Gradle/Maven plugin to package Java applications as native Windows, MacOS, or Linux executables and create installers for them.
GNU General Public License v3.0
1.07k stars 133 forks source link

Add compiled universalJavaApplicationStub as option #188

Closed AstroPixelProcessor closed 2 years ago

AstroPixelProcessor commented 2 years ago

This is my proposal to have the universalJavaApplicationStub compiled to a binayr before codesigning so projects that depend on JFileCHooser will have a properly working JFileChooser that can access the user's Documents/Downloads/Desktop folders.

I would suggest to offer this as an option in javapackager, since it needs an extra dependency. You need to have the shell compiler shc installed and available on the commandline using:

https://github.com/neurobin/shc

Download it with git clone https://github.com/neurobin/shc.git and.. ./configure make sudo make install

This is working properly on both intel and arm macs for my project and is completely inline with the information from universalJavaApplicationStub itself, so I can only assume it will work properly for all other projects with the current macOS security and privacy settings on the newest macOS versions.

fvarrui commented 2 years ago

As I explained to you in issue-187, I'm going to give it another approach. Sorry for refusign your PR!

AstroPixelProcessor commented 2 years ago

No problem Francisco @fvarrui ! I am sure that it will be good !