cc8556533f
Can be used on: Linux, Mac OS X, Android, Emscripten
21 lines
344 B
Makefile
21 lines
344 B
Makefile
# Install
|
|
BIN = demo
|
|
|
|
# Flags
|
|
CFLAGS = -std=c99 -pedantic -O2
|
|
|
|
SRC = main.c
|
|
OBJ = $(SRC:.c=.o)
|
|
|
|
UNAME_S := $(shell uname -s)
|
|
ifeq ($(UNAME_S),Darwin)
|
|
LIBS = -lSDL2 -framework OpenGLES -lm -lGLEW
|
|
else
|
|
LIBS = -lSDL2 -lGLESv2 -lm -lGLU -lGLEW
|
|
endif
|
|
|
|
$(BIN):
|
|
@mkdir -p bin
|
|
rm -f bin/$(BIN) $(OBJS)
|
|
$(CC) $(SRC) $(CFLAGS) -o bin/$(BIN) $(LIBS)
|