Skip to content

Commit

Permalink
star.cpp, winsys.cpp: Correct gl.h include sequence on Windows
Browse files Browse the repository at this point in the history
  • Loading branch information
stephengtuggy committed Apr 30, 2024
1 parent 013b5c2 commit 9c21d7d
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 3 deletions.
10 changes: 8 additions & 2 deletions engine/src/gfx/star.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,15 @@
#include "vs_logging.h"

#if defined(__APPLE__) && defined(__MACH__)
#include <OpenGL/gl.h>
# include <OpenGL/gl.h>
#elif defined (_WIN32) || defined (__CYGWIN__)
# ifndef NOMINMAX
# define NOMINMAX
# endif //tells VCC not to generate min/max macros
# include <windows.h>
# include <GL/gl.h>
#else
#include <GL/gl.h>
# include <GL/gl.h>
#endif

#define SINX 1
Expand Down
9 changes: 8 additions & 1 deletion engine/src/gldrv/winsys.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,15 @@
*/

#include <SDL2/SDL.h>
#if defined (__APPLE__) && defined (__MACH__)

#if defined(__APPLE__) && defined(__MACH__)
# include <OpenGL/gl.h>
#elif defined (_WIN32) || defined (__CYGWIN__)
# ifndef NOMINMAX
# define NOMINMAX
# endif //tells VCC not to generate min/max macros
# include <windows.h>
# include <GL/gl.h>
#else
# include <GL/gl.h>
#endif
Expand Down

0 comments on commit 9c21d7d

Please sign in to comment.