From 4017e4a96a41ce2e781bcd99695c7f9dfc503c5f Mon Sep 17 00:00:00 2001 From: Chris Robinson Date: Thu, 20 Jun 2013 17:17:17 -0700 Subject: Check for MinGW in CMakeLists.txt instead of config.h --- CMakeLists.txt | 6 +++++- config.h.in | 3 --- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 4efd396c..13f8e0a2 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -206,7 +206,11 @@ ENDIF() # Set visibility/export options if available IF(WIN32) SET(EXPORT_DECL "__declspec(dllexport)") - SET(ALIGN_DECL "__declspec(align(x))") + IF(NOT MINGW) + SET(ALIGN_DECL "__declspec(align(x))") + ELSE() + SET(ALIGN_DECL "__declspec(aligned(x))") + ENDIF() OPTION(WINE "Enable use of Wine headers when compiling" OFF) IF(WINE) diff --git a/config.h.in b/config.h.in index 9fee8bd5..81d5e1f4 100644 --- a/config.h.in +++ b/config.h.in @@ -13,9 +13,6 @@ /* Define any available alignment declaration */ #define ALIGN(x) ${ALIGN_DECL} -#ifdef __MINGW32__ -#define align(x) aligned(x) -#endif /* Define if we have the C11 aligned_alloc function */ #cmakedefine HAVE_ALIGNED_ALLOC -- cgit v1.2.3