-
Enhancement
-
Resolution: Fixed
-
P4
-
18
-
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.
* 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.
- duplicates
-
JDK-8281215 Hotspot fails to build with --with-version-string=19
-
- Closed
-