JDK-8118218 : fx:jar + fx:resources produces a jar with JavaFX-Class-Path attribute in the manifest
  • Type: Bug
  • Component: deploy
  • Sub-Component: packager
  • Affected Version: 8
  • Priority: P3
  • Status: Resolved
  • Resolution: Duplicate
  • Submitted: 2013-10-23
  • Updated: 2015-06-17
  • Resolved: 2013-11-14
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 8
8Resolved
Related Reports
Duplicate :  
Relates :  
Description
The JavaFX-Class-Path attribute is obsolete, the packager should stop using it.

Consider a call to packager like that:

        <fx:jar destfile="${dist.dir}/unsigned/App.jar">
            <fx:application refid="com.company.app.name"/>
            <fx:platform refid="myPlatform"/>
            <fileset dir="${build.classes.dir}"/>
            <fx:resources>
                <fx:fileset dir="${basedir}/${dist.dir}/signed"
                            includes="Kit.jar"/>
            </fx:resources>
            <manifest>
                <attribute name="Implementation-Title" value="${application.title}"/>
                <attribute name="Implementation-Vendor" value="${application.vendor}"/>
                <attribute name="Implementation-Version" value="${application.version.extended}"/>
            </manifest>
        </fx:jar>

As a consequence the manifest of App.jar contains the JavaFX-Class-Path attribute:

Manifest-Version: 1.0
Created-By: JavaFX Packager
JavaFX-Application-Class: com.whatever.App
Main-Class: com/javafx/main/Main
JavaFX-Version: 8.0+
Implementation-Title: My Title
Implementation-Version: 1.0
Implementation-Vendor: Vendor Name
JavaFX-Class-Path: Kit.jar
Comments
Resolving this issue in https://javafx-jira.kenai.com/browse/RT-34236
14-11-2013

https://javafx-jira.kenai.com/browse/RT-34236
14-11-2013

If I put a Class-Path attribute in my ant task calling fx:jar it has no effect, the manifest sill contains JavaFX-Class-Path and only this.
13-11-2013

Quoting David DeHaven: "It's deprecated and only supported for backwards compatibility, and is practically guaranteed to break at some point in the future. Just use Class-Path if you need to load additional jar files. The accepted JavaFX-* attributes are listed in the launcher code (I can't remember the path offhand..) Those changed over the summer when we implemented the FX side of launcher changes to allow the SE launcher to start JavaFX jars easily from the command line, e.g., "java -jar fxapp.jar". You *might* be able to (temporarily) work around it by adding a matching "Class-Path" attribute. I don't recall if the FX launcher ignores JavaFX-Class-Path in that case. Otherwise you could probably remove the fx:resources section and manually add Class-Path in the manifest section."
23-10-2013