nuclear@0: src = $(wildcard src/*.cpp) nuclear@0: obj = $(src:.cpp=.o) nuclear@0: dep = $(obj:.o=.d) nuclear@0: nuclear@0: name = miniassimp nuclear@0: so_major = 0 nuclear@0: so_minor = 1 nuclear@0: nuclear@0: liba = lib$(name).a nuclear@0: libso = lib$(name).so nuclear@0: ldname = lib$(name).so.$(so_major) nuclear@0: soname = lib$(name).so.$(so_major).$(so_minor) nuclear@0: nuclear@0: warn = -pedantic -Wall nuclear@0: dbg = -g nuclear@0: opt = -O0 nuclear@0: inc = -Iinclude nuclear@0: nuclear@0: CC=gcc nuclear@0: CXX=g++ nuclear@0: CFLAGS = $(warn) $(dbg) $(opt) $(def) $(inc) nuclear@0: CXXFLAGS = $(warn) $(dbg) $(opt) $(def) $(inc) nuclear@0: nuclear@0: shared = -shared -Wl,-soname,$(soname) nuclear@0: nuclear@0: .PHONY: all nuclear@0: all: $(libso) $(liba) nuclear@0: nuclear@0: $(liba): $(obj) nuclear@0: $(AR) rcs $@ $(obj) nuclear@0: nuclear@0: $(libso): $(obj) nuclear@0: $(CC) -o $@ $(shared) $(obj) $(LDFLAGS) nuclear@0: nuclear@0: -include $(dep) nuclear@0: nuclear@0: %.d: %.cpp nuclear@0: @echo depfile $@ nuclear@0: @$(CPP) $(CXXFLAGS) $< -MM -MT $(@:.d=.o) >$@ nuclear@0: nuclear@0: .PHONY: clean nuclear@0: clean: nuclear@0: rm -f $(obj) $(liba) $(libso)