Bundling JDK into program - legal issue and small JDK

I am making small side project which MUST bundle JDK an integral part of the program (program which is compiling and running another programs written in “main” program). With this comes the question - can I bundle Oracle or any other JDK with application?

Second question - bundled JDK should be feature-complete, but as small as possible, possibly <40 mb. Is this possible to achieve?

when you bundle the oracle JRE, you can do it, but aren’t allowed to change it in any way(remove unused packages). If you bundle OpenJDK you can do whatever you want.

I had similar question:

which would be void by using jigsaw but not sure how far that is

you may also use openjdk, works beautifully

Hi

You can use OpenJDK, I agree with Cero and Danny02. You can use any derivative too, there are stripped-down headless versions of OpenJDK available for example in Debian, some JogAmp contributors are already able to build an headless JRE from OpenJDK (Project Ji Gong).

OpenJDK ftw.

Am considering using a Windows build of it now, too.

Cas :slight_smile:

Everything works as it should, but it seems that OpenJDK is treated as suspicious, at least for Avast. ::slight_smile:

Just… ignore problems with virus checkers.

Cas :slight_smile: