From b8726e74c81cf19aff9cfa9e0886d268e97471ee Mon Sep 17 00:00:00 2001 From: Pavol Rusnak Date: Wed, 21 Aug 2019 17:46:30 +0200 Subject: [PATCH] core: add possibility to pass PYOPT to emulator frozen build --- core/Makefile | 3 ++- core/SConscript.unix | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/core/Makefile b/core/Makefile index 6e3cfbfd2..e95a271c8 100644 --- a/core/Makefile +++ b/core/Makefile @@ -17,6 +17,7 @@ UNIX_PORT_OPTS ?= CROSS_PORT_OPTS ?= PRODUCTION ?= 0 +PYOPT ?= 1 STLINK_VER ?= v2 OPENOCD = openocd -f interface/stlink-$(STLINK_VER).cfg -c "transport select hla_swd" -f target/stm32f4x.cfg @@ -110,7 +111,7 @@ build_unix: res ## build unix port $(SCONS) CFLAGS="$(CFLAGS)" $(UNIX_BUILD_DIR)/micropython $(UNIX_PORT_OPTS) build_unix_frozen: res build_cross ## build unix port with frozen modules - $(SCONS) CFLAGS="$(CFLAGS)" $(UNIX_BUILD_DIR)/micropython $(UNIX_PORT_OPTS) TREZOR_EMULATOR_FROZEN=1 + $(SCONS) CFLAGS="$(CFLAGS)" $(UNIX_BUILD_DIR)/micropython $(UNIX_PORT_OPTS) PYOPT="$(PYOPT)" TREZOR_EMULATOR_FROZEN=1 build_cross: ## build mpy-cross port $(MAKE) -C vendor/micropython/mpy-cross $(CROSS_PORT_OPTS) diff --git a/core/SConscript.unix b/core/SConscript.unix index 4bc8db7f5..6df4f25fd 100644 --- a/core/SConscript.unix +++ b/core/SConscript.unix @@ -8,7 +8,7 @@ CPPDEFINES_MOD = [] SOURCE_MOD = [] SOURCE_MOD_SECP256K1_ZKP = [] -PYOPT = '1' +PYOPT = ARGUMENTS.get('PYOPT', '1') # modtrezorconfig CPPPATH_MOD += [