summaryrefslogtreecommitdiff
path: root/archivers/libarchive/files/tar/bsdtar_windows.h
diff options
context:
space:
mode:
Diffstat (limited to 'archivers/libarchive/files/tar/bsdtar_windows.h')
-rw-r--r--archivers/libarchive/files/tar/bsdtar_windows.h24
1 files changed, 15 insertions, 9 deletions
diff --git a/archivers/libarchive/files/tar/bsdtar_windows.h b/archivers/libarchive/files/tar/bsdtar_windows.h
index 092ea6959d8..308ad1107be 100644
--- a/archivers/libarchive/files/tar/bsdtar_windows.h
+++ b/archivers/libarchive/files/tar/bsdtar_windows.h
@@ -26,35 +26,41 @@
*/
#ifndef BSDTAR_WINDOWS_H
-#define BSDTAR_WINDOWS_H 1
+#define BSDTAR_WINDOWS_H 1
#include <direct.h>
#include <windows.h>
+#include <io.h>
+#include <fcntl.h>
#ifndef PRId64
-#define PRId64 "I64"
+#define PRId64 "I64"
#endif
-#define geteuid() 0
+#define geteuid() 0
+
+#ifndef __WATCOMC__
#ifndef S_IFIFO
-#define S_IFIFO 0010000 /* pipe */
+#define S_IFIFO 0010000 /* pipe */
#endif
#include <string.h> /* Must include before redefining 'strdup' */
#if !defined(__BORLANDC__)
-#define strdup _strdup
+#define strdup _strdup
#endif
#if !defined(__BORLANDC__)
-#define getcwd _getcwd
+#define getcwd _getcwd
#endif
-#define chdir __tar_chdir
+#define chdir __tar_chdir
int __tar_chdir(const char *);
#ifndef S_ISREG
-#define S_ISREG(a) (a & _S_IFREG)
+#define S_ISREG(a) (a & _S_IFREG)
#endif
#ifndef S_ISBLK
-#define S_ISBLK(a) (0)
+#define S_ISBLK(a) (0)
+#endif
+
#endif
#endif /* BSDTAR_WINDOWS_H */