This bug is to resolve the remaining miscellaneous symbol collisions
when statically linking JDK/VM natives with the standard Java launcher binary (see JDK-8303796 for more details). The symbols include:
- debug
- findFunction
- jvm (if it's desirable to statically linking with libawt_xawt, was not addressed inJDK-8305761)
E.g.
/usr/bin/ld: /.../build/linux-x86_64-server-slowdebug/images/static-libs/lib/libj2pkcs11.a(j2secmod_md.o): in function `findFunction':
/.../src/jdk.crypto.cryptoki/unix/native/libj2pkcs11/j2secmod_md.c:37: multiple definition of `findFunction'; /.../build/linux-x86_64-server-slowdebug/images/static-libs/lib/libj2pcsc.a(pcsc_md.o):/.../src/java.smartcardio/unix/native/libj2pcsc/pcsc_md.c:78: first defined here
/usr/bin/ld: /.../build/linux-x86_64-server-slowdebug/hotspot/variant-server/libjvm/objs/static/libjvm.a(debug.o): in function `debug':
/.../src/hotspot/share/utilities/debug.cpp:486: multiple definition of `debug'; /.../build/linux-x86_64-server-slowdebug/images/static-libs/lib/libj2pkcs11.a(p11_general.o):/.../src/jdk.crypto.cryptoki/share/native/libj2pkcs11/p11_general.c:78: first defined here
...
/usr/bin/ld: /.../build/linux-x86_64-server-slowdebug/images/static-libs/lib/libawt_xawt.a(XlibWrapper.o):/.../src/java.desktop/unix/native/libawt_xawt/xawt/XlibWrapper.c:1328: multiple definition of `jvm'; /.../build/linux-x86_64-server-slowdebug/images/static-libs/lib/libawt.a(awt_LoadLibrary.o):/.../src/java.desktop/unix/native/libawt/awt/awt_LoadLibrary.c:52: first defined here
collect2: error: ld returned 1 exit status
when statically linking JDK/VM natives with the standard Java launcher binary (see JDK-8303796 for more details). The symbols include:
- debug
- findFunction
- jvm (if it's desirable to statically linking with libawt_xawt, was not addressed in
E.g.
/usr/bin/ld: /.../build/linux-x86_64-server-slowdebug/images/static-libs/lib/libj2pkcs11.a(j2secmod_md.o): in function `findFunction':
/.../src/jdk.crypto.cryptoki/unix/native/libj2pkcs11/j2secmod_md.c:37: multiple definition of `findFunction'; /.../build/linux-x86_64-server-slowdebug/images/static-libs/lib/libj2pcsc.a(pcsc_md.o):/.../src/java.smartcardio/unix/native/libj2pcsc/pcsc_md.c:78: first defined here
/usr/bin/ld: /.../build/linux-x86_64-server-slowdebug/hotspot/variant-server/libjvm/objs/static/libjvm.a(debug.o): in function `debug':
/.../src/hotspot/share/utilities/debug.cpp:486: multiple definition of `debug'; /.../build/linux-x86_64-server-slowdebug/images/static-libs/lib/libj2pkcs11.a(p11_general.o):/.../src/jdk.crypto.cryptoki/share/native/libj2pkcs11/p11_general.c:78: first defined here
...
/usr/bin/ld: /.../build/linux-x86_64-server-slowdebug/images/static-libs/lib/libawt_xawt.a(XlibWrapper.o):/.../src/java.desktop/unix/native/libawt_xawt/xawt/XlibWrapper.c:1328: multiple definition of `jvm'; /.../build/linux-x86_64-server-slowdebug/images/static-libs/lib/libawt.a(awt_LoadLibrary.o):/.../src/java.desktop/unix/native/libawt/awt/awt_LoadLibrary.c:52: first defined here
collect2: error: ld returned 1 exit status
- relates to
-
JDK-8303796 Optionally build fully statically linked JDK image
-
- Open
-