From: Bernd Edlinger Date: Tue, 27 Jan 2015 17:20:27 +0000 (+0000) Subject: Fix build under cygwin/64. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=7e8338d861d338dcf608d9ba8fb4a0289e44820e;p=gcc.git Fix build under cygwin/64. 2015-01-27 Bernd Edlinger Fix build under cygwin/64. * adaint.h: Add check for __CYGWIN__. * mingw32.h: Prevent windows.h from including x86intrin.h in GCC. From-SVN: r220180 --- diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog index 6d50312902d..f5715461b7a 100644 --- a/gcc/ada/ChangeLog +++ b/gcc/ada/ChangeLog @@ -1,3 +1,9 @@ +2015-01-27 Bernd Edlinger + + Fix build under cygwin/64. + * adaint.h: Add check for __CYGWIN__. + * mingw32.h: Prevent windows.h from including x86intrin.h in GCC. + 2015-01-19 Bernd Edlinger PR ada/64640 diff --git a/gcc/ada/adaint.h b/gcc/ada/adaint.h index b0e66cc69b5..c53a8bf93bd 100644 --- a/gcc/ada/adaint.h +++ b/gcc/ada/adaint.h @@ -36,7 +36,7 @@ extern "C" { #include #include -#ifdef _WIN32 +#if defined (_WIN32) || defined (__CYGWIN__) #include "mingw32.h" #endif diff --git a/gcc/ada/mingw32.h b/gcc/ada/mingw32.h index 09343066dfc..77caec26425 100644 --- a/gcc/ada/mingw32.h +++ b/gcc/ada/mingw32.h @@ -52,6 +52,11 @@ #ifndef __CYGWIN__ #include #endif +#if defined (__CYGWIN__) && !defined (__CYGWIN32__) && !defined (IN_RTS) +/* Note: windows.h on cygwin-64 includes x86intrin.h which uses malloc. + That fails to compile, if malloc is poisoned, i.e. if !IN_RTS. */ +#define _X86INTRIN_H_INCLUDED +#endif #include #ifndef _O_U8TEXT