Fix macro redefinition warning in macOS
Freetype's embedded zlib headers define a macro that conflicts with
a macro defined in the macOS SDK headers (-Wmacro-redefined).
This change adds a suppression for this warning in the freetype2 build
for macOS. This is towards rolling more recent clang versions.
(Example: https://github.com/flutter/engine/pull/52358)
Example of the warning:
../../flutter/buildtools/mac-x64/clang/bin/clang ... -c ../../flutter/third_party/freetype2/src/gzip/ftgzip.c -o obj/flutter/third_party/freetype2/src/gzip/libfreetype2.ftgzip.o
In file included from ../../flutter/third_party/freetype2/src/gzip/ftgzip.c:104:
In file included from ../../flutter/third_party/freetype2/src/gzip/zutil.c:8:
../../flutter/third_party/freetype2/src/gzip/zutil.h:165:11: error: 'OS_CODE' macro redefined [-Werror,-Wmacro-redefined]
165 | # define OS_CODE 19
| ^
../../flutter/third_party/freetype2/src/gzip/zutil.h:136:11: note: previous definition is here
136 | # define OS_CODE 7
| ^
1 error generated.
Change-Id: I1776cb58ff995577ec438daf11c4cfffd212e51d
Reviewed-on: https://flutter-review.googlesource.com/c/third_party/freetype2/+/57220
Commit-Queue: Jason Simmons <jsimmons@google.com>
Reviewed-by: Gray Mackall <mackall@google.com>
Commit-Queue: Christopher Fujino <fujino@google.com>
Reviewed-by: Jason Simmons <jsimmons@google.com>
1 file changed