Adds a new jarmode called 'tools'. This provides two commands,
'extract' and 'list-layers'. list-layers is the same as list from
the layertools.
extract is able to extract the JAR in four different modes:
- CDS compatible extraction with libraries in a lib folder and a runner
.jar
- CDS compatible as above, but with layers
- Launcher based
- Launcher based with layers. This is essentially the same as extract
from the layertools
The commands in layertools have been deprecated in favor of the commands
in 'tools'.
This also changes the behavior of layers.enabled from the Gradle and
Maven plugin: before this commit, layers.enabled prevents the inclusion
of the layer index file as well as the layertools JAR.
After this commit, layers.enabled only prevents the inclusion of the
layer index file.
layer.includeLayerTools have been deprecated in favor of includeTools,
and the layertools JAR has been renamed to tools.
Closes gh-38276