diff options
Diffstat (limited to 'nuklear/demo/sdl_opengl3/Makefile')
-rw-r--r-- | nuklear/demo/sdl_opengl3/Makefile | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/nuklear/demo/sdl_opengl3/Makefile b/nuklear/demo/sdl_opengl3/Makefile new file mode 100644 index 0000000..4b8ccf4 --- /dev/null +++ b/nuklear/demo/sdl_opengl3/Makefile @@ -0,0 +1,25 @@ +# Install +BIN = demo + +# Flags +CFLAGS = -std=c99 -pedantic -O2 + +SRC = main.c +OBJ = $(SRC:.c=.o) + +ifeq ($(OS),Windows_NT) +BIN := $(BIN).exe +LIBS = -lmingw32 -lSDL2main -lSDL2 -lopengl32 -lm -lGLU32 -lGLEW32 +else + UNAME_S := $(shell uname -s) + ifeq ($(UNAME_S),Darwin) + LIBS = -lSDL2 -framework OpenGL -lm -lGLEW + else + LIBS = -lSDL2 -lGL -lm -lGLU -lGLEW + endif +endif + +$(BIN): + @mkdir -p bin + rm -f bin/$(BIN) $(OBJS) + $(CC) $(SRC) $(CFLAGS) -o bin/$(BIN) $(LIBS) |