diff --git a/src/native/external/zlib.cmake b/src/native/external/zlib.cmake index 6365a1ea5585ac..6bdec9ec45eb42 100644 --- a/src/native/external/zlib.cmake +++ b/src/native/external/zlib.cmake @@ -24,3 +24,8 @@ set(ZLIB_SOURCES_BASE ) addprefix(ZLIB_SOURCES "${CMAKE_CURRENT_LIST_DIR}/zlib" "${ZLIB_SOURCES_BASE}") + +if (CMAKE_C_COMPILER_ID MATCHES "Clang") + # Turn off warn-as-error for strict prototype checking until https://github.com/madler/zlib/issues/633 is fixed upstream + set_source_files_properties(${ZLIB_SOURCES} PROPERTIES COMPILE_OPTIONS "-Wno-error=strict-prototypes") +endif()