mmtk-openjdk icon indicating copy to clipboard operation
mmtk-openjdk copied to clipboard

Attempt to link before libmmtk_openjdk.so is built

Open qinsoon opened this issue 1 year ago • 0 comments

See the discussion here: https://mmtk.zulipchat.com/#narrow/stream/262674-mmtk-openjdk/topic/Link.20before.20ready.3F/near/367539761

Basically we will see the error /usr/bin/ld: cannot find -lmmtk_openjdk: No such file or directory, if the build script attempts to link with libmmtk_openjdk.so before it is built. It happens if it takes long to build the Rust crate.

We also noticed this in our CI build:

gmake[2]: *** [make/Main.gmk:272: hotspot-server-libs] Error 2

ERROR: Build failed for target 'default (exploded-image)' in configuration 'linux-x86_64-normal-server-release' (exit code 2) 
Stopping sjavac server

=== Output from failing command(s) repeated here ===
* For target hotspot_variant-server_libjvm_gtest_objs_BUILD_GTEST_LIBJVM_link:
/usr/bin/ld: cannot find -lmmtk_openjdk: No such file or directory
collect2: error: ld returned 1 exit status
* For target hotspot_variant-server_libjvm_objs_BUILD_LIBJVM_link:
/usr/bin/ld: cannot find -lmmtk_openjdk: No such file or directory
collect2: error: ld returned 1 exit status

qinsoon avatar Aug 22 '23 06:08 qinsoon