From: Philippe Daouadi Date: Tue, 9 Jun 2015 07:52:49 +0000 (+0200) Subject: Add compatibility with old #defines X-Git-Tag: v3.1.900a~78^2 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=refs%2Fpull%2F558%2Fhead;p=thirdparty%2Flibarchive.git Add compatibility with old #defines --- diff --git a/libarchive/archive.h b/libarchive/archive.h index 98397a93e..540aeaca4 100644 --- a/libarchive/archive.h +++ b/libarchive/archive.h @@ -45,6 +45,14 @@ # include #endif +#if ARCHIVE_VERSION_NUMBER < 4000000 +// also defined in archive_entry.h, don't redefine +#if !defined(__LA_INT64_T) +#define __LA_INT64_T la_int64_t +#endif +#define __LA_SSIZE_T la_ssize_t +#endif + /* Get appropriate definitions of standard POSIX-style types. */ /* These should match the types used in 'struct stat' */ #if defined(_WIN32) && !defined(__CYGWIN__) && !defined(__WATCOMC__) diff --git a/libarchive/archive_entry.h b/libarchive/archive_entry.h index b42fad6d5..21a0f30fd 100644 --- a/libarchive/archive_entry.h +++ b/libarchive/archive_entry.h @@ -47,6 +47,13 @@ #include #endif +#if ARCHIVE_VERSION_NUMBER < 4000000 +// also defined in archive.h, don't redefine +#if !defined(__LA_INT64_T) +#define __LA_INT64_T la_int64_t +#endif +#endif + /* Get a suitable 64-bit integer type. */ #if defined(_WIN32) && !defined(__CYGWIN__) && !defined(__WATCOMC__) typedef __int64 la_int64_t;