RFR: 8346987: [lto] gtest build fails
Thomas Stuefe
stuefe at openjdk.org
Mon Feb 24 14:16:14 UTC 2025
On Fri, 24 Jan 2025 17:22:46 GMT, Magnus Ihse Bursie <ihse at openjdk.org> wrote:
>> When building with link time optimization (lto) , configure flag is --enable-jvm-feature-link-time-opt , we run in the gtest build into a lot of errors.
>> One workaround is just to configure without gtest ; this one changes the make to NOT use the lto build flags for gtest , just for the "normal" libjvm.so .
>
> Maybe we should heed @kimbarrett's advice and not push for the LTO stuff piecemeal like this. Personally, I rather think the best solution for now is to wait with this patch, and for you to continue configuring without gtest, than uglifying the code like this. I'll try to prioritize separating gtest and hotspot builds, and then it will be possible to fix this in a clean way.
@magicus about https://bugs.openjdk.org/browse/JDK-8296497, its a bit sparse on the details. What exactly is your plan, to build the gtest object files separately, but leave the linking stage as it is? Or build the gtest parts as an own launcher and link against the libjvm.so? The latter, I think, could be quite difficult since we expect to have access to all symbols in the gtest suite.
-------------
PR Comment: https://git.openjdk.org/jdk/pull/23173#issuecomment-2678536432
More information about the build-dev
mailing list