如何将 JAVA 9 JRE/JDK 作为 zip 文件而不是 EXE 或 MSI 安装程序?

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/33322758/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-11-02 21:30:59  来源:igfitidea点击:

How can I get JAVA 9 JRE / JDK as a zip file rather than EXE or MSI installer?

javajava-9

提问by vaquar khan

How can I get JAVA 9 JRE / JDK as a zip file rather than EXE or MSI installer?

如何将 JAVA 9 JRE/JDK 作为 zip 文件而不是 EXE 或 MSI 安装程序?

https://jdk9.java.net/download/

https://jdk9.java.net/download/

采纳答案by Paul Verest

Look at https://jdk9.java.net/carefully there's "JDK 9 Early Access with Project Jigsaw" that is actually zip download.

仔细查看https://jdk9.java.net/有“JDK 9 Early Access with Project Jigsaw”,它实际上是 zip 下载。

回答by Pahari Chora

回答by ftr

As mentionend you can download the jigsaw distribution or you can follow the instructions from hereto build your own distribution.

如前所述,您可以下载拼图发行版,也可以按照此处的说明构建自己的发行版。

回答by Chandra Sekhar

You can download JDK 9 Early-Access Builds from jdk.java.net, All other locations (jdk9-builds, jdk9.java.net) are not accessible/migrated.

您可以从jdk.java.net下载 JDK 9 Early-Access Builds ,所有其他位置(jdk9-buildsjdk9.java.net)均不可访问/迁移。

回答by Chris Thistlethwaite

From here: https://stackoverflow.com/a/6571736/8714033

从这里:https: //stackoverflow.com/a/6571736/8714033

  • Create working JDK directory (C:\JDKin this case)
  • [Download][1] latest version of JDK from Oracle (for example jdk-7u7-windows-x64.exe)
  • [Download][2] and install 7-Zip (or download [7-Zip portable][3] version if you are not administrator)
  • With 7-Zip extract all the files from jdk-XuXX-windows-x64.exeinto the directory C:\JDK
  • Execute the following commands in cmd.exe:
    • cd C:\JDK\.rsrc\1033\JAVA_CAB10
    • extrac32 111
  • Unpack C:\JDK\.rsrc\1033\JAVA_CAB10\tools.zipwith 7-zip
  • Execute the following commands in cmd.exe:
    • cd C:\JDK\.rsrc\1033\JAVA_CAB10\tools\
    • for /r %x in (*.pack) do .\bin\unpack200 -r "%x" "%~dx%~px%~nx.jar"(this will convert all .packfiles into .jarfiles)
  • Copy all contents of C:\JDK\.rsrc\1033\JAVA_CAB10\toolswhere you want your JDK to be
  • Setup JAVA_HOMEand PATHmanually to point to your JDK dir and its BIN subdirectory.
  • 创建工作 JDK 目录(C:\JDK在本例中)
  • [下载][1] 来自 Oracle 的最新版 JDK(例如jdk-7u7-windows-x64.exe
  • [下载][2] 并安装 7-Zip(如果您不是管理员,请下载 [7-Zip 便携版][3] 版本)
  • 使用 7-Zip 将所有文件从jdk-XuXX-windows-x64.exe目录中解压缩C:\JDK
  • 在 中执行以下命令cmd.exe
    • cd C:\JDK\.rsrc\1033\JAVA_CAB10
    • extrac32 111
  • C:\JDK\.rsrc\1033\JAVA_CAB10\tools.zip用 7-zip打开包装
  • 在 中执行以下命令cmd.exe
    • cd C:\JDK\.rsrc\1033\JAVA_CAB10\tools\
    • for /r %x in (*.pack) do .\bin\unpack200 -r "%x" "%~dx%~px%~nx.jar"(这会将所有.pack文件转换为.jar文件)
  • 复制C:\JDK\.rsrc\1033\JAVA_CAB10\tools您希望 JDK 所在位置的所有内容
  • 设置JAVA_HOMEPATH手动指向您的 JDK 目录及其 BIN 子目录。

Though my experience was a bit different, tools.zip can be in a different place depending on JDK version.

虽然我的经验有点不同,但根据 JDK 版本,tools.zip 可以位于不同的位置。