Makefile: all objects .o depend on generated headers (to avoid tracking

all dependencies before compiling)
This commit is contained in:
Émilie Feral
2018-01-03 16:12:14 +01:00
committed by EmilieNumworks
parent 6c070b63fc
commit 66e375a308
2 changed files with 3 additions and 2 deletions

View File

@@ -85,6 +85,8 @@ dependencies = $(all_objs:.o=.d)
-include $(dependencies)
products += $(dependencies)
$(all_objs): $(generated_headers)
.SECONDARY: $(objs)
%.$(EXE): $(objs)
@echo "LD $@"

View File

@@ -25,8 +25,7 @@ FREETYPE_PATH := /usr/local/Cellar/freetype/2.6.3
# built w/o PNG support and simply won't output an image of the rasterization
#LIBPNG_PATH := /usr/local/Cellar/libpng/1.6.21
kandinsky/src/text.cpp: kandinsky/src/small_font.h kandinsky/src/large_font.h
kandinsky/src/context_text.cpp: kandinsky/src/small_font.h kandinsky/src/large_font.h
generated_headers += $(addprefix kandinsky/src/, small_font.h large_font.h)
small_font_files = $(addprefix kandinsky/src/, small_font.h small_font.c)
large_font_files = $(addprefix kandinsky/src/, large_font.h large_font.c)