RFR: 8286582: Build fails on macos aarch64 when using --with-zlib=bundled
Alan Bateman
alanb at openjdk.java.net
Wed May 11 12:54:03 UTC 2022
On Wed, 11 May 2022 12:47:08 GMT, Jaikiran Pai <jpai at openjdk.org> wrote:
>> src/java.base/share/native/libzip/zlib/gzwrite.c line 452:
>>
>>> 450: len = strlen(next);
>>> 451: # else
>>> 452: # ifdef __APPLE__ // ignore format-nonliteral warning on macOS
>>
>> Instead of patching 3rd party code to fix a compilation warning, you should disable that warning instead.
>>
>> In `make/modules/java.base/lib/CoreLibraries.gmk`, add
>>
>> DISABLED_WARNINGS_clang := format-nonliteral, \
>>
>> as line 138.
>
> Thank you for these useful inputs Magnus. I did these changes locally but for some reason this format-nonliteral is not getting picked up while building that library. I will investigate and see what's going on. Will update the PR once I figure it out.
I agree with Magnus and try to avoid changing the imported zlib code.
-------------
PR: https://git.openjdk.java.net/jdk/pull/8651
More information about the core-libs-dev
mailing list