mirror of
https://github.com/RIOT-OS/RIOT.git
synced 2024-12-29 04:50:03 +01:00
Make: exterminate 'clean' buildtarget
Closes #993. We do not need to descend into the modules to know what to do on `make clean BOARD=blub`. We can just invoke `rm -rf bin/blub`. This PR only keeps the descending into the USEPKGs, since they might want to delete cached/downloaded/extracted data.
This commit is contained in:
parent
9f24ae2e62
commit
300d6b3e35
@ -21,8 +21,6 @@ ifeq ($(strip $(GIT_VERSION)),)
|
|||||||
endif
|
endif
|
||||||
export CFLAGS += -DVERSION=\"$(GIT_VERSION)\"
|
export CFLAGS += -DVERSION=\"$(GIT_VERSION)\"
|
||||||
|
|
||||||
.PHONY: clean
|
|
||||||
|
|
||||||
$(BINDIR)$(MODULE).a: $(OBJ) $(ASMOBJ)
|
$(BINDIR)$(MODULE).a: $(OBJ) $(ASMOBJ)
|
||||||
$(AD)$(AR) -rc $(BINDIR)$(MODULE).a $(OBJ) $(ASMOBJ)
|
$(AD)$(AR) -rc $(BINDIR)$(MODULE).a $(OBJ) $(ASMOBJ)
|
||||||
|
|
||||||
@ -44,7 +42,3 @@ $(BINDIR)$(MODULE)/%.o: %.s
|
|||||||
$(BINDIR)$(MODULE)/%.o: %.S
|
$(BINDIR)$(MODULE)/%.o: %.S
|
||||||
@mkdir -p $(BINDIR)$(MODULE)
|
@mkdir -p $(BINDIR)$(MODULE)
|
||||||
$(AD)$(CC) -c $(CFLAGS) $*.S -o $(BINDIR)$(MODULE)/$*.o
|
$(AD)$(CC) -c $(CFLAGS) $*.S -o $(BINDIR)$(MODULE)/$*.o
|
||||||
|
|
||||||
# remove compilation products
|
|
||||||
clean::
|
|
||||||
$(AD)rm -f $(BINDIR)$(MODULE).a $(OBJ) $(DEP) $(ASMOBJ)
|
|
||||||
|
@ -143,9 +143,7 @@ $(USEPKG:%=${BINDIR}%.a)::
|
|||||||
"$(MAKE)" -C $(RIOTBASE)/pkg/$(patsubst ${BINDIR}%.a,%,$@)
|
"$(MAKE)" -C $(RIOTBASE)/pkg/$(patsubst ${BINDIR}%.a,%,$@)
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
@for i in $(USEPKG) ; do "$(MAKE)" -C $(RIOTBASE)/pkg/$$i clean || exit 1; done ;
|
@for i in $(USEPKG) ; do "$(MAKE)" -C $(RIOTBASE)/pkg/$$i clean || exit 1; done
|
||||||
"$(MAKE)" -C $(RIOTBOARD)/$(BOARD) clean
|
|
||||||
"$(MAKE)" -C $(RIOTBASE) clean
|
|
||||||
rm -rf $(BINDIR)
|
rm -rf $(BINDIR)
|
||||||
|
|
||||||
flash: all
|
flash: all
|
||||||
|
@ -3,4 +3,5 @@
|
|||||||
all:
|
all:
|
||||||
$(error Project $(PROJECT) currently not supported for $(BOARD))
|
$(error Project $(PROJECT) currently not supported for $(BOARD))
|
||||||
|
|
||||||
clean: all
|
clean:
|
||||||
|
@true
|
||||||
|
@ -6,6 +6,3 @@ all: $(BINDIR)$(MODULE).a
|
|||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
||||||
|
|
||||||
include $(RIOTBASE)/Makefile.base
|
include $(RIOTBASE)/Makefile.base
|
||||||
|
|
||||||
clean::
|
|
||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i clean || exit 1; done ;
|
|
||||||
|
@ -7,6 +7,3 @@ all: $(BINDIR)$(MODULE).a
|
|||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
||||||
|
|
||||||
include $(RIOTBASE)/Makefile.base
|
include $(RIOTBASE)/Makefile.base
|
||||||
|
|
||||||
clean::
|
|
||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i clean || exit 1; done ;
|
|
||||||
|
@ -6,6 +6,3 @@ all: $(BINDIR)$(MODULE).a
|
|||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
||||||
|
|
||||||
include $(RIOTBASE)/Makefile.base
|
include $(RIOTBASE)/Makefile.base
|
||||||
|
|
||||||
clean::
|
|
||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i clean || exit 1; done ;
|
|
||||||
|
@ -6,6 +6,3 @@ all: $(BINDIR)$(MODULE).a
|
|||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
||||||
|
|
||||||
include $(RIOTBASE)/Makefile.base
|
include $(RIOTBASE)/Makefile.base
|
||||||
|
|
||||||
clean::
|
|
||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i clean || exit 1; done ;
|
|
||||||
|
@ -6,6 +6,3 @@ all: $(BINDIR)$(MODULE).a
|
|||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
||||||
|
|
||||||
include $(RIOTBASE)/Makefile.base
|
include $(RIOTBASE)/Makefile.base
|
||||||
|
|
||||||
clean::
|
|
||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i clean || exit 1; done ;
|
|
||||||
|
@ -6,6 +6,3 @@ all: $(BINDIR)$(MODULE).a
|
|||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
||||||
|
|
||||||
include $(RIOTBASE)/Makefile.base
|
include $(RIOTBASE)/Makefile.base
|
||||||
|
|
||||||
clean::
|
|
||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i clean || exit 1; done ;
|
|
||||||
|
@ -7,6 +7,3 @@ all: $(BINDIR)$(MODULE).a
|
|||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
||||||
|
|
||||||
include $(RIOTBASE)/Makefile.base
|
include $(RIOTBASE)/Makefile.base
|
||||||
|
|
||||||
clean::
|
|
||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i clean || exit 1; done ;
|
|
||||||
|
@ -12,6 +12,3 @@ $(BINDIR)$(MODULE)/%.o: %.c
|
|||||||
$(AD)$(CC) $(CFLAGS) $(NATIVEINCLUDES) -c $*.c -o $(BINDIR)$(MODULE)/$*.o
|
$(AD)$(CC) $(CFLAGS) $(NATIVEINCLUDES) -c $*.c -o $(BINDIR)$(MODULE)/$*.o
|
||||||
$(AD)$(CC) $(CFLAGS) $(NATIVEINCLUDES) -MM $*.c |\
|
$(AD)$(CC) $(CFLAGS) $(NATIVEINCLUDES) -MM $*.c |\
|
||||||
sed -e "1s|^|$(BINDIR)$(MODULE)/|" > $(BINDIR)$(MODULE)/$*.d
|
sed -e "1s|^|$(BINDIR)$(MODULE)/|" > $(BINDIR)$(MODULE)/$*.d
|
||||||
|
|
||||||
clean::
|
|
||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i clean || exit 1; done ;
|
|
||||||
|
@ -7,6 +7,3 @@ all: $(BINDIR)$(MODULE).a
|
|||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
||||||
|
|
||||||
include $(RIOTBASE)/Makefile.base
|
include $(RIOTBASE)/Makefile.base
|
||||||
|
|
||||||
clean::
|
|
||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i clean || exit 1; done ;
|
|
||||||
|
@ -6,6 +6,3 @@ all: $(BINDIR)$(MODULE).a
|
|||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
||||||
|
|
||||||
include $(RIOTBASE)/Makefile.base
|
include $(RIOTBASE)/Makefile.base
|
||||||
|
|
||||||
clean::
|
|
||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i clean || exit 1; done ;
|
|
||||||
|
@ -6,6 +6,3 @@ all: $(BINDIR)$(MODULE).a
|
|||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
||||||
|
|
||||||
include $(RIOTBASE)/Makefile.base
|
include $(RIOTBASE)/Makefile.base
|
||||||
|
|
||||||
clean::
|
|
||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i clean || exit 1; done ;
|
|
||||||
|
@ -6,6 +6,3 @@ all: $(BINDIR)$(MODULE).a
|
|||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
||||||
|
|
||||||
include $(RIOTBASE)/Makefile.base
|
include $(RIOTBASE)/Makefile.base
|
||||||
|
|
||||||
clean::
|
|
||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i clean || exit 1; done ;
|
|
||||||
|
@ -6,6 +6,3 @@ all: $(BINDIR)$(MODULE).a
|
|||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
||||||
|
|
||||||
include $(RIOTBASE)/Makefile.base
|
include $(RIOTBASE)/Makefile.base
|
||||||
|
|
||||||
clean::
|
|
||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i clean || exit 1; done ;
|
|
||||||
|
@ -6,6 +6,3 @@ all: $(BINDIR)$(MODULE).a
|
|||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
||||||
|
|
||||||
include $(RIOTBASE)/Makefile.base
|
include $(RIOTBASE)/Makefile.base
|
||||||
|
|
||||||
clean::
|
|
||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i clean || exit 1; done ;
|
|
||||||
|
@ -11,9 +11,6 @@ all: $(BINDIR)$(MODULE).a
|
|||||||
|
|
||||||
include $(RIOTBASE)/Makefile.base
|
include $(RIOTBASE)/Makefile.base
|
||||||
|
|
||||||
clean::
|
|
||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i clean || exit 1; done ;
|
|
||||||
|
|
||||||
# This is needed for NXP Cortex M devices
|
# This is needed for NXP Cortex M devices
|
||||||
nxpsum:
|
nxpsum:
|
||||||
$(CCLOCAL) nxpsum.c -std=c99 -o nxpsum
|
$(CCLOCAL) nxpsum.c -std=c99 -o nxpsum
|
||||||
|
@ -20,6 +20,3 @@ all: $(BINDIR)$(MODULE).a
|
|||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
||||||
|
|
||||||
include $(RIOTBASE)/Makefile.base
|
include $(RIOTBASE)/Makefile.base
|
||||||
|
|
||||||
clean::
|
|
||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i clean || exit 1; done ;
|
|
||||||
|
@ -12,6 +12,3 @@ all: $(BINDIR)$(MODULE).a
|
|||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
||||||
|
|
||||||
include $(RIOTBASE)/Makefile.base
|
include $(RIOTBASE)/Makefile.base
|
||||||
|
|
||||||
clean::
|
|
||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i clean || exit 1; done ;
|
|
||||||
|
@ -1,11 +1,3 @@
|
|||||||
MODULE =msp430_common
|
MODULE =msp430_common
|
||||||
|
|
||||||
DIRS =
|
|
||||||
|
|
||||||
all: $(BINDIR)$(MODULE).a
|
|
||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
|
||||||
|
|
||||||
include $(RIOTBASE)/Makefile.base
|
include $(RIOTBASE)/Makefile.base
|
||||||
|
|
||||||
clean::
|
|
||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i clean || exit 1; done ;
|
|
||||||
|
@ -8,6 +8,3 @@ all: $(BINDIR)$(MODULE).a
|
|||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
||||||
|
|
||||||
include $(RIOTBASE)/Makefile.base
|
include $(RIOTBASE)/Makefile.base
|
||||||
|
|
||||||
clean::
|
|
||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i clean || exit 1; done ;
|
|
||||||
|
@ -18,6 +18,3 @@ $(BINDIR)$(MODULE)/%.o: %.c
|
|||||||
$(AD)$(CC) $(CFLAGS) $(NATIVEINCLUDES) -c $*.c -o $(BINDIR)$(MODULE)/$*.o
|
$(AD)$(CC) $(CFLAGS) $(NATIVEINCLUDES) -c $*.c -o $(BINDIR)$(MODULE)/$*.o
|
||||||
$(AD)$(CC) $(CFLAGS) $(NATIVEINCLUDES) -MM $*.c |\
|
$(AD)$(CC) $(CFLAGS) $(NATIVEINCLUDES) -MM $*.c |\
|
||||||
sed -e "1s|^|$(BINDIR)$(MODULE)/|" > $(BINDIR)$(MODULE)/$*.d
|
sed -e "1s|^|$(BINDIR)$(MODULE)/|" > $(BINDIR)$(MODULE)/$*.d
|
||||||
|
|
||||||
clean::
|
|
||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i clean || exit 1; done ;
|
|
||||||
|
@ -39,7 +39,3 @@ all:
|
|||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
||||||
|
|
||||||
include $(RIOTBASE)/Makefile.base
|
include $(RIOTBASE)/Makefile.base
|
||||||
|
|
||||||
# remove compilation products
|
|
||||||
clean::
|
|
||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i clean || exit 1; done ;
|
|
||||||
|
@ -1,11 +1,3 @@
|
|||||||
MODULE =at86rf231
|
MODULE =at86rf231
|
||||||
|
|
||||||
DIRS =
|
|
||||||
|
|
||||||
all: $(BINDIR)$(MODULE).a
|
|
||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
|
||||||
|
|
||||||
include $(RIOTBASE)/Makefile.base
|
include $(RIOTBASE)/Makefile.base
|
||||||
|
|
||||||
clean::
|
|
||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i clean || exit 1; done ;
|
|
||||||
|
@ -15,6 +15,3 @@ all: $(BINDIR)$(MODULE).a
|
|||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
||||||
|
|
||||||
include $(RIOTBASE)/Makefile.base
|
include $(RIOTBASE)/Makefile.base
|
||||||
|
|
||||||
clean::
|
|
||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i clean || exit 1; done ;
|
|
||||||
|
@ -1,11 +1,3 @@
|
|||||||
MODULE =cc2420
|
MODULE =cc2420
|
||||||
|
|
||||||
DIRS =
|
|
||||||
|
|
||||||
all: $(BINDIR)$(MODULE).a
|
|
||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
|
||||||
|
|
||||||
include $(RIOTBASE)/Makefile.base
|
include $(RIOTBASE)/Makefile.base
|
||||||
|
|
||||||
clean::
|
|
||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i clean || exit 1; done ;
|
|
||||||
|
@ -106,7 +106,3 @@ all: $(BINDIR)$(MODULE).a
|
|||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
@for i in $(DIRS) ; do "$(MAKE)" -C $$i || exit 1; done ;
|
||||||
|
|
||||||
include $(RIOTBASE)/Makefile.base
|
include $(RIOTBASE)/Makefile.base
|
||||||
|
|
||||||
# remove compilation products
|
|
||||||
clean::
|
|
||||||
@for i in $(DIRS) ; do "$(MAKE)" -C $$i clean || exit 1; done ;
|
|
||||||
|
Loading…
Reference in New Issue
Block a user