This week's book giveaway is in the HTML Pages with CSS and JavaScript forum.
We're giving away four copies of Testing JavaScript Applications and have Lucas da Costa on-line!
See this thread for details.
Win a copy of Testing JavaScript Applications this week in the HTML Pages with CSS and JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Carey Brown

JPackage question

 
Ranch Hand
Posts: 59
5
Netbeans IDE Python Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I use jpackage to create installers for my application. I've been using the incubator builds for some time now and been very happy with the results. I am now moving up to the Java 14 version and have run into some problems that I'm hoping folks here might have pointers for.

My problem is that when the program is packaged for OSX, it is signed in a way that I don't want it to be. I would prefer that there be no signature at all. Currently it's getting an Oracle signature. Initially the build works fine... but if it is uploaded then downloaded, the OS puts metadata on the files that invalidates the signature. I am hoping that this is just an artifact of using the Oracle version and the OpenJDK 14 vuild will take care of this. At the same time, I would also like to address this before then if possible, since I am looking to release shortly after the drop of Open JDK 14 (scheduled for the 17th). Below is how I'm using the tool.



I know that you can use the --mac-sign option to request that a build be signed, but is there anything you can do to specify that it not be signed? Conversely, is it possible that the signing is somehow happening earlier?

Any advice much appreciated!
 
Draque Thompson
Ranch Hand
Posts: 59
5
Netbeans IDE Python Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
As an additional clue, I know that if I strip off the file attributes of everything in my app manually by hitting it with "xattr -r-c". This tells me that it's absolutely some kind of weird signing thing going on which prevents it from running when it detects that it has been downloaded from somewhere unexpected.

Again, really scratching my head here, and any help would be super appreciated.
 
Draque Thompson
Ranch Hand
Posts: 59
5
Netbeans IDE Python Java
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Found the solution. This one is kind of annoying.

JPackage entitlements and signing are currently broken in OSX. This is a known bug.

In the meantime, here is what to do.

1) Do NOT build a dmg file. Instead build an app file.
2) Using xcode/keychain get a developer identity key
2) Manually do your code signing.

3) Using some utility like dmgbuild, build your dmg installer file manually
 
Straws are for suckers. Now suck on this tiny ad!
Thread Boost feature
https://coderanch.com/t/674455/Thread-Boost-feature
    Bookmark Topic Watch Topic
  • New Topic