chg: easy printing of MAKE variables

Usage::
  make print-FLASHTOOL
  cd bootrom; make print-APP_CFLAGS
  cd client; make print-GCC_VERSION
This commit is contained in:
iceman1001 2017-09-18 18:59:51 +02:00
commit 28f1f23d48
4 changed files with 10 additions and 3 deletions

View file

@ -75,5 +75,8 @@ udev:
sudo udevadm control --reload-rules
sudo adduser $USER dialout
# easy printing of MAKE VARIABLES
print-%: ; @echo $* = $($*)
# Dummy target to test for GNU make availability
_test:

View file

@ -159,5 +159,4 @@ help:
@echo Multi-OS Makefile, you are running on $(DETECTED_OS)
@echo Possible targets:
@echo + all - Build the full image $(OBJDIR)/fullimage.s19
@echo + clean - Clean $(OBJDIR)
@echo + clean - Clean $(OBJDIR)

View file

@ -269,7 +269,9 @@ lua_build:
cd ../liblua && make $(LUAPLATFORM)
.PHONY: all clean
print-%: ; @echo $* = $($*)
# easy printing of MAKE VARIABLES
print-%: ; @echo $* = $($*)
$(OBJDIR)/%_NOSIMD.o : %.c $(OBJDIR)/%.d
$(CC) $(DEPFLAGS) $(CFLAGS) $(HARD_SWITCH_NOSIMD) -c -o $@ $<

View file

@ -109,6 +109,9 @@ $(OBJDIR)/%.s19: $(OBJDIR)/%.elf
version.c: default_version.c
perl ../tools/mkversion.pl .. > $@ || $(COPY) $^ $@
# easy printing of MAKE VARIABLES
print-%: ; @echo $* = $($*)
# Automatic dependency generation
DEPENDENCY_FILES = $(patsubst %.c,$(OBJDIR)/%.d,$(notdir $(THUMBSRC))) \
$(patsubst %.c,$(OBJDIR)/%.d,$(notdir $(ARMSRC))) \