summaryrefslogtreecommitdiffstats
path: root/Utilities/cmlibarchive/libarchive/archive_platform.h
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2020-06-01 19:45:43 (GMT)
committerBrad King <brad.king@kitware.com>2020-06-01 19:59:10 (GMT)
commit22c5b0c244f90696c97f05647c43775e0847d98f (patch)
tree1064cb436f94177eb02346f8d1f62f0de21bb1df /Utilities/cmlibarchive/libarchive/archive_platform.h
parenta7e66cac164c0bc6db01a5772d63f07b28d7e698 (diff)
downloadCMake-22c5b0c244f90696c97f05647c43775e0847d98f.zip
CMake-22c5b0c244f90696c97f05647c43775e0847d98f.tar.gz
CMake-22c5b0c244f90696c97f05647c43775e0847d98f.tar.bz2
libarchive: Avoid configure-time checks for integer range constants
Diffstat (limited to 'Utilities/cmlibarchive/libarchive/archive_platform.h')
-rw-r--r--Utilities/cmlibarchive/libarchive/archive_platform.h42
1 files changed, 15 insertions, 27 deletions
diff --git a/Utilities/cmlibarchive/libarchive/archive_platform.h b/Utilities/cmlibarchive/libarchive/archive_platform.h
index 90db31f..3273930 100644
--- a/Utilities/cmlibarchive/libarchive/archive_platform.h
+++ b/Utilities/cmlibarchive/libarchive/archive_platform.h
@@ -107,56 +107,44 @@
/* Borland warns about its own constants! */
#if defined(__BORLANDC__)
-# if HAVE_DECL_UINT64_MAX
-# undef UINT64_MAX
-# undef HAVE_DECL_UINT64_MAX
-# endif
-# if HAVE_DECL_UINT64_MIN
-# undef UINT64_MIN
-# undef HAVE_DECL_UINT64_MIN
-# endif
-# if HAVE_DECL_INT64_MAX
-# undef INT64_MAX
-# undef HAVE_DECL_INT64_MAX
-# endif
-# if HAVE_DECL_INT64_MIN
-# undef INT64_MIN
-# undef HAVE_DECL_INT64_MIN
-# endif
+# undef UINT64_MAX
+# undef UINT64_MIN
+# undef INT64_MAX
+# undef INT64_MIN
#endif
/* Some platforms lack the standard *_MAX definitions. */
-#if !HAVE_DECL_SIZE_MAX
+#ifndef SIZE_MAX
#define SIZE_MAX (~(size_t)0)
#endif
-#if !HAVE_DECL_SSIZE_MAX
+#ifndef SSIZE_MAX
#define SSIZE_MAX ((ssize_t)(SIZE_MAX >> 1))
#endif
-#if !HAVE_DECL_UINT32_MAX
+#ifndef UINT32_MAX
#define UINT32_MAX (~(uint32_t)0)
#endif
-#if !HAVE_DECL_INT32_MAX
+#ifndef INT32_MAX
#define INT32_MAX ((int32_t)(UINT32_MAX >> 1))
#endif
-#if !HAVE_DECL_INT32_MIN
+#ifndef INT32_MIN
#define INT32_MIN ((int32_t)(~INT32_MAX))
#endif
-#if !HAVE_DECL_UINT64_MAX
+#ifndef UINT64_MAX
#define UINT64_MAX (~(uint64_t)0)
#endif
-#if !HAVE_DECL_INT64_MAX
+#ifndef INT64_MAX
#define INT64_MAX ((int64_t)(UINT64_MAX >> 1))
#endif
-#if !HAVE_DECL_INT64_MIN
+#ifndef INT64_MIN
#define INT64_MIN ((int64_t)(~INT64_MAX))
#endif
-#if !HAVE_DECL_UINTMAX_MAX
+#ifndef UINTMAX_MAX
#define UINTMAX_MAX (~(uintmax_t)0)
#endif
-#if !HAVE_DECL_INTMAX_MAX
+#ifndef INTMAX_MAX
#define INTMAX_MAX ((intmax_t)(UINTMAX_MAX >> 1))
#endif
-#if !HAVE_DECL_INTMAX_MIN
+#ifndef INTMAX_MIN
#define INTMAX_MIN ((intmax_t)(~INTMAX_MAX))
#endif