nuclear@0: src = $(wildcard src/*.cc) nuclear@0: obj = $(src:.cc=.o) nuclear@0: bin = cloth nuclear@0: nuclear@0: sys := $(shell uname -s | tr '[:upper:]' '[:lower:]' | sed 's/mingw.*/mingw/') nuclear@0: nuclear@0: CXXFLAGS = -pedantic -Wall -g nuclear@0: LDFLAGS = $(libgl_$(sys)) -lgmath nuclear@0: nuclear@0: libgl_linux = -lGL -lGLU -lglut -lGLEW nuclear@0: libgl_darwin = -framework OpenGL -framework GLUT -lGLEW nuclear@0: libgl_mingw = -lopengl32 -lglu32 -lglut32 -lglew32 nuclear@0: nuclear@0: $(bin): $(obj) nuclear@0: $(CXX) -o $@ $(obj) $(LDFLAGS) nuclear@0: nuclear@0: .PHONY: clean nuclear@0: clean: nuclear@0: rm -f $(obj) $(bin)