Skip to content

Commit 0453946

Browse files
committed
Merge JDK9 and JDK10 build systems
1 parent 43b2856 commit 0453946

25 files changed

+94
-325
lines changed

README.md

Lines changed: 17 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -3,42 +3,35 @@ A custom build of OpenJDK 9 & 10 for EV3, a Lego Mindstorms programmable brick f
33

44
## Components
55
The output consists of these parts:
6-
* JRE running on the EV3 - `jre-ev3.zip`
7-
* Stripped down version -- a runtime image
8-
* JDK built for the EV3 - `jdk-ev3.zip`
9-
* Basically the full build
6+
* JRI running on the EV3 - `jri-ev3.zip`
7+
* Stripped down version of Java -- a Java Runtime Image
8+
* Intended for normal users.
9+
* Full JDK running on the EV3 - `jdk-ev3.zip`
10+
* Intended for Linux power users.
1011
* EV3 jmods
11-
* It can be used for creating custom JRE images.
12+
* They can be used for creating custom JRIs.
13+
* Intended for advanced users wanting to add additional OpenJDK modules.
1214

1315
## Building
1416

1517
0. Clone/download this repo to your computer.
1618
1. Install [Docker](https://docs.docker.com/engine/installation/) for your operating system.
17-
2. Adjust the JAVA_VERSION variable in `jdkX/config.sh` to match the current OpenJDK tip:
18-
* [OpenJDK 9 updates](http://hg.openjdk.java.net/jdk-updates/jdk9u/) repo
19-
* [OpenJDK 10 updates](http://hg.openjdk.java.net/jdk-updates/jdk10u/) repo
20-
3. Build the jdk cross-compilation environment:
21-
* For JDK9:
19+
2. Build the jdk cross-compilation environment:
2220
```sh
23-
sudo docker build -t ev3dev-lang-java:jdk9-stretch -f jdk9/Dockerfile.system build
24-
sudo docker build -t ev3dev-lang-java:jdk9-build -f jdk9/Dockerfile.scripts build
21+
sudo docker build -t ev3dev-lang-java:jdk-stretch -f system/Dockerfile system
22+
sudo docker build -t ev3dev-lang-java:jdk-build -f scripts/Dockerfile scripts
2523
```
26-
* For JDK10:
27-
```sh
28-
sudo docker build -t ev3dev-lang-java:jdk10-stretch -f jdk10/Dockerfile.system build
29-
sudo docker build -t ev3dev-lang-java:jdk10-build -f jdk10/Dockerfile.scripts build
30-
```
31-
4. Run the newly prepared container. You have to mount a host directory to the the `/build` directory in the container,
24+
3. Run the newly prepared container. You have to mount a host directory to the the `/build` directory in the container,
3225
otherwise the build would get discarded. The final build needs at least 6.5 GB of free space (in the build directory).
33-
* For JDK9:
3426
```
35-
sudo docker run --rm -it -v <path on host, where the sources should be stored>:/build ev3dev-lang-java:jdk9-build
27+
sudo docker run --rm -it -v <path on host, where the sources should be stored>:/build ev3dev-lang-java:jdk-build
3628
```
37-
* For JDK10:
29+
4. Select the OpenJDK version you want to cross-compile:
3830
```
39-
sudo docker run --rm -it -v <path on host, where the sources should be stored>:/build ev3dev-lang-java:jdk10-build
31+
export JDKVER=9
32+
export JDKVER=10
4033
```
41-
5. Let's fetch the OpenJDK sources:
34+
5. Now we can download the OpenJDK sources:
4235
```
4336
./fetch.sh
4437
```
@@ -50,7 +43,7 @@ sudo docker run --rm -it -v <path on host, where the sources should be stored>:/
5043
```
5144
./zip.sh
5245
```
53-
8. If the build was successful, JDK packages were created in `/build/jre-ev3.tar.gz`, `/build/jdk-ev3.tar.gz` and `/build/jmods.tar.gz`.
46+
8. If the build was successful, JDK packages were created in `/build/jri-ev3.tar.gz`, `/build/jdk-ev3.tar.gz` and `/build/jmods.tar.gz`.
5447
If you have mounted `/build`, you can access the files from the host.
5548

5649
## ~~JShell on the EV3~~

jdk10/config.sh

Lines changed: 0 additions & 9 deletions
This file was deleted.

jdk9/Dockerfile.scripts

Lines changed: 0 additions & 13 deletions
This file was deleted.

jdk9/Dockerfile.system

Lines changed: 0 additions & 59 deletions
This file was deleted.

jdk9/DumpPort.java

Lines changed: 0 additions & 19 deletions
This file was deleted.

jdk9/apt.sources.list.debian

Lines changed: 0 additions & 3 deletions
This file was deleted.

jdk9/build.sh

Lines changed: 0 additions & 46 deletions
This file was deleted.

jdk9/compiler.sudoers

Lines changed: 0 additions & 1 deletion
This file was deleted.

jdk9/config.sh

Lines changed: 0 additions & 9 deletions
This file was deleted.

jdk9/ev3dev-archive-keyring.gpg

-2.42 KB
Binary file not shown.

0 commit comments

Comments
 (0)