【深入浅出-JVM】(4):编译 jdk

环境

mac,xcode,jdk8,openjdk,autoconf



步骤

  1. 安装autoconf

brew install autoconf

  1. 下载openjdk源码

git clone https://github.com/unofficial-openjdk/openjdk.git

cd openjdk && git checkout -b build

  1. 在openjdk 根目录下执行编译脚本,大约 10 分钟不到,执行完成

bash configure --enable-debug --with-jvm-variants=server --enable-dtrace

make jdk

  1. 进入编译的输出的jdk目录,执行 java -version


感谢您的耐心阅读,如果您发现文章中有一些没表述清楚的,或者是不对的地方,请给我留言,您的鼓励是作者写作最大的动力。

作 者 : @mousycoder

原文出处 : http://mousycoder.com/thinking-in-jvm/4/

posted @ 2019-07-15 16:32  mousycoder  阅读(231)  评论(0编辑  收藏  举报