[cogl/cogl-latest-win: 18/27] config.h.win32.in: Update for later Visual Studio versions
- From: Chun-wei Fan <fanchunwei src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [cogl/cogl-latest-win: 18/27] config.h.win32.in: Update for later Visual Studio versions
- Date: Mon, 18 Oct 2021 10:53:49 +0000 (UTC)
commit 9316f4935b4b6d3f14266f1bf181fad42d14b7f5
Author: Chun-wei Fan <fanchunwei src gnome org>
Date: Fri Oct 15 09:45:36 2021 +0800
config.h.win32.in: Update for later Visual Studio versions
Visual Studio 2013+ has inttypes.h, and clean up some of the predefined
entries. Also, we have strncasecmp() via using _strnicmp() on Visual
Studio.
config.h.win32.in | 39 +++++++++++++++++----------------------
1 file changed, 17 insertions(+), 22 deletions(-)
---
diff --git a/config.h.win32.in b/config.h.win32.in
index 9915845d..b40357cf 100644
--- a/config.h.win32.in
+++ b/config.h.win32.in
@@ -218,7 +218,7 @@
#define HAVE_INT64_AND_I64 1
/* Define to 1 if you have the <inttypes.h> header file. */
-#ifndef _MSC_VER
+#if !defined (_MSC_VER) || (_MSC_VER >= 1800)
#define HAVE_INTTYPES_H 1
#endif
@@ -307,7 +307,9 @@
/* #undef HAVE_SPLICE */
/* Whether _Static_assert can be used or not */
-/* #undef HAVE_STATIC_ASSERT */
+#if (__STDC_VERSION__ >= 201112L)
+#define HAVE_STATIC_ASSERT 1
+#endif
/* Define to 1 if you have the <stdint.h> header file. */
#if ((_MSC_VER >= 1600) || !defined(_MSC_VER))
@@ -323,9 +325,10 @@
/* Define to 1 if you have the `strcasecmp' function. */
#if defined(_MSC_VER)
#define strcasecmp _stricmp
-#endif /* _MSC_VER uses _stricmp, which is identical to strcasecmp */
+#define strncasecmp _strnicmp
+#endif /* _MSC_VER uses _stricmp/_strnicmp, which is identical to strcasecmp/strncasecmp */
-#if !defined(__DMC__)
+#ifndef __DMC__
#define HAVE_STRCASECMP 1
#endif /* _MSC_VER or __gcc__ */
@@ -341,10 +344,8 @@
#define HAVE_STRING_H 1
/* Define to 1 if you have the `strncasecmp' function. */
-#if !defined(_MSC_VER) && !defined(__DMC__)
+#ifndef __DMC__
#define HAVE_STRNCASECMP 1
-#else /* _MSC_VER or __DMC__ */
-/* #undef HAVE_STRNCASECMP */
#endif /* _MSC_VER or __DMC__ */
/* Define to 1 if you have the `strsignal' function. */
@@ -508,9 +509,7 @@
#define LT_OBJDIR ".libs"
/* Define to 1 if your C compiler doesn't accept -c and -o together. */
-#ifdef _MSC_VER
-#define NO_MINUS_C_MINUS_O 1
-#endif
+/* #undef NO_MINUS_C_MINUS_O */
/* Define to the address where bug reports for this package should be sent. */
#define PACKAGE_BUGREPORT ""
@@ -549,27 +548,23 @@
#define SIZEOF_LONG 4
/* The size of `long long', as computed by sizeof. */
-#ifndef _MSC_VER
#define SIZEOF_LONG_LONG 8
-#else /* _MSC_VER */
-#define SIZEOF_LONG_LONG 0
-#endif /* _MSC_VER */
/* The size of `short', as computed by sizeof. */
#define SIZEOF_SHORT 2
/* The size of `size_t', as computed by sizeof. */
-#define SIZEOF_SIZE_T 4
+#ifdef _WIN64
+# define SIZEOF_SIZE_T 8
+#else
+# define SIZEOF_SIZE_T 4
+#endif
/* The size of `void *', as computed by sizeof. */
-#ifdef _MSC_VER
-#if (defined(_M_X64) || defined(_M_AMD64))
-#define SIZEOF_VOID_P 8
-#elif (defined(_M_IX86))
-#define SIZEOF_VOID_P 4
-#endif
+#ifdef _WIN64
+# define SIZEOF_VOID_P 8
#else
-#define SIZEOF_VOID_P 4
+# define SIZEOF_VOID_P 4
#endif
/* The size of `__int64', as computed by sizeof. */
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]