Notarizing exported application on macOS 10.15 (Catalina)

I am trying to notarize an exported application on macOS 10.15 (Catalina) as it is required. My steps are as follows.

  1. Export application without embedding Java. “JDK 14 is the first release that complies with the new macOS 10.15 hardening and notarization requirements.”, yet “…Processing supports Java 1.8.”
  2. Execute the following in Terminal
unzip jogl-all-natives-macosx-universal.jar -d jogl-all-natives-macosx-universal
unzip gluegen-rt-natives-macosx-universal.jar -d gluegen-rt-natives-macosx-universal
codesign --timestamp --options=runtime -s "my identity" -v gluegen-rt-natives-macosx-universal/natives/macosx-universal/libgluegen-rt.jnilib
codesign --timestamp --options=runtime -s "my identity" -v jogl-all-natives-macosx-universal/natives/macosx-universal/lib*
rm gluegen-rt-natives-macosx-universal.jar
rm jogl-all-natives-macosx-universal.jar
jar cvfM gluegen-rt-natives-macosx-universal.jar -C gluegen-rt-natives-macosx-universal .
jar cvfM jogl-all-natives-macosx-universal.jar -C jogl-all-natives-macosx-universal .
rm -r gluegen-rt-natives-macosx-universal/
rm -r jogl-all-natives-macosx-universal/
cd ../../..
codesign --timestamp --options=runtime -s "my identity" -v
ditto -c -k --keepParent
xcrun altool --notarize-app --primary-bundle-id --username my.username --password my-password --file

I receive an email from Apple saying my software has been notarized. However when I run my application I receive a window with the message “Unable to load Java Runtime Environment.” I understand that the developers “…strongly recommended that you embed Java with your application.”, but I am unable to notarize an exported application with Java embedded. Is there a way to notarize an exported application on Catalina?

Try using a recent OpenJDK 8 from eg. AdoptOpenJDK - see info on notarization at