jdeps 命令与“--multi-release”选项一起使用失败
jdeps command use with `--multi-release` option failed
我运行以下命令,但我得到了同样的错误:
$ jdeps --generate-module-info . --multi-release 9 libs/log4j-core-2.11.1.jar
Error: log4j-core-2.11.1.jar is a multi-release jar file but --multi-release option is not set
$ jdeps --generate-module-info . --multi-release 10 libs/log4j-core-2.11.1.jar
Error: log4j-core-2.11.1.jar is a multi-release jar file but --multi-release option is not set
$ jdeps --generate-module-info . --multi-release 11 libs/log4j-core-2.11.1.jar
Error: log4j-core-2.11.1.jar is a multi-release jar file but --multi-release option is not set
$ jdeps --generate-module-info . libs/log4j-core-2.11.1.jar
Error: log4j-core-2.11.1.jar is a multi-release jar file but --multi-release option is not set
以上命令有什么问题?
按照关于我的环境的其他命令:
$ java --version
openjdk 10.0.2 2018-07-17
OpenJDK Runtime Environment (build 10.0.2+13-Ubuntu-1ubuntu0.18.04.4)
OpenJDK 64-Bit Server VM (build 10.0.2+13-Ubuntu-1ubuntu0.18.04.4, mixed mode)
$ javac --version
javac 10.0.2
$ jdeps --version
10.0.2
与 java-11-oracle
相同的错误。
有一个 bug 与 --multi-release 选项一起使用模块
jdeps fails when executing on a non multi release jar and the --class-path contains multi release jars.
The opposite is also true.
jdeps fails when executing on a multi release jar with the appropriate --multi-release flag is set and the --class-path contains non multi release jars.
问题总结:
This basically makes multi-release jars unusable with modules.
JDK-8229396 修复了 jdeps --generate-module-info 选项以正确使用指定给 --multi-release 选项的版本来解析给定的多版本 JAR。此问题已在 14 中修复。请在接下来的几周内试用 EA 版本。
我运行以下命令,但我得到了同样的错误:
$ jdeps --generate-module-info . --multi-release 9 libs/log4j-core-2.11.1.jar
Error: log4j-core-2.11.1.jar is a multi-release jar file but --multi-release option is not set
$ jdeps --generate-module-info . --multi-release 10 libs/log4j-core-2.11.1.jar
Error: log4j-core-2.11.1.jar is a multi-release jar file but --multi-release option is not set
$ jdeps --generate-module-info . --multi-release 11 libs/log4j-core-2.11.1.jar
Error: log4j-core-2.11.1.jar is a multi-release jar file but --multi-release option is not set
$ jdeps --generate-module-info . libs/log4j-core-2.11.1.jar
Error: log4j-core-2.11.1.jar is a multi-release jar file but --multi-release option is not set
以上命令有什么问题?
按照关于我的环境的其他命令:
$ java --version
openjdk 10.0.2 2018-07-17
OpenJDK Runtime Environment (build 10.0.2+13-Ubuntu-1ubuntu0.18.04.4)
OpenJDK 64-Bit Server VM (build 10.0.2+13-Ubuntu-1ubuntu0.18.04.4, mixed mode)
$ javac --version
javac 10.0.2
$ jdeps --version
10.0.2
与 java-11-oracle
相同的错误。
有一个 bug 与 --multi-release 选项一起使用模块
jdeps fails when executing on a non multi release jar and the --class-path contains multi release jars. The opposite is also true. jdeps fails when executing on a multi release jar with the appropriate --multi-release flag is set and the --class-path contains non multi release jars.
问题总结:
This basically makes multi-release jars unusable with modules.
JDK-8229396 修复了 jdeps --generate-module-info 选项以正确使用指定给 --multi-release 选项的版本来解析给定的多版本 JAR。此问题已在 14 中修复。请在接下来的几周内试用 EA 版本。