diff options
author | zhang <[email protected]> | 2007-06-28 08:10:09 -0600 |
---|---|---|
committer | Brian <[email protected]> | 2007-06-28 08:10:09 -0600 |
commit | 52e25f63d401506bcca8ac7f524974bbde68f5fd (patch) | |
tree | 79603b49ac49d5334a3cddd7d8774114e751b81f /include | |
parent | f3fb67972bbbf87f5aaaf029df6070fbaee3b594 (diff) |
a variety of fixes for MingW
Diffstat (limited to 'include')
-rw-r--r-- | include/GL/glu.h | 13 | ||||
-rw-r--r-- | include/GL/glut.h | 8 |
2 files changed, 18 insertions, 3 deletions
diff --git a/include/GL/glu.h b/include/GL/glu.h index c0bac75a8cc..d82103d141a 100644 --- a/include/GL/glu.h +++ b/include/GL/glu.h @@ -44,6 +44,19 @@ #define GLAPIENTRYP GLAPIENTRY * #endif +#ifdef GLAPI +#undef GLAPI +#endif + +# if (defined(_MSC_VER) || defined(__MINGW32__)) && defined(BUILD_GLU32) +# define GLAPI __declspec(dllexport) +# elif (defined(_MSC_VER) || defined(__MINGW32__)) && defined(_DLL) /* tag specifying we're building for DLL runtime support */ +# define GLAPI __declspec(dllimport) +# else /* for use with static link lib build of Win32 edition only */ +# define GLAPI extern +# endif /* _STATIC_MESA support */ + + #ifndef GLAPI #define GLAPI #endif diff --git a/include/GL/glut.h b/include/GL/glut.h index 23c740ee117..e0fad6e5cb0 100644 --- a/include/GL/glut.h +++ b/include/GL/glut.h @@ -115,7 +115,7 @@ extern _CRTIMP void __cdecl exit(int); #endif /* GLUT API entry point declarations for Win32. */ -#if defined(GLUT_BUILDING_LIB) && defined(_DLL) +#if (defined(BUILD_GLUT32) || defined(GLUT_BUILDING_LIB)) && defined(_DLL) # define GLUTAPI __declspec(dllexport) #elif defined(_DLL) # define GLUTAPI __declspec(dllimport) @@ -131,8 +131,10 @@ extern _CRTIMP void __cdecl exit(int); # endif # define CALLBACK __stdcall typedef int (GLUTAPIENTRY *PROC)(); -typedef void *HGLRC; -typedef void *HDC; +#if !defined(__MINGW32__) + typedef void *HGLRC; + typedef void *HDC; +#endif typedef unsigned long COLORREF; #endif |