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

Add unistd.h and make it configure script independent #1022

Open
wants to merge 2 commits into
base: develop
Choose a base branch
from

Conversation

arnabanimesh
Copy link

No description provided.

@Neustradamus
Copy link

@madler: Have you seen this PR?

Copy link

@guidomodarelli guidomodarelli left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add this change in gzlib.c

diff --git a/gzlib.c b/gzlib.c
index 55da46a..f1d85c3 100644
--- a/gzlib.c
+++ b/gzlib.c
@@ -4,6 +4,11 @@
  */
 
 #include "gzguts.h"
+#if defined( unix ) || defined( __unix ) || defined( __unix__ ) || \
+    (defined( __APPLE__ ) && defined( __MACH__ )) || \
+    HAVE_UNISTD_H
+#include <unistd.h>         /* lseek, read, write, close, chown, unlink, sleep, ftruncate, fsync */
+#endif
 
 #if defined(_WIN32) && !defined(__BORLANDC__)
 #  define LSEEK _lseeki64

@arnabanimesh
Copy link
Author

@guidomodarelli done

Copy link

@guidomodarelli guidomodarelli left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🟢

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants