]> git.ipfire.org Git - thirdparty/libarchive.git/commitdiff
Various small fixes for Cygwin, Haiku, OpenIndiana (#2346)
authorvcoxvco <62189056+vcoxvco@users.noreply.github.com>
Mon, 14 Oct 2024 15:44:17 +0000 (17:44 +0200)
committerGitHub <noreply@github.com>
Mon, 14 Oct 2024 15:44:17 +0000 (08:44 -0700)
Cygwin 3.5.4 (same applies for 3.5.3),
I get a compile error as shown below after a simple ./configure and
make. Adding <windef.h> solves the problem.

Co-authored-by: vco <god@universe.sys>
libarchive/archive_platform.h
libarchive/archive_write_disk_posix.c
tar/bsdtar.c

index 24e8b50323d06fc1027b1895bb28c9b2963bcb04..f30df1104c83d94eae5b7dce260dd2ec6733b451 100644 (file)
 # endif
 #endif
 
+/* For cygwin, to avoid missing LONG, ULONG, PUCHAR, ... definitions */
+#ifdef __CYGWIN__
+#include <windef.h>
+#endif
+
 /* It should be possible to get rid of this by extending the feature-test
  * macros to cover Windows API functions, probably along with non-trivial
  * refactoring of code to find structures that sit more cleanly on top of
index d9619fe2d122366df02391d3c14267f1f113fb9d..d69ab34e8bb35abc598be07b27271a0b7519cd14 100644 (file)
@@ -3605,7 +3605,7 @@ set_time_tru64(int fd, int mode, const char *name,
        tstamp.atime.tv_sec = atime;
        tstamp.mtime.tv_sec = mtime;
        tstamp.ctime.tv_sec = ctime;
-#if defined (__hpux) && defined (__ia64)
+#if defined (__hpux) && ( defined (__ia64) || defined (__hppa) )
        tstamp.atime.tv_nsec = atime_nsec;
        tstamp.mtime.tv_nsec = mtime_nsec;
        tstamp.ctime.tv_nsec = ctime_nsec;
index 439093ded76a62a0d12eddfcb4d4f4458028d2dc..daa24ffe51e5c2ec57ee8a7764a3f3aa54123a72 100644 (file)
@@ -7,6 +7,9 @@
 
 #include "bsdtar_platform.h"
 
+#ifdef HAVE_LIMITS_H
+#include <limits.h>
+#endif
 #ifdef HAVE_SYS_PARAM_H
 #include <sys/param.h>
 #endif