RFR: 8357404: jpackage should attempt to get a package version from the JDK's release file if the --version option is not specified [v2]

Alexey Semenyuk asemenyuk at openjdk.org
Fri Jan 16 23:34:44 UTC 2026


On Fri, 16 Jan 2026 22:42:10 GMT, Alexander Matveev <almatvee at openjdk.org> wrote:

> Why we need to normalize version then?

Same reason why we do this for the app version in the "release" file. Why would it be different?

> For example jar can have: 1.2.3-SNAPSHOT. In this case JarVersionReader will return 1.2.3

 - What would `RuntimeVersionReader` and `ModuleVersionReader` return for this input?
 - Why would the `JarVersionReader` strip the "-SNAPSHOT" prefix? On Linux, there are no restrictions similar to those of macOS and Windows for version string. "1.2.3-SNAPSHOT" is a valid rpm/deb version.

-------------

PR Comment: https://git.openjdk.org/jdk/pull/29260#issuecomment-3762212499


More information about the core-libs-dev mailing list