RFR: 8274980: Improve adhoc build version strings [v4]

TheShermanTanker duke at openjdk.java.net
Fri Feb 4 10:36:05 UTC 2022


On Fri, 4 Feb 2022 10:05:09 GMT, Aleksey Shipilev <shade at openjdk.org> wrote:

> > If that's the case, I'm wondering if instead of changing `18-internal+0-adhoc.shade.jdk (18-internal)` to something like `18-internal-jdk-18+17-80-gcdf89304eaf.shade (18-internal)`, `build 18<+build number, not required>-internal-<branch name + commit id>` would be more understandable and slightly easier on one's eyes, while conveying the same information the usual (verbose) version string otherwise tries to display
> 
> We have been discussing this (see the bug comments in JIRA). The showstopper is that versions are captured during `configure`, which means you can configure on one branch, switch to another, and your build would still be recorded as produced by old branch.

I must've missed that, my bad. I was referring to the original issue though, where the final generated version string is ultimately something along the lines of `18-internal-jdk-18+17-80.shade (18-internal)`, which could potentially be shortened to something like `build 18<+build number>-internal`, which is much less verbose and somewhat easier to understand.

All that aside though, would it be possible to detect the branch and commit at compile time?

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

PR: https://git.openjdk.java.net/jdk/pull/6152



More information about the build-dev mailing list