File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 9191endif
9292# ---------------------------------------------------------------------------------
9393
94- export OFILES := $(addsuffix .o,$(BINFILES ) ) \
95- $(CPPFILES:.cpp=.o ) $(CFILES:.c=.o ) $(SFILES:.s=.o )
94+ export OFILES_BIN := $(addsuffix .o,$(BINFILES ) )
95+ export OFILES_SRC := $(CPPFILES:.cpp=.o ) $(CFILES:.c=.o ) $(SFILES:.s=.o )
96+
97+ export HFILES_BIN := $(addsuffix .h,$(subst .,_,$(BINFILES ) ) )
98+
99+ export OFILES := $(OFILES_BIN ) $(OFILES_SRC )
96100
97101export INCLUDE := $(foreach dir,$(INCLUDES ) ,-I$(CURDIR ) /$(dir ) ) \
98102 $(foreach dir,$(LIBDIRS ) ,-I$(dir ) /include) \
@@ -153,8 +157,10 @@ DEPENDS := $(OFILES:.o=.d)
153157# ---------------------------------------------------------------------------------
154158$(OUTPUT ) : $(OFILES )
155159
160+ $(OFILES_SRC ) : $(HFILES_BIN )
161+
156162# ---------------------------------------------------------------------------------
157- % .bin.o : % .bin
163+ % .bin.o % _bin.h : % .bin
158164# ---------------------------------------------------------------------------------
159165 @echo $(notdir $<)
160166 @$(bin2o)
You can’t perform that action at this time.
0 commit comments