Mac 安装 jdk11
时间: 2023-08-28 16:05:04 浏览: 187
JDK11 for Mac
要在Mac上安装jdk11,可以按照以下步骤进行操作:
1. 首先,从Oracle官网下载jdk11的安装包。你可以在找到jdk11的下载链接。
2. 下载完成后,打开终端并输入以下命令,以查找刚刚安装好的jdk11的路径:
```
open /Library/Java/JavaVirtualMachines/
```
在这个路径下,你应该能找到刚刚安装的jdk11。
3. 接下来,输入以下命令,用vim编辑.bash_profile文件:
```
vim ~/.bash_profile
```
在该文件中,你需要添加以下代码:
```
JAVA_HOME=/Library/Java/JavaVirtualMachines/jdk-11.0.17.jdk/Contents/Home
#JAVA_HOME=/Library/Java/JavaVirtualMachines/jdk-17.0.5.jdk/Contents/Home
#JAVA_HOME=/Library/Internet Plug-Ins/JavaAppletPlugin.plugin/Contents/Home
PATH=$JAVA_HOME/bin:$
#### 引用[.reference_title]
- *1* *3* [MAC下Neo4j、jdk11的安装](https://blog.csdn.net/moumoumouwang/article/details/128560929)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v93^chatsearchT3_2"}}] [.reference_item style="max-width: 50%"]
- *2* [mac m2 安装jdk11](https://blog.csdn.net/qq_42483257/article/details/122285679)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v93^chatsearchT3_2"}}] [.reference_item style="max-width: 50%"]
[ .reference_list ]
阅读全文