# Copyright (C) 2018 Tomasz Kramkowski # SPDX-License-Identifier: MIT -include config.mk PROG := faqe EPRINTF_PATH ?= ../eprintf LINMATH_PATH ?= ../linmath PKG_CONFIG ?= pkg-config LN ?= ln -sf LIBS := gl libpng sdl2 CFLAGS += $(shell $(PKG_CONFIG) --cflags $(LIBS)) -std=c11 -MMD -MP LDFLAGS += -Wl,--as-needed LDLIBS += $(shell $(PKG_CONFIG) --libs $(LIBS)) -lm OBJ := faqe.o camera.o ensize.o eprintf.o fmd.o gl.o glprog.o ieee754.o model.o mtl.o tex.o all: $(PROG) include $(EPRINTF_PATH)/module.mk include $(LINMATH_PATH)/module.mk $(PROG): $(OBJ) test_ieee754: ieee754.o deplinks: $(EPRINTF_FILES) $(LINMATH_FILES) DEP := $(OBJ:.o=.d) clean: $(RM) $(OBJ) $(DEP) $(PROG) $(CLEAN) -include $(DEP) .PHONY: all deplinks clean