Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Patch zlib to fix compatibility with Xcode 14.3 #17987

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions third_party/zlib/gzguts.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@
* For conditions of distribution and use, see copyright notice in zlib.h
*/

#ifndef _WIN32
#include <unistd.h>
#endif

#ifdef _LARGEFILE64_SOURCE
# ifndef _LARGEFILE_SOURCE
# define _LARGEFILE_SOURCE 1
Expand Down
15 changes: 15 additions & 0 deletions third_party/zlib/zlib.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
diff --git a/third_party/zlib/gzguts.h b/third_party/zlib/gzguts.h
index 57faf37165..54f668fcb2 100644
--- a/third_party/zlib/gzguts.h
+++ b/third_party/zlib/gzguts.h
@@ -3,6 +3,10 @@
* For conditions of distribution and use, see copyright notice in zlib.h
*/

+#ifndef _WIN32
+ #include <unistd.h>
+#endif
+
#ifdef _LARGEFILE64_SOURCE
# ifndef _LARGEFILE_SOURCE
# define _LARGEFILE_SOURCE 1