osx-bundle missing symlink

27 views
Skip to first unread message

Stian Soiland-Reyes

unread,
Jan 16, 2014, 4:30:41 AM1/16/14
to openjdk-unof...@googlegroups.com
The OpenJDK 7 update 40 build 43 x86_64 bundle does not work when used as a bundle plugin within an Application (e.g. added as MyApp.app/Content/PlugIns/jre.bundle)


The reason seems to be that 

stain@vmint /tmp/12/Contents/MacOS $ ls -al
total 68
drwxr-xr-x 2 stain stain  4096 Sep 19 07:14 .
drwxr-xr-x 4 stain stain  4096 Sep 19 07:14 ..
-rwxr-xr-x 1 stain stain 61432 Sep 19 07:14 libjli.dylib

When starting, libjli.dylib will complain about not finding libjava - because the relative paths are wrong.



Instead, this should be instead be a symlink as in the Oracle downloads:

stain@vmint /tmp/12/Contents/MacOS $ ls -al
total 8
drwxr-xr-x 2 stain stain 4096 Jan 16 09:25 .
drwxr-xr-x 4 stain stain 4096 Sep 19 07:14 ..
lrwxrwxrwx 1 stain stain   32 Jan 16 09:24 libjli.dylib -> ../Home/jre/lib/jli/libjli.dylib


When I add this change, the bundle works fine as a plugin.


Stian Soiland-Reyes

unread,
Jan 16, 2014, 4:44:21 AM1/16/14
to openjdk-unof...@googlegroups.com
Probably happened as part of making the zip.. I find you need to use zip --symlinks to preserve the symlinks.

Alex Kasko

unread,
Jan 16, 2014, 5:02:35 AM1/16/14
to Stian Soiland-Reyes, openjdk-unof...@googlegroups.com
Hi,

About symlink - I'll look at it closer. Bundle itself is built as part
of OpenJDK build process (not by my scripts) and I'm always trying to
use zip -qyr (y - for symlinks) on linux and mac.

And I'll fix the typos.

Thanks for the report.
--
Regards,
Alex Kasko

Alex Kasko

unread,
Jun 5, 2014, 3:41:11 PM6/5/14
to Stian Soiland-Reyes, openjdk-unof...@googlegroups.com
Hi,

The problem was in copying, cp -r behaviour differs on linux and macos.
Now using cp -a, symlink should be fixed in 7u60 builds.
-Alex

Reply all
Reply to author
Forward
0 new messages