#ifndef WIN32_NO_ABSOLUTE_INST_DIRS
#define WIN32_NO_ABSOLUTE_INST_DIRS 1
#endif
#include "i386/cygwin.h"
#define TARGET_EXECUTABLE_SUFFIX ".exe"
#define EXTRA_OS_CPP_BUILTINS() \
do \
{ \
builtin_define ("__MSVCRT__"); \
builtin_define ("__MINGW32__"); \
} \
while (0)
#undef TARGET_OS_CPP_BUILTINS
#define TARGET_OS_CPP_BUILTINS() \
do \
{ \
builtin_define ("_WIN32"); \
builtin_define_std ("WIN32"); \
builtin_define_std ("WINNT"); \
builtin_define ("_X86_=1"); \
builtin_define ("__stdcall=__attribute__((__stdcall__))"); \
builtin_define ("__cdecl=__attribute__((__cdecl__))"); \
builtin_define ("__declspec(x)=__attribute__((x))"); \
if (!flag_iso) \
{ \
builtin_define ("_stdcall=__attribute__((__stdcall__))"); \
builtin_define ("_cdecl=__attribute__((__cdecl__))"); \
} \
EXTRA_OS_CPP_BUILTINS (); \
builtin_assert ("system=winnt"); \
} \
while (0)
#undef STANDARD_INCLUDE_DIR
#define STANDARD_INCLUDE_DIR "/usr/local/mingw32/include"
#undef STANDARD_INCLUDE_COMPONENT
#define STANDARD_INCLUDE_COMPONENT "MINGW"
#undef CPP_SPEC
#define CPP_SPEC "%{posix:-D_POSIX_SOURCE} %{mthreads:-D_MT}"
#undef LIB_SPEC
#define LIB_SPEC "%{pg:-lgmon} %{mwindows:-lgdi32 -lcomdlg32} \
-luser32 -lkernel32 -ladvapi32 -lshell32"
#undef LINK_SPEC
#define LINK_SPEC "%{mwindows:--subsystem windows} \
%{mconsole:--subsystem console} \
%{shared: %{mdll: %eshared and mdll are not compatible}} \
%{shared: --shared} %{mdll:--dll} \
%{static:-Bstatic} %{!static:-Bdynamic} \
%{shared|mdll: -e _DllMainCRTStartup@12}"
#undef LIBGCC_SPEC
#define LIBGCC_SPEC \
"%{mthreads:-lmingwthrd} -lmingw32 -lgcc -lmoldname -lmsvcrt"
#undef STARTFILE_SPEC
#define STARTFILE_SPEC "%{shared|mdll:dllcrt2%O%s} \
%{!shared:%{!mdll:crt2%O%s}} %{pg:gcrt2%O%s}"
#undef MATH_LIBRARY
#define MATH_LIBRARY ""
#undef OUTPUT_QUOTED_STRING
#define OUTPUT_QUOTED_STRING(FILE, STRING) \
do { \
char c; \
\
putc ('\"', asm_file); \
\
while ((c = *string++) != 0) \
{ \
if (c == '\\') \
c = '/'; \
\
if (ISPRINT (c)) \
{ \
if (c == '\"') \
putc ('\\', asm_file); \
putc (c, asm_file); \
} \
else \
fprintf (asm_file, "\\%03o", (unsigned char) c); \
} \
\
putc ('\"', asm_file); \
} while (0)
#undef WINT_TYPE
#define WINT_TYPE "short unsigned int"