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

Improve adhoc build version strings

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Fixed
    • Icon: P4 P4
    • 19
    • 18
    • infrastructure
    • b10

      Current default version strings are not very descriptive:

      * Version string: 18-internal+0-adhoc.shade.jdk (18-internal)

      They do not tell where the code is built from. It does print $basedir, but that is almost always something generic like "jdk". Adhoc builds also have generic build "+0". This might be improved by using for example "git describe":

      * Version string: 18-internal-jdk-18+17-80-gcdf89304eaf.shade (18-internal)

      A dirty patch does this:

      diff --git a/make/autoconf/jdk-version.m4 b/make/autoconf/jdk-version.m4
      index 60405d67bcb..b4e46f4b5bd 100644
      --- a/make/autoconf/jdk-version.m4
      +++ b/make/autoconf/jdk-version.m4
      @@ -239,10 +239,10 @@ AC_DEFUN_ONCE([JDKVER_SETUP_JDK_VERSION_NUMBERS],
           fi
         else
           if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then
      - # Default is to calculate a string like this 'adhoc.<username>.<base dir name>'
      + # Default is to calculate a string like this '<description>.<username>'
             # Outer [ ] to quote m4.
      - [ basedirname=`$BASENAME "$TOPDIR" | $TR -d -c '[a-z][A-Z][0-9].-'` ]
      - VERSION_OPT="adhoc.$USERNAME.$basedirname"
      + [ description=`git describe` ]
      + VERSION_OPT="$description.$USERNAME"
           fi
         fi
       
      ...but it needs to handle the trees that are not covered by Git.

            ihse Magnus Ihse Bursie
            shade Aleksey Shipilev
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: