JDK-8331541 : [i386] linking with libjvm.so fails after JDK-8283326
  • Type: Bug
  • Component: hotspot
  • Sub-Component: runtime
  • Priority: P4
  • Status: Resolved
  • Resolution: Fixed
  • OS: linux
  • CPU: x86
  • Submitted: 2024-05-02
  • Updated: 2024-05-13
  • Resolved: 2024-05-08
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 23
23 b22Fixed
Related Reports
Relates :  
Relates :  
Description
This bug was detected when building openjdk-22 in debian unstable[1]

Building the following example
---
#include <jni.h>

int main(){
    JavaVM *jvm;
    JNIEnv *env;
    JavaVMInitArgs vm_args;
    vm_args.version = JNI_VERSION_1_8;
    vm_args.nOptions = 0;
    vm_args.ignoreUnrecognized = false;
    JNI_CreateJavaVM(&jvm, (void**)&env, &vm_args);
}
---

fails with the following error:

11864s /usr/bin/ld: /usr/lib/jvm/java-22-openjdk-i386/lib/server/libjvm.so: undefined reference to `_SafeFetch32_impl'

The symbol is undefined in master:
$ readelf --symbols /usr/lib/jvm/java-23-openjdk-i386/lib/server/libjvm.so | grep SafeFetch
    17: 00000000     0 FUNC    GLOBAL DEFAULT  UND _SafeFetch32_impl

[1] https://ci.debian.net/data/autopkgtest/testing/i386/o/openjdk-22/46078740/log.gz
Comments
Changeset: 2d622152 Author: Vladimir Petko <vpetko@openjdk.org> Committer: Magnus Ihse Bursie <ihse@openjdk.org> Date: 2024-05-08 22:36:25 +0000 URL: https://git.openjdk.org/jdk/commit/2d622152b07bba0aba8fd5b1e24293e28d6e69f5
08-05-2024

A pull request was submitted for review. URL: https://git.openjdk.org/jdk/pull/19048 Date: 2024-05-02 08:23:38 +0000
06-05-2024