Turn off nullability warnings for macOS SDK

This commit is contained in:
Andrew Murray 2024-02-23 23:50:36 +11:00
parent 583039608d
commit 24865e5832

View File

@ -569,6 +569,9 @@ class pil_build_ext(build_ext):
if sdk_path: if sdk_path:
_add_directory(library_dirs, os.path.join(sdk_path, "usr", "lib")) _add_directory(library_dirs, os.path.join(sdk_path, "usr", "lib"))
_add_directory(include_dirs, os.path.join(sdk_path, "usr", "include")) _add_directory(include_dirs, os.path.join(sdk_path, "usr", "include"))
for extension in self.extensions:
extension.extra_compile_args = ["-Wno-nullability-completeness"]
elif ( elif (
sys.platform.startswith("linux") sys.platform.startswith("linux")
or sys.platform.startswith("gnu") or sys.platform.startswith("gnu")