mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-03-19 22:00:28 +01:00
[scripts] Remove unused EPSILON_DEVICE_BENCH flag
This commit is contained in:
@@ -229,7 +229,7 @@ void initClocks() {
|
||||
class RCC::APB2ENR apb2enr(0); // Reset value
|
||||
apb2enr.setADC1EN(true);
|
||||
apb2enr.setSYSCFGEN(true);
|
||||
apb2enr.setUSART6EN(true); // TODO if EPSILON_DEVICE_BENCH?
|
||||
apb2enr.setUSART6EN(true); // TODO required if building bench target only?
|
||||
RCC.APB2ENR()->set(apb2enr);
|
||||
|
||||
// Configure clocks in sleep mode
|
||||
|
||||
@@ -5,9 +5,6 @@ EPSILON_BOOT_PROMPT = update
|
||||
|
||||
BUILD_DIR = build/$(PLATFORM)/$(MODEL)
|
||||
|
||||
EPSILON_DEVICE_BENCH ?= 1
|
||||
SFLAGS += -DEPSILON_DEVICE_BENCH=$(EPSILON_DEVICE_BENCH)
|
||||
|
||||
$(BUILD_DIR)/python/port/port.o: CXXFLAGS += -DMP_PORT_USE_STACK_SYMBOLS=1
|
||||
|
||||
include scripts/platform.device.$(MODEL).mak
|
||||
|
||||
@@ -59,29 +59,19 @@ openocd:
|
||||
|
||||
# The flasher target is defined here because otherwise $(src) has not been
|
||||
# fully filled
|
||||
ifeq ($(EPSILON_DEVICE_BENCH),0)
|
||||
$(BUILD_DIR)/flasher.%.$(EXE): LDFLAGS += -Lion/src/$(PLATFORM)/flasher
|
||||
$(BUILD_DIR)/flasher.%.$(EXE): LDSCRIPT = ion/src/$(PLATFORM)/shared/ram.ld
|
||||
flasher_objs = $(call object_for,$(src) $(flasher_src) $(ion_device_dfu_xip_src))
|
||||
$(BUILD_DIR)/flasher.light.$(EXE): $(BUILD_DIR)/ion/src/$(PLATFORM)/flasher/display_light.o $(flasher_objs)
|
||||
$(BUILD_DIR)/flasher.verbose.$(EXE): $(BUILD_DIR)/ion/src/$(PLATFORM)/flasher/display_verbose.o $(flasher_objs)
|
||||
else
|
||||
$(BUILD_DIR)/flasher.%.$(EXE):
|
||||
@echo "Error: flasher.elf requires EPSILON_DEVICE_BENCH=0"
|
||||
endif
|
||||
|
||||
#TODO Do not build all apps... Put elsewhere?
|
||||
ifeq ($(EPSILON_DEVICE_BENCH),1)
|
||||
$(BUILD_DIR)/bench.ram.$(EXE): LDFLAGS += -Lion/src/$(PLATFORM)/bench
|
||||
$(BUILD_DIR)/bench.ram.$(EXE): LDSCRIPT = ion/src/$(PLATFORM)/shared/ram.ld
|
||||
$(BUILD_DIR)/bench.flash.$(EXE): LDSCRIPT = ion/src/$(PLATFORM)/$(MODEL)/internal_flash.ld
|
||||
$(BUILD_DIR)/bench.%.$(EXE): $(call object_for,$(src) $(bench_src) $(ion_device_dfu_xip_src))
|
||||
else
|
||||
$(BUILD_DIR)/bench.ram.$(EXE):
|
||||
@echo "Error: bench.*.bin requires EPSILON_DEVICE_BENCH=1"
|
||||
endif
|
||||
|
||||
ifeq ($(EPSILON_DEVICE_BENCH)$(EPSILON_ONBOARDING_APP)$(EPSILON_BOOT_PROMPT),01update)
|
||||
ifeq ($(EPSILON_ONBOARDING_APP)$(EPSILON_BOOT_PROMPT),1update)
|
||||
.PHONY: %_two_binaries
|
||||
%_two_binaries: %.elf
|
||||
@echo "Building an internal and an external binary for $<"
|
||||
@@ -92,7 +82,7 @@ ifeq ($(EPSILON_DEVICE_BENCH)$(EPSILON_ONBOARDING_APP)$(EPSILON_BOOT_PROMPT),01u
|
||||
$(Q) printf "\xFF\xFF\xFF\xFF" >> $(basename $<).internal.bin
|
||||
else
|
||||
%_two_binaries:
|
||||
@echo "Error: two_binaries requires EPSILON_DEVICE_BENCH=0 EPSILON_ONBOARDING_APP=1 EPSILON_BOOT_PROMPT=update"
|
||||
@echo "Error: two_binaries requires EPSILON_ONBOARDING_APP=1 EPSILON_BOOT_PROMPT=update"
|
||||
endif
|
||||
|
||||
.PHONY: binpack
|
||||
@@ -100,14 +90,14 @@ binpack:
|
||||
rm -rf build/binpack
|
||||
mkdir -p build/binpack
|
||||
make clean
|
||||
make -j8 EPSILON_DEVICE_BENCH=0 $(BUILD_DIR)/flasher.light.bin
|
||||
make -j8 $(BUILD_DIR)/flasher.light.bin
|
||||
cp $(BUILD_DIR)/flasher.light.bin build/binpack
|
||||
make clean
|
||||
make -j8 EPSILON_DEVICE_BENCH=1 $(BUILD_DIR)/bench.flash.bin
|
||||
make -j8 EPSILON_DEVICE_BENCH=1 $(BUILD_DIR)/bench.ram.bin
|
||||
make -j8 $(BUILD_DIR)/bench.flash.bin
|
||||
make -j8 $(BUILD_DIR)/bench.ram.bin
|
||||
cp $(BUILD_DIR)/bench.ram.bin $(BUILD_DIR)/bench.flash.bin build/binpack
|
||||
make clean
|
||||
make -j8 EPSILON_DEVICE_BENCH=0 EPSILON_ONBOARDING_APP=1 EPSILON_BOOT_PROMPT=update $(BUILD_DIR)/epsilon_two_binaries
|
||||
make -j8 EPSILON_ONBOARDING_APP=1 EPSILON_BOOT_PROMPT=update $(BUILD_DIR)/epsilon_two_binaries
|
||||
cp $(BUILD_DIR)/epsilon.internal.bin $(BUILD_DIR)/epsilon.external.bin build/binpack
|
||||
make clean
|
||||
cd build && for binary in flasher.light.bin bench.flash.bin bench.ram.bin epsilon.internal.bin epsilon.external.bin; do shasum -a 256 -b binpack/$${binary} > binpack/$${binary}.sha256;done
|
||||
|
||||
Reference in New Issue
Block a user