make: Move clean target above BOARD check

This commit is contained in:
Tim Crawford
2020-04-07 11:34:35 -06:00
committed by Jeremy Soller
parent 2a86572f2b
commit dfe3032f4d

View File

@ -1,5 +1,9 @@
-include config.mk -include config.mk
# Target to remove build artifacts
clean:
rm -rf build
# Parameter for current board # Parameter for current board
ifeq ($(BOARD),) ifeq ($(BOARD),)
$(info $(shell echo Please set BOARD to one of the following)) $(info $(shell echo Please set BOARD to one of the following))
@ -19,10 +23,6 @@ BUILD=build/$(BOARD)/$(VERSION)
all: $(BUILD)/ec.rom all: $(BUILD)/ec.rom
$(info Built '$(VERSION)' for '$(BOARD)') $(info Built '$(VERSION)' for '$(BOARD)')
# Target to remove build artifacts
clean:
rm -rf build
# Include common source # Include common source
COMMON_DIR=src/common COMMON_DIR=src/common
SRC=$(wildcard $(COMMON_DIR)/*.c) SRC=$(wildcard $(COMMON_DIR)/*.c)