I follow the instructions in the quick start guide for getting the fast release of Java 9 Jigsaw at http://openjdk.java.net/projects/jigsaw/quick-start
➜ tmp java --version
java 9-ea
Java(TM) SE Runtime Environment (build 9-ea+172)
Java HotSpot(TM) 64-Bit Server VM (build 9-ea+172, mixed mode)
The jar command is taken from the correct Java 9 directory.
➜ tmp which jar
/Library/Java/JavaVirtualMachines/jdk-9.jdk/Contents/Home/bin/jar
One of the steps in the quick start guide says that to run the jar command with a parameter --print-module-descriptor, however, when I try, I get an error message below.
➜ tmp jar --print-module-descriptor --file=mlib/org.astro@1.0.jar
unrecognized option : --print-module-descriptor
Try `jar --help' for more information.
This option does not seem to exist in the latest version. Was the early access build removed or moved to another location? jar --helpbelow for reference
➜ tmp jar
Usage: jar [OPTION...] [ [
jar creates an archive for classes and resources, and can manipulate or
restore individual classes or resources from an archive.
Examples:
jar
jar
jar
-C foo/ classes resources
jar
-C foo/ module-info.class
jar
To shorten or simplify the jar command, you can specify arguments in a separate
text file and pass it to the jar command with the at sign (@) as a prefix.
Examples:
jar
Main operation mode:
-c,
-i,
archives
-t,
-u,
-x,
-d,
Operation modifiers valid in any mode:
-C DIR Change to the specified directory and include the
following file
-f,
stdout is used based on the operation
of the jar (i.e. META-INF/versions/VERSION/)
-v,
Operation modifiers valid only in create and update mode:
-e,
applications bundled into a modular, or executable,
jar archive
-m,
manifest file
-M,
jar, or updating a non-modular jar
matched by the given pattern and that depend upon
directly or indirectly on a modular jar being
created or a non-modular jar being updated
-p,
the hash
Operation modifiers valid only in create, update, and generate-index mode:
-0,
Other options:
-h,
An archive is a modular jar if a module descriptor, 'module-info.class', is
located in the root of the given directories, or the root of the jar archive
itself. The following operations are only valid when creating a modular jar,
or updating an existing non-modular jar: '--module-version',
'--hash-modules', and '--module-path'.
Mandatory or optional arguments to long options are also mandatory or optional
for any corresponding short options.