Skip to content

Commit 760a41f

Browse files
committed
[scripts] upgrade to JDK 10 repo & runtime
1 parent 71bd638 commit 760a41f

File tree

5 files changed

+16
-16
lines changed

5 files changed

+16
-16
lines changed

README.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
1-
# openjdk-9-ev3
2-
A custom build of OpenJDK 9 for EV3, a Lego Mindstorms programmable brick featuring a ARM926EJ-S CPU.
1+
# OpenJDK 10 for EV3
2+
A custom build of OpenJDK 10 for EV3, a Lego Mindstorms programmable brick featuring a ARM926EJ-S CPU.
33

44
## Components
55
The output consists of these parts:
66
* JRE running on the EV3 - `jre-ev3.zip`
77
* Stripped down version -- a runtime image
88
* JDK built for the EV3 - `jdk-ev3.zip`
99
* Basically the full build
10-
* [Official OpenJDK linux-amd64](http://jdk.java.net/9/) with EV3 jmods
10+
* [Official OpenJDK linux-amd64](http://jdk.java.net/10/) with EV3 jmods
1111
* Only a stripped down version -- also a runtime image
1212
* It can be used for creating custom JRE images. For this, jlink and the ev3 jmods are included.
1313
* It has `javac` (jdk.compiler module).
@@ -42,8 +42,8 @@ JShell JDI agent on the remote side, which is handled by SSH as well.
4242

4343
0. Clone/download this repo to your computer.
4444
1. Install [Docker](https://docs.docker.com/engine/installation/) for your operating system.
45-
2. Adjust the JAVA_VERSION variable in `build/config.sh` to match the current OpenJDK tip: [OpenJDK 9 updates](http://hg.openjdk.java.net/jdk-updates/jdk9u/)
46-
3. Build the jdk9 cross-compilation environment:
45+
2. Adjust the JAVA_VERSION variable in `build/config.sh` to match the current OpenJDK tip: [OpenJDK 10 updates](http://hg.openjdk.java.net/jdk-updates/jdk10u/)
46+
3. Build the jdk cross-compilation environment:
4747
```sh
4848
sudo docker build -t ev3dev-lang-java:jdk-stretch -f build/Dockerfile.system build
4949
sudo docker build -t ev3dev-lang-java:jdk-build -f build/Dockerfile.scripts build
@@ -65,5 +65,5 @@ sudo docker run --rm -it -v <path on host, where the sources should be stored>:/
6565
```
6666
./zip.sh
6767
```
68-
8. If the build was successful, JDK9 packages were created in `/build/jre-ev3.zip`, `/build/jdk-ev3.zip` and `/build/jdk-pc.zip`.
68+
8. If the build was successful, JDK packages were created in `/build/jre-ev3.zip`, `/build/jdk-ev3.zip` and `/build/jdk-pc.zip`.
6969
If you have mounted `/build`, you can access the files from the host.

build/Dockerfile.system

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,9 +48,9 @@ RUN dpkg --add-architecture armel && \
4848
mercurial \
4949
zlib1g-dev
5050

51-
# download JDK 9
51+
# download JDK 10
5252
RUN mkdir /opt/jdkcross
53-
RUN curl -SL http://download.java.net/java/GA/jdk9/9.0.1/binaries/openjdk-9.0.1_linux-x64_bin.tar.gz | tar -xzC /opt/jdkcross
53+
RUN curl -SL https://download.java.net/java/GA/jdk10/10/binaries/openjdk-10_linux-x64_bin.tar.gz | tar -xzC /opt/jdkcross
5454

5555
# prepare a nonroot user
5656
COPY compiler.sudoers /etc/sudoers.d/compiler

build/build.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ bash ./common/autoconf/autogen.sh
2727
# BUILD_NM="gcc-nm"
2828

2929
# configure the build
30-
bash ./configure --with-boot-jdk="$SCRIPTDIR/jdk-9.0.1" \
30+
bash ./configure --with-boot-jdk="$SCRIPTDIR/jdk-10" \
3131
--openjdk-target=arm-linux-gnueabi \
3232
--with-abi-profile=arm-ev3 \
3333
--enable-headless-only \

build/config.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#!/bin/bash
22

3-
JAVA_VERSION="10+23"
4-
JAVA_REPO="http://hg.openjdk.java.net/jdk10/jdk10/"
3+
JAVA_VERSION="10+46"
4+
JAVA_REPO="http://hg.openjdk.java.net/jdk-updates/jdk10u/"
55
SCRIPTDIR="/opt/jdkcross"
66

77
BUILDDIR="/build"

build/zip.sh

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ rm -rf ./jshell-support
1414
rm -f ./jdk-ev3
1515

1616
# build ev3 runtime image
17-
"$SCRIPTDIR/jdk-9.0.1/bin/jlink" \
17+
"$SCRIPTDIR/jdk-10/bin/jlink" \
1818
--module-path ./jmods/ \
1919
--endian little \
2020
--compress 0 \
@@ -25,8 +25,8 @@ rm -f ./jdk-ev3
2525
--output ./jre-ev3
2626

2727
# build microjdk
28-
"$SCRIPTDIR/jdk-9.0.1/bin/jlink" \
29-
--module-path "$SCRIPTDIR/jdk-9.0.1/jmods" \
28+
"$SCRIPTDIR/jdk-10/bin/jlink" \
29+
--module-path "$SCRIPTDIR/jdk-10/jmods" \
3030
--compress 2 \
3131
--strip-debug \
3232
--no-header-files \
@@ -41,8 +41,8 @@ ln -s ./jdk ./jdk-ev3
4141

4242
# JShell hack
4343
mkdir jshell-support
44-
"$SCRIPTDIR/jdk-9.0.1/bin/javac" -d ./jshell-support "$SCRIPTDIR/jshellhack/DumpPort.java"
45-
"$SCRIPTDIR/jdk-9.0.1/bin/jar" cf ./jshellhack.jar -C ./jshell-support jshellhack/DumpPort.class
44+
"$SCRIPTDIR/jdk-10/bin/javac" -d ./jshell-support "$SCRIPTDIR/jshellhack/DumpPort.java"
45+
"$SCRIPTDIR/jdk-10/bin/jar" cf ./jshellhack.jar -C ./jshell-support jshellhack/DumpPort.class
4646
cp ./jshellhack.jar ./jdk-pc/bin
4747
cp "$SCRIPTDIR/jshell-launch.sh" ./jdk-pc/bin
4848

0 commit comments

Comments
 (0)