JLI_Launch has mangled name in jli.dll when building for win32
thomas.stuefe at gmail.com
Thu Jul 11 14:06:11 UTC 2019
This means that the function is using the __stdcall calling convention. I
do not know whether this is correct or not, but caller and callee have to
agree on the calling convention used, so the prototype for that function
used when compiling the caller code must have been declared with __stdcall
too for this to work.
This is a 32bit Windows specialty. No other platform, including 64 bit
Windows, has different calling conventions.
Hope that helps,
On Thu, Jul 11, 2019, 09:34 Robert Lichtenberger <
r.lichtenberger at synedra.com> wrote:
> I have tried to use the jpackage EA version in combination with the
> win32-build of Java 12 from AdoptOpenJDK.
> I was able to build the jpackage EA from the sandbox and built an image
> from the win32 Java 12 build, which then was successfully combined using
> jpackage's --runtime-image option. (BTW I was able to produce working
> packages for win64, mac and linux in that way).
> Now when I tried to start the win32 package I get an error message:
> Failed to locate JLI_Launch.
> I digged into the jpackage/launcher code and found out that
> runtime/bin/jli.dll is loaded and the function JLI_Launch is called.
> But the jli.dll in the win32-build of Java 12 from AdoptOpenJDK has a
> name mangled version of JLI_Launch in it (_JLI_Launch at 56) which is (I
> think) the reason that the JVM cannot be started.
> I've since tried to build Java 12 myself and the effect is reproducible.
> When I build for win64, the jli.dll is correct, when I build
> --with-target-bits=32 from the exact same sources the jli.dll has the
> mangled name.
> Other pre-built JDKs (e.g. Liberica JDK) have the same "problem".
> Any ideas/hints as to what could cause the problem would be most welcome
More information about the build-dev