jrt file system now has /package and /modules directories

Michael Hall mik3hall at gmail.com
Sun Nov 15 17:04:07 UTC 2015

Would it still be the case that the exploded build in the jdk directory is invalid to use?

I am having some difficulties on this again. As long as I had done this once I thought it would make sense to be most up to date by just continuing to build from source.
So I redid the command to get new source.
And tried building. At some point this told me my configuration was no longer valid and the best thing to do was something like
make reconfigure
I did that, got through the build but the ‘make install’ shows errors and the images directory ends up with only…
I did get a OS X application to boot with the ‘exploded’? build in the jdk directory but if I try listing files with the JRT filesystem to be sure I’m running a new release I get errors like…

ava.nio.file.FileSystemNotFoundException: /Users/mjh/HalfPipe/bundles/HalfPipe9/HalfPipe9.app/Contents/PlugIns/Java/Contents/Home/lib/modules/bootmodules.jimage
	at jdk.internal.jrtfs.JrtFileSystem.checkExists(JrtFileSystem.java:87)

Although I didn’t seem to have a build step fail on a compiler warning I did also try…
./configure --disable-warnings-as-errors

So what I am doing is basically…
[get updated source bash get_source.sh or whatever it is]
make clean
sudo make install

Sort of consistently getting…

Building target 'install' in configuration 'macosx-x86_64-normal-server-release'
Installing jdk image into /usr/local/jvm/openjdk-1.9.0-internal
and creating 0 links from /usr/local/bin into the jdk.
cp: /Users/mjh/jdk9/build/macosx-x86_64-normal-server-release/images/jdk/*: No such file or directory
make[3]: *** [install] Error 1
make[2]: *** [install] Error 2

I tried searching on ] Error as also suggested and don’t think I saw any for the last build besides the ones immediately above.

> On Jul 26, 2015, at 2:08 AM, Alan Bateman <Alan.Bateman at oracle.com> wrote:
> On 26/07/2015 01:29, Michael Hall wrote:
>>> On Jul 25, 2015, at 12:10 PM, Alan Bateman <Alan.Bateman at oracle.com> wrote:
>>> Just a heads-up that jdk9-b74 has a refresh of the jimage and jrt file system implementation.
>> Have mostly just been following along on this a little with the early access releases. I was a little curious on this though so I cloned and built current jdk9.
>> I have a simple jrt filesystem lister that I tried running getting…
>> ~/jdk9/build/macosx-x86_64-normal-server-release/jdk/bin/java -cp . JRTLister
>> java.nio.file.FileSystemNotFoundException: /Users/mjh/jdk9/build/macosx-x86_64-normal-server-release/jdk/lib/modules/bootmodules.jimage
>> 	at jdk.internal.jrtfs.JrtFileSystem.checkExists(JrtFileSystem.java:87)
>> 	at jdk.internal.jrtfs.JrtFileSystem.<init>(JrtFileSystem.java:102)
>> 	at jdk.internal.jrtfs.JrtFileSystemProvider$1.<init>(JrtFileSystemProvider.java:113)
>> 	at jdk.internal.jrtfs.JrtFileSystemProvider.getTheFileSystem(JrtFileSystemProvider.java:113)
>> 	at jdk.internal.jrtfs.JrtFileSystemProvider.getFileSystem(JrtFileSystemProvider.java:131)
>> 	at java.nio.file.FileSystems.getFileSystem(FileSystems.java:221)
>> 	at JRTLister.main(JRTLister.java:13)
>> Obviously finding JrtFileSystem but not modules/bootmodules.jimage?
> Replace jdk/bin/java with images/jdk/bin/java in your path above and I expect it should work.
> The jdk directory in the build output is the "exploded build". It's an intermediate step in the build before the JDK and JRE images are created. Many people working on the JDK use the exploded builds for quick edit-build-debug sessions and local testing but I don't think is used much beyond that.
> JDK-8066860 [1] is tracking an update to the jrt file system to support exploded builds. Sundar has an initial patch but it's not in JDK 9 yet.
> -Alan
> [1] https://bugs.openjdk.java.net/browse/JDK-8066860 <https://bugs.openjdk.java.net/browse/JDK-8066860>

Michael Hall

More information about the jigsaw-dev mailing list