forked from eclipse-openj9/openj9-website
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathoj9_build.html
530 lines (473 loc) · 28.3 KB
/
oj9_build.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
<!DOCTYPE html>
<!--
Copyright (c) 2017, 2019 IBM Corp. and others
This program and the accompanying materials are made available under the terms of the Eclipse Public License 2.0 which accompanies this distribution and is available at http://eclipse.org/legal/epl-2.0 or the Apache License, Version 2.0 which accompanies this distribution and is available at https://www.apache.org/licenses/LICENSE-2.0.
This Source Code may also be made available under the following Secondary Licenses when the conditions for such availability set forth in the Eclipse Public License, v. 2.0 are satisfied: GNU General Public License, version 2 with the GNU Classpath Exception [1] and GNU General Public License, version 2 with the OpenJDK Assembly Exception [2].
[1] https://www.gnu.org/software/classpath/license.html
[2] http://openjdk.java.net/legal/assembly-exception.html
SPDX-License-Identifier: EPL-2.0 OR Apache-2.0 OR GPL-2.0 WITH Classpath-exception-2.0 OR LicenseRef-GPL-2.0 WITH Assembly-exception
The project website pages cannot be redistributed
-->
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>OpenJ9 - Build</title>
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Roboto">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/normalize/3.0.3/normalize.min.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.5.0/css/font-awesome.css">
<link rel="stylesheet" href="./css/oj9_media.css">
<link rel="stylesheet" href="./css/oj9_common.css">
<!-- Eclipse privacy popup -->
<link rel="stylesheet" type="text/css" href="//www.eclipse.org/eclipse.org-common/themes/solstice/public/stylesheets/vendor/cookieconsent/cookieconsent.min.css" />
<!-- End Eclipse privacy popup -->
<script type="text/javascript" src="./js/oj9_common.js"></script>
<!-- Google Tag Manager -->
<script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':
new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],
j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=
'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);
})(window,document,'script','dataLayer','GTM-5WLCZXC');</script>
<!-- End Google Tag Manager -->
<!-- Global site tag (gtag.js) - Google Analytics -->
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-105616558-3"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', 'UA-105616558-3', { 'anonymize_ip': true });
</script>
<!-- End Global site tag (gtag.js) - Google Analytics -->
</head>
<body onload="version('a')">
<div id="main-title">
<script type="text/javascript">navigation(document.location.href);</script>
<div class="title">
<a href="index.html">
<!--<img class="title_icon" src="./assets/openj9_6a.png" alt="Eclipse OpenJ9">-->
<img class="title_icon" src="./assets/openj9_6b.png" alt="Eclipse OpenJ9">
</a>
</div>
<div class="egg">
<a href="http://wiki.eclipse.org/Development_Resources/Process_Guidelines/What_is_Incubation" target="_blank"><img src="./assets/egg-incubation.png" alt="Eclipse Incubation"></a>
</div>
</div>
<main class="tabs_bg" id="build">
<div class="section-content" style="padding-bottom:0;">
<h1 style="padding-bottom: 10px;">Build your own OpenJDK</h1>
<ul class="tabs" id="version-tabs">
<li>
<a class="tab" href="#version-8">Version 8</a>
</li>
<li>
<a class="tab" href="#version-11">Version 11</a>
</li>
<li>
<a class="tab" href="#version-12">Version 12</a>
</li>
</ul>
</div>
<script>tabs('version-tabs');</script>
<!-- =========================================================================================== -->
<!-- CONTENT FOR VERSION 8 -->
<section id="version-8">
<div class="f-section-item">
<!-- set version -->
<span class="intro-text">Building OpenJDK™ 8 with OpenJ9 will be familiar to anyone who has already built OpenJDK.</span>
</div>
<div class="f-section-item">
<span class="intro-text1" style="margin:0 4rem;">We're going to use Docker to create a Docker container where you'll build a binary from source code and run some tests on it. Just follow these steps:</span>
</div>
<!-- set version x5 -->
<div class="f-section-item">
<ol class="toc">
<li><a href="#version-8:prepare">Prepare your system </a></li>
<li><a href="#version-8:get" >Get the source </a></li>
<li><a href="#version-8:config" >Configure your build </a></li>
<li><a href="#version-8:build9" >Build OpenJDK with OpenJ9 </a></li>
<li><a href="#version-8:test" >Test your binary </a></li>
</ol>
</div>
<!-- set version -->
<div class="f-section-item" id="version-8:prepare">
<div class="f-content-container">
<h3>Prepare your system</h3>
<p>
We'll start by building a Dockerfile.
</p>
<!-- set version x2 -->
<p style="font-size:.9rem; line-height:1.2rem"><i class="fa fa-pencil-square-o" aria-hidden="true" style="font-size:1rem;"></i> <strong>Note:</strong> The Dockerfile you'll use in these instructions creates the configuration that makes building OpenJDK with OpenJ9 very simple. If you don't want to use Docker or you want to build a binary for another platform, you'll need to reproduce the configuration for yourself. Read the <a href="https://github.com/eclipse/openj9/blob/master/doc/build-instructions/Build_Instructions_V8.md" target="-blank">full set of build instructions for JDK 8</a> to see what you'll need (including Apache FreeMarker™) and where to get it.
</p>
<p>If you don't already have Docker on your system, <a href="https://docs.docker.com/engine/installation/">download</a> and install it now.
</p>
<!-- set version -->
<p>Pick one of the following <strong>JDK v8</strong> Dockerfiles for the platform you want to work on:</p>
<!-- set version x3 -->
<ul>
<li><strong><a href="https://github.com/eclipse/openj9/blob/master/buildenv/docker/jdk8/x86_64/ubuntu16/Dockerfile" target="_blank">Linux 64-bit (x86_64)</a></strong></li>
<li><strong><a href="https://github.com/eclipse/openj9/blob/master/buildenv/docker/jdk8/ppc64le/ubuntu16/Dockerfile" target="_blank">Linux on Power systems 64-bit (ppc64)</a></strong></li>
<li><strong><a href="https://github.com/eclipse/openj9/blob/master/buildenv/docker/jdk8/s390x/ubuntu16/Dockerfile" target="_blank">Linux on z Systems 64-bit (390_64)</a></strong></li>
</ul>
<p>Save the Dockerfile to your current directory and specify these commands to build and run the Docker image:
</p>
<pre><code>docker build -t openj9 -f Dockerfile .</code>
<code>docker run -it openj9</code></pre>
<p>Depending on your <a href="https://docs.docker.com/engine/reference/commandline/cli/#description" target="_blank">Docker system configuration</a>, you might need to prefix these commands with <code>sudo</code>.
</p>
<p>Now that you have the Docker image running, you are ready to move to the next step.
</p>
</div>
</div>
<!-- set version -->
<div class="f-section-item" id="version-8:get">
<div class="f-content-container">
<h3>Get the source</h3>
<p>First you need to clone the <strong>Extensions for OpenJDK for Eclipse OpenJ9</strong> project.
</p>
<p>This repository is a git mirror of OpenJDK without the HotSpot JVM, but with an <strong>openj9</strong> branch that contains a few necessary patches. Run the following command:
</p>
<!-- set version -->
<pre><code>git clone https://github.com/ibmruntimes/openj9-openjdk-jdk8</code></pre>
<p>Cloning this repository can take a while because OpenJDK is a large project! When the process is complete, change directory into the cloned repository:
</p>
<!-- set version -->
<pre><code>cd openj9-openjdk-jdk8</code></pre>
<p>Now fetch additional sources from the <strong>Eclipse OpenJ9</strong> project and its clone of <strong>Eclipse OMR</strong>:
</p>
<pre><code>bash ./get_source.sh</code></pre>
</div>
</div>
<!-- set version -->
<div class="f-section-item" id="version-8:config">
<div class="f-content-container">
<h3>Configure</h3>
<p>When you have all the source files that you need, run the configure script, which detects how to build in the current build environment. You must specify one extra jar file, which has already been installed into the Docker container.
</p>
<pre><code>bash ./configure --with-freemarker-jar=/root/freemarker.jar</code></pre>
<p>Note that you must give an absolute path to <code>freemarker.jar</code>
</p>
</div>
</div>
<!-- set version -->
<div class="f-section-item" id="version-8:build9">
<div class="f-content-container">
<h3>Build</h3>
<p>Now you're ready to build OpenJDK with OpenJ9:
</p>
<pre><code>make all</code></pre>
<p>Two Java™ builds are produced: a full developer kit (<code>jdk</code>) and a runtime environment (<code>jre</code>):
</p>
<!-- set version x2 -->
<ul>
<li><code>build/<platform>/images/j2sdk-image</code></li>
<li><code>build/<platform>/images/j2re-image</code></li>
</ul>
<p>where <code><platform></code> reflects the Dockerfile you chose.
</p>
<p>For example, the <strong>Linux 64-bit (x86-64)</strong> Dockerfile directory is: <code>linux-x86_64-normal-server-release</code>
</p>
</div>
</div>
<!-- set version -->
<div class="f-section-item" id="version-8:test">
<div class="f-content-container">
<h3>Test</h3>
<p>For a simple test, try running the <code>java -version</code> command.
</p>
<!-- set version -->
<pre><code>cd build/<platform>/images/j2re-image</code>
<code>./bin/java -version</code></pre>
<p>Here is a sample of the output from a Linux x-86 binary:
</p>
<!-- set version -->
<pre class="output">openjdk version "1.8.0-internal"
OpenJDK Runtime Environment (build 1.8.0-internal-admin_2017_10_31_10_46-b00)
Eclipse OpenJ9 VM (build 2.9, JRE 1.8.0 Linux amd64-64 Compressed References 20171031_000000 (JIT enabled, AOT enabled)
OpenJ9 - 68d6fdb
OMR - 7c3d3d7
OpenJDK - 27f5b8f based on jdk8u152-b03)
</pre>
<p>There are a large number of test cases that are run automatically as part of the Eclipse OpenJ9 build and test pipeline. The tests are triggered by pull requests and by successful OpenJ9 builds. You can see the latest results on the <a href="https://ci.eclipse.org/openj9/" target="_blank">Eclipse OpenJ9 Jenkins instance</a>.
</p>
<p>If you want to run any of these tests manually on your own machine, refer to the <a href="https://github.com/eclipse/openj9/blob/master/test/README.md" target="_blank">OpenJ9 test quick start guide</a>.
<br /><br /></p>
</div>
</div>
</section>
<!-- =========================================================================================== -->
<!-- CONTENT FOR VERSION 11 -->
<section id="version-11">
<div class="f-section-item">
<!-- set version -->
<span class="intro-text">Building OpenJDK™ 11 with OpenJ9 will be familiar to anyone who has already built OpenJDK.</span>
</div>
<div class="f-section-item">
<span class="intro-text1" style="margin:0 4rem;">We're going to use Docker to create a Docker container where you'll build a binary from source code and run some tests on it. Just follow these steps:</span>
</div>
<!-- set version x5 -->
<div class="f-section-item">
<ol class="toc">
<li><a href="#version-11:prepare">Prepare your system </a></li>
<li><a href="#version-11:get" >Get the source </a></li>
<li><a href="#version-11:config" >Configure your build </a></li>
<li><a href="#version-11:build9" >Build OpenJDK with OpenJ9 </a></li>
<li><a href="#version-11:test" >Test your binary </a></li>
</ol>
</div>
<!-- set version -->
<div class="f-section-item" id="version-11:prepare">
<div class="f-content-container">
<h3>Prepare your system</h3>
<p>
We'll start by building a Dockerfile.
</p>
<!-- set version x2 -->
<p style="font-size:.9rem; line-height:1.2rem"><i class="fa fa-pencil-square-o" aria-hidden="true" style="font-size:1rem;"></i> <strong>Note:</strong> The Dockerfile you'll use in these instructions creates the configuration that makes building OpenJDK with OpenJ9 very simple. If you don't want to use Docker or you want to build a binary for another platform, you'll need to reproduce the configuration for yourself. Read the <a href="https://github.com/eclipse/openj9/blob/master/doc/build-instructions/Build_Instructions_V11.md" target="-blank">full set of build instructions for JDK 11</a> to see what you'll need (including Apache FreeMarker™) and where to get it.
</p>
<p>If you don't already have Docker on your system, <a href="https://docs.docker.com/engine/installation/">download</a> and install it now.
</p>
<!-- set version -->
<p>Pick one of the following <strong>JDK v11</strong> Dockerfiles for the platform you want to work on:</p>
<!-- set version x3 -->
<ul>
<li><strong><a href="https://github.com/eclipse/openj9/blob/master/buildenv/docker/jdk11/x86_64/ubuntu16/Dockerfile" target="_blank">Linux 64-bit (x86_64)</a></strong></li>
<li><strong><a href="https://github.com/eclipse/openj9/blob/master/buildenv/docker/jdk11/ppc64le/ubuntu16/Dockerfile" target="_blank">Linux on Power systems 64-bit (ppc64)</a></strong></li>
<li><strong><a href="https://github.com/eclipse/openj9/blob/master/buildenv/docker/jdk11/s390x/ubuntu16/Dockerfile" target="_blank">Linux on z Systems 64-bit (390_64)</a></strong></li>
</ul>
<p>Save the Dockerfile to your current directory and specify these commands to build and run the Docker image:
</p>
<pre><code>docker build -t openj9 -f Dockerfile .</code>
<code>docker run -it openj9</code></pre>
<p>Depending on your <a href="https://docs.docker.com/engine/reference/commandline/cli/#description" target="_blank">Docker system configuration</a>, you might need to prefix these commands with <code>sudo</code>.
</p>
<p>Now that you have the Docker image running, you are ready to move to the next step.
</p>
</div>
</div>
<!-- set version -->
<div class="f-section-item" id="version-11:get">
<div class="f-content-container">
<h3>Get the source</h3>
<p>First you need to clone the <strong>Extensions for OpenJDK for Eclipse OpenJ9</strong> project.
</p>
<p>This repository is a git mirror of OpenJDK without the HotSpot JVM, but with an <strong>openj9</strong> branch that contains a few necessary patches. Run the following command:
</p>
<!-- set version -->
<pre><code>git clone https://github.com/ibmruntimes/openj9-openjdk-jdk11</code></pre>
<p>Cloning this repository can take a while because OpenJDK is a large project! When the process is complete, change directory into the cloned repository:
</p>
<!-- set version -->
<pre><code>cd openj9-openjdk-jdk11</code></pre>
<p>Now fetch additional sources from the <strong>Eclipse OpenJ9</strong> project and its clone of <strong>Eclipse OMR</strong>:
</p>
<pre><code>bash ./get_source.sh</code></pre>
</div>
</div>
<!-- set version -->
<div class="f-section-item" id="version-11:config">
<div class="f-content-container">
<h3>Configure</h3>
<p>When you have all the source files that you need, run the configure script, which detects how to build in the current build environment. You must specify one extra jar file, which has already been installed into the Docker container.
</p>
<pre><code>bash ./configure --with-freemarker-jar=/root/freemarker.jar</code></pre>
<p>Note that you must give an absolute path to <code>freemarker.jar</code>
</p>
</div>
</div>
<!-- set version -->
<div class="f-section-item" id="version-11:build9">
<div class="f-content-container">
<h3>Build</h3>
<p>Now you're ready to build OpenJDK with OpenJ9:
</p>
<pre><code>make all</code></pre>
<p>A full developer kit (<code>jdk</code>) is produced in the following directory: <code>build/<platform>/images/jdk</code>
</p>
<p>where <code><platform></code> reflects the Dockerfile you chose.
</p>
<p>For example, the <strong>Linux 64-bit (x86-64)</strong> Dockerfile directory is: <code>linux-x86_64-normal-server-release</code>
</p>
</div>
</div>
<!-- set version -->
<div class="f-section-item" id="version-11:test">
<div class="f-content-container">
<h3>Test</h3>
<p>For a simple test, try running the <code>java -version</code> command.
</p>
<!-- set version -->
<pre><code>cd build/<platform>/images/jdk</code>
<code>./bin/java -version</code></pre>
<p>Here is a sample of the output from a Linux x-86 binary:
</p>
<!-- set version -->
<pre class="output">openjdk version "11-internal" 2018-09-25
OpenJDK Runtime Environment (build 11-internal+0-adhoc..jdk11)
Eclipse OpenJ9 VM (build master-ee517c1, JRE 11 Linux amd64-64-Bit Compressed References 20180910_000000 (JIT enabled, AOT enabled)
OpenJ9 - ee517c1
OMR - f29d158
JCL - 98f2038 based on jdk-11+28)
</pre>
<p>There are a large number of test cases that are run automatically as part of the Eclipse OpenJ9 build and test pipeline. The tests are triggered by pull requests and by successful OpenJ9 builds. You can see the latest results on the <a href="https://ci.eclipse.org/openj9/" target="_blank">Eclipse OpenJ9 Jenkins instance</a>.
</p>
<p>If you want to run any of these tests manually on your own machine, refer to the <a href="https://github.com/eclipse/openj9/blob/master/test/README.md" target="_blank">OpenJ9 test quick start guide</a>.
<br /><br /></p>
</div>
</div>
</section>
<!-- =========================================================================================== -->
<!-- CONTENT FOR VERSION 12 -->
<!-- set version -->
<section id="version-12">
<div class="f-section-item">
<!-- set version -->
<span class="intro-text">Building OpenJDK™ 12 with OpenJ9 will be familiar to anyone who has already built OpenJDK.</span>
</div>
<div class="f-section-item">
<span class="intro-text1" style="margin:0 4rem;">We're going to use Docker to create a Docker container where you'll build a binary from source code and run some tests on it. Just follow these steps:</span>
</div>
<!-- set version x5 -->
<div class="f-section-item">
<ol class="toc">
<li><a href="#version-12:prepare">Prepare your system </a></li>
<li><a href="#version-12:get" >Get the source </a></li>
<li><a href="#version-12:config" >Configure your build </a></li>
<li><a href="#version-12:build9" >Build OpenJDK with OpenJ9 </a></li>
<li><a href="#version-12:test" >Test your binary </a></li>
</ol>
</div>
<!-- set version -->
<div class="f-section-item" id="version-12:prepare">
<div class="f-content-container">
<h3>Prepare your system</h3>
<p>
We'll start by building a Dockerfile.
</p>
<!-- set version x2 -->
<p style="font-size:.9rem; line-height:1.2rem"><i class="fa fa-pencil-square-o" aria-hidden="true" style="font-size:1rem;"></i> <strong>Note:</strong> The Dockerfile you'll use in these instructions creates the configuration that makes building OpenJDK with OpenJ9 very simple. If you don't want to use Docker or you want to build a binary for another platform, you'll need to reproduce the configuration for yourself. Read the <a href="https://github.com/eclipse/openj9/blob/master/doc/build-instructions/Build_Instructions_V12.md" target="-blank">full set of build instructions for JDK 12</a> to see what you'll need (including Apache FreeMarker™) and where to get it.
</p>
<p>If you don't already have Docker on your system, <a href="https://docs.docker.com/engine/installation/">download</a> and install it now.
</p>
<!-- set version -->
<p>Pick one of the following <strong>JDK v12</strong> Dockerfiles for the platform you want to work on:</p>
<!-- set version x3 -->
<ul>
<li><strong><a href="https://github.com/eclipse/openj9/blob/master/buildenv/docker/jdk12/x86_64/ubuntu16/Dockerfile" target="_blank">Linux 64-bit (x86_64)</a></strong></li>
<li><strong><a href="https://github.com/eclipse/openj9/blob/master/buildenv/docker/jdk12/ppc64le/ubuntu16/Dockerfile" target="_blank">Linux on Power systems 64-bit (ppc64)</a></strong></li>
<li><strong><a href="https://github.com/eclipse/openj9/blob/master/buildenv/docker/jdk12/s390x/ubuntu16/Dockerfile" target="_blank">Linux on z Systems 64-bit (390_64)</a></strong></li>
</ul>
<p>Save the Dockerfile to your current directory and specify these commands to build and run the Docker image:
</p>
<pre><code>docker build -t openj9 -f Dockerfile .</code>
<code>docker run -it openj9</code></pre>
<p>Depending on your <a href="https://docs.docker.com/engine/reference/commandline/cli/#description" target="_blank">Docker system configuration</a>, you might need to prefix these commands with <code>sudo</code>.
</p>
<p>Now that you have the Docker image running, you are ready to move to the next step.
</p>
</div>
</div>
<!-- set version -->
<div class="f-section-item" id="version-12:get">
<div class="f-content-container">
<h3>Get the source</h3>
<p>First you need to clone the <strong>Extensions for OpenJDK for Eclipse OpenJ9</strong> project.
</p>
<p>This repository is a git mirror of OpenJDK without the HotSpot JVM, but with an <strong>openj9</strong> branch that contains a few necessary patches. Run the following command:
</p>
<!-- set version -->
<pre><code>git clone https://github.com/ibmruntimes/openj9-openjdk-jdk12</code></pre>
<p>Cloning this repository can take a while because OpenJDK is a large project! When the process is complete, change directory into the cloned repository:
</p>
<!-- set version -->
<pre><code>cd openj9-openjdk-jdk12</code></pre>
<p>Now fetch additional sources from the <strong>Eclipse OpenJ9</strong> project and its clone of <strong>Eclipse OMR</strong>:
</p>
<pre><code>bash ./get_source.sh</code></pre>
</div>
</div>
<!-- set version -->
<div class="f-section-item" id="version-12:config">
<div class="f-content-container">
<h3>Configure</h3>
<p>When you have all the source files that you need, run the configure script, which detects how to build in the current build environment. You must specify one extra jar file, which has already been installed into the Docker container.
</p>
<pre><code>bash ./configure --with-freemarker-jar=/root/freemarker.jar</code></pre>
<p>Note that you must give an absolute path to <code>freemarker.jar</code>
</p>
</div>
</div>
<!-- set version -->
<div class="f-section-item" id="version-12:build9">
<div class="f-content-container">
<h3>Build</h3>
<p>Now you're ready to build OpenJDK with OpenJ9:
</p>
<pre><code>make all</code></pre>
<p>A full developer kit (<code>jdk</code>) is produced in the following directory: <code>build/<platform>/images/jdk</code>
</p>
<p>where <code><platform></code> reflects the Dockerfile you chose.
</p>
<p>For example, the <strong>Linux 64-bit (x86-64)</strong> Dockerfile directory is: <code>linux-x86_64-normal-server-release</code>
</p>
</div>
</div>
<!-- set version -->
<div class="f-section-item" id="version-12:test">
<div class="f-content-container">
<h3>Test</h3>
<p>For a simple test, try running the <code>java -version</code> command.
</p>
<!-- set version -->
<pre><code>cd build/<platform>/images/jdk</code>
<code>./bin/java -version</code></pre>
<p>Here is a sample of the output from a Linux x-86 binary:
</p>
<!-- set version -->
<pre class="output">openjdk version "12-internal" 2019-03-19
OpenJDK Runtime Environment (build 12-internal+0-adhoc..openj9-openjdk-jdk12)
Eclipse OpenJ9 VM (build tye-2e3d778, JRE 12 Linux amd64-64-Bit Compressed References 20190201_000000 (JIT enabled, AOT enabled)
OpenJ9 - 2e3d778
OMR - a5a028d
JCL - 9af014f based on jdk-12+29)
</pre>
<p>There are a large number of test cases that are run automatically as part of the Eclipse OpenJ9 build and test pipeline. The tests are triggered by pull requests and by successful OpenJ9 builds. You can see the latest results on the <a href="https://ci.eclipse.org/openj9/" target="_blank">Eclipse OpenJ9 Jenkins instance</a>.
</p>
<p>If you want to run any of these tests manually on your own machine, refer to the <a href="https://github.com/eclipse/openj9/blob/master/test/README.md" target="_blank">OpenJ9 test quick start guide</a>.
<br /><br /></p>
</div>
</div>
</section>
<!-- =========================================================================================== -->
</main>
<footer>
<div class="social-icon">
<a href="https://github.com/eclipse/openj9" target="_blank" title="Github">
<i class="fa fa-github" aria-hidden="true" style="font-size: 2.3rem;"></i>
</a>
</div>
<div class="social-icon">
<a href="https://openj9.slack.com/" target="_blank" title="Slack">
<i class="fa fa-slack" aria-hidden="true" style="font-size:2rem;"></i>
</a>
</div>
<div class="social-icon">
<a href="https://twitter.com/openj9/" target="_blank" title="Twitter">
<i class="fa fa-twitter" aria-hidden="true" style="font-size:2rem;"></i>
</a>
</div>
<div class="social-icon">
<a href="https://stackoverflow.com/search?q=%23OpenJ9" target="_blank" title="Stack Overflow">
<i class="fa fa-stack-overflow" aria-hidden="true" style="font-size: 2rem;"></i>
</a>
</div>
<p>OpenJ9 is an Eclipse Incubator project.</p>
<span class="no-wrap"><i class="fa fa-chevron-circle-right f_mini" aria-hidden="true"></i><a class="dark-link" href="http://www.eclipse.org">Eclipse Foundation website</a></span>
<span class="no-wrap"><i class="fa fa-chevron-circle-right f_mini" aria-hidden="true"></i><a class="dark-link" href="http://www.eclipse.org/legal/privacy.php">Privacy policy</a></span>
<span class="no-wrap"><i class="fa fa-chevron-circle-right f_mini" aria-hidden="true"></i><a class="dark-link" href="http://www.eclipse.org/legal/termsofuse.php">Website terms of use</a></span>
<span class="no-wrap"><i class="fa fa-chevron-circle-right f_mini" aria-hidden="true"></i><a class="dark-link" href="http://www.eclipse.org/legal/copyright.php">Copyright agent</a></span>
<span class="no-wrap"><i class="fa fa-chevron-circle-right f_mini" aria-hidden="true"></i><a class="dark-link" href="http://www.eclipse.org/legal">Legal</a></span>
</footer>
<script src="./js/app.js"></script>
</body>
</html>