Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8254920

Application launched with jpackage produced .exe crashes JVM

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P2 P2
    • 16
    • 15, 16
    • deploy
    • Microsoft Windows [Version 10.0.19041.572]

      openjdk 15 2020-09-15
      OpenJDK Runtime Environment (build 15+36)
      OpenJDK 64-Bit Server VM (build 15+36, mixed mode)

    • 15
    • b24
    • x86_64
    • windows_10

      Creating an application image with jpackage from a JRE image produced with jlink and a set of jars, the resulting application crashes the JVM when launched by the .exe launcher created by jpackage, but launches correctly when using the java.exe from the JRE image.
      The .cfg file only has mainclass and classpath info, no JVM options.

      When running from the application image folder (the one with app and runtime sub-folders) with the command line:

      runtime\bin\java.exe -cp app\libs\* mainclassname

      the application launches and runs as expected.
      Launching via the application .exe file produces the crash report attached.
      The JRE image was created with:

      jlink.exe --no-header-files --no-man-pages --compress=2 --add-modules javafx.controls,javafx.fxml,java.prefs,java.logging,java.management,jdk.jdwp.agent --output C:\dev\MyApp\build\image\runtime

      jpackage used the following command line:

      jpackage.exe --type app-image --verbose --temp C:\dev\MyApp\build\tmp\image --app-version 1.0.4 --input C:\dev\MyApp\build\image\app --runtime-image C:\dev\MyApp\build\image\runtime --name "My Server Admin" --main-jar libs\MyApp-1.0.4.jar --main-class my.domain.serveradmin.MyServerAdminApp --resource-dir src/main/deploy/package/windows --icon "src/main/deploy/package/windows/My Server Admin.ico" --description "My Server Administration Application" --vendor "My Company" --copyright "Copyright (c) 2015-2020 My Company Corp." --dest C:\dev\MyApp\build\application

            herrick Andy Herrick (Inactive)
            swpalmer Scott Palmer
            Votes:
            0 Vote for this issue
            Watchers:
            9 Start watching this issue

              Created:
              Updated:
              Resolved: