Skip to content

Commit

Permalink
add 'any' target, fix missing 'PRJ' target, add one-off feature selec…
Browse files Browse the repository at this point in the history
…tion
  • Loading branch information
aegean-odyssey committed Jan 17, 2021
1 parent 3783c05 commit 7fc715a
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ $(PRJ_OBJS) $(PRJ_DEPS) : CFLAGS += -include ${PRJ_INCLUDE_H}
LDFLAGS += -L${CMSIS}/Lib/GCC
LDLIBS += -larm_cortexM0l_math

CFLAGS += ${DEFINES}
CFLAGS += ${DEFINES} $(foreach i,$(select),${${i}})
CPPFLAGS += -fsingle-precision-constant -fmerge-all-constants
CFLAGS += -Os -fdata-sections -ffunction-sections -flto $(INCLUDE)
CXXFLAGS += $(CFLAGS) -fno-exceptions -fno-rtti
Expand All @@ -182,10 +182,13 @@ BINSIZE = arm-none-eabi-size

### MAKE RULES

.PHONY : one all clean realclean distclean depends T1 T2 ALL
.PHONY : any one all clean realclean distclean depends PRJ T1 T2 ALL

.PRECIOUS : %.elf

any : distclean realclean ${MARLIN} ${BUILD}
$(call variant,PRJ)

one : ${MARLIN} ${BUILD}
ifneq (${D_COUNT},$(words $(wildcard ${BUILD}/*.d)))
# # something's missing, re-create dependencies
Expand Down Expand Up @@ -230,6 +233,9 @@ distclean : clean

depends : $(BSP_DEPS) $(PRJ_DEPS)

PRJ : ${PRJ}.otx ${PRJ}.bin ${PRJ}.map ${PRJ}.elf
@cp -u $^ ${ZD} && cat $<

T1 : ${T1}.otx ${T1}.bin ${T1}.map ${T1}.elf
@cp -u $^ ${ZD} && cat $<

Expand Down

0 comments on commit 7fc715a

Please sign in to comment.