stm32: Convert to use FROZEN_MANIFEST to specify frozen code.
All symlinks are removed, frozen files are now referenced via boards/manifest.py.
This commit is contained in:
parent
2fd3f2520d
commit
287800d6e1
|
@ -18,8 +18,8 @@ include $(BOARD_DIR)/mpconfigboard.mk
|
||||||
QSTR_DEFS = qstrdefsport.h $(BUILD)/pins_qstr.h $(BUILD)/modstm_qstr.h
|
QSTR_DEFS = qstrdefsport.h $(BUILD)/pins_qstr.h $(BUILD)/modstm_qstr.h
|
||||||
QSTR_GLOBAL_DEPENDENCIES = mpconfigboard_common.h $(BOARD_DIR)/mpconfigboard.h
|
QSTR_GLOBAL_DEPENDENCIES = mpconfigboard_common.h $(BOARD_DIR)/mpconfigboard.h
|
||||||
|
|
||||||
# directory containing scripts to be frozen as bytecode
|
# File containing description of content to be frozen into firmware.
|
||||||
FROZEN_MPY_DIR ?= modules
|
FROZEN_MANIFEST ?= boards/manifest.py
|
||||||
|
|
||||||
# include py core make definitions
|
# include py core make definitions
|
||||||
include $(TOP)/py/py.mk
|
include $(TOP)/py/py.mk
|
||||||
|
@ -485,13 +485,13 @@ $(TOP)/lib/stm32lib/README.md:
|
||||||
$(ECHO) "stm32lib submodule not found, fetching it now..."
|
$(ECHO) "stm32lib submodule not found, fetching it now..."
|
||||||
(cd $(TOP) && git submodule update --init lib/stm32lib)
|
(cd $(TOP) && git submodule update --init lib/stm32lib)
|
||||||
|
|
||||||
ifneq ($(FROZEN_DIR),)
|
ifneq ($(FROZEN_MANIFEST)$(FROZEN_DIR),)
|
||||||
# To use frozen source modules, put your .py files in a subdirectory (eg scripts/)
|
# To use frozen source modules, put your .py files in a subdirectory (eg scripts/)
|
||||||
# and then invoke make with FROZEN_DIR=scripts (be sure to build from scratch).
|
# and then invoke make with FROZEN_DIR=scripts (be sure to build from scratch).
|
||||||
CFLAGS += -DMICROPY_MODULE_FROZEN_STR
|
CFLAGS += -DMICROPY_MODULE_FROZEN_STR
|
||||||
endif
|
endif
|
||||||
|
|
||||||
ifneq ($(FROZEN_MPY_DIR),)
|
ifneq ($(FROZEN_MANIFEST)$(FROZEN_MPY_DIR),)
|
||||||
# To use frozen bytecode, put your .py files in a subdirectory (eg frozen/) and
|
# To use frozen bytecode, put your .py files in a subdirectory (eg frozen/) and
|
||||||
# then invoke make with FROZEN_MPY_DIR=frozen (be sure to build from scratch).
|
# then invoke make with FROZEN_MPY_DIR=frozen (be sure to build from scratch).
|
||||||
CFLAGS += -DMICROPY_QSTR_EXTRA_POOL=mp_qstr_frozen_const_pool
|
CFLAGS += -DMICROPY_QSTR_EXTRA_POOL=mp_qstr_frozen_const_pool
|
||||||
|
|
|
@ -5,4 +5,4 @@ AF_FILE = boards/stm32l072_af.csv
|
||||||
LD_FILES = boards/stm32l072xz.ld boards/common_basic.ld
|
LD_FILES = boards/stm32l072xz.ld boards/common_basic.ld
|
||||||
|
|
||||||
# Don't include default frozen modules because MCU is tight on flash space
|
# Don't include default frozen modules because MCU is tight on flash space
|
||||||
FROZEN_MPY_DIR ?=
|
FROZEN_MANIFEST ?=
|
||||||
|
|
|
@ -6,4 +6,4 @@ TEXT0_ADDR = 0x08000000
|
||||||
TEXT1_ADDR = 0x08020000
|
TEXT1_ADDR = 0x08020000
|
||||||
|
|
||||||
# Don't include default frozen modules because MCU is tight on flash space
|
# Don't include default frozen modules because MCU is tight on flash space
|
||||||
FROZEN_MPY_DIR ?=
|
FROZEN_MANIFEST ?=
|
||||||
|
|
|
@ -4,4 +4,4 @@ AF_FILE = boards/stm32f091_af.csv
|
||||||
LD_FILES = boards/stm32f091xc.ld boards/common_basic.ld
|
LD_FILES = boards/stm32f091xc.ld boards/common_basic.ld
|
||||||
|
|
||||||
# Don't include default frozen modules because MCU is tight on flash space
|
# Don't include default frozen modules because MCU is tight on flash space
|
||||||
FROZEN_MPY_DIR ?=
|
FROZEN_MANIFEST ?=
|
||||||
|
|
|
@ -4,4 +4,4 @@ AF_FILE = boards/stm32l072_af.csv
|
||||||
LD_FILES = boards/stm32l072xz.ld boards/common_basic.ld
|
LD_FILES = boards/stm32l072xz.ld boards/common_basic.ld
|
||||||
|
|
||||||
# Don't include default frozen modules because MCU is tight on flash space
|
# Don't include default frozen modules because MCU is tight on flash space
|
||||||
FROZEN_MPY_DIR ?=
|
FROZEN_MANIFEST ?=
|
||||||
|
|
|
@ -5,4 +5,4 @@ LD_FILES = boards/stm32l432.ld boards/common_basic.ld
|
||||||
OPENOCD_CONFIG = boards/openocd_stm32l4.cfg
|
OPENOCD_CONFIG = boards/openocd_stm32l4.cfg
|
||||||
|
|
||||||
# Don't include default frozen modules because MCU is tight on flash space
|
# Don't include default frozen modules because MCU is tight on flash space
|
||||||
FROZEN_MPY_DIR ?=
|
FROZEN_MANIFEST ?=
|
||||||
|
|
|
@ -0,0 +1,3 @@
|
||||||
|
freeze('$(MPY)/drivers/dht', 'dht.py')
|
||||||
|
freeze('$(MPY)/drivers/display', ('lcd160cr.py', 'lcd160cr_test.py'))
|
||||||
|
freeze('$(MPY)/drivers/onewire', 'onewire.py')
|
|
@ -1 +0,0 @@
|
||||||
../../../drivers/dht/dht.py
|
|
|
@ -1 +0,0 @@
|
||||||
../../../drivers/display/lcd160cr.py
|
|
|
@ -1 +0,0 @@
|
||||||
../../../drivers/display/lcd160cr_test.py
|
|
|
@ -1 +0,0 @@
|
||||||
../../../drivers/onewire/onewire.py
|
|
Loading…
Reference in New Issue