You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@harmony.apache.org by Andrey Chernyshev <a....@gmail.com> on 2006/09/13 12:45:26 UTC

[classlib] missing underscores in native dll exports?

I've noticed that the vast majority of the exported function names in
the classlib native libraries do not have underscores. For example,
for luni.dll the export table looks like:
dumpbin /EXPORTS hyluni.dll
...
  233   E6 0000C230 Java_org_apache_harmony_math_util_BigInteger_subImpl

On the other hand, MS compiler adds underscores to function names if
they are declared as __stdcall (which is same as JNICALL) by default.
If compile a native library as written in the JNI tutorial, the
resulted dll would also contain the underscores, e.g. the exported
name would be like:
      1    0 00001000 _Java_Test_test@8

Are the underscores switched off intentionally in the classlib's build?
I've also noticed that the underscores are generated for DRLVM's
kernel classes (those natives are in vmcore.dll):
       543  222 00068660 _Java_java_lang_Class_getStackClasses@16

Any ideas which naming scheme is the correct one for Windows?

-- 
Andrey Chernyshev
Intel Middleware Products Division

---------------------------------------------------------------------
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: harmony-dev-unsubscribe@incubator.apache.org
For additional commands, e-mail: harmony-dev-help@incubator.apache.org