From c4953db271b2f54d3ff544435fcae01777f7715b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ioan=20Biz=C4=83u?= Date: Wed, 19 Mar 2025 13:04:58 +0100 Subject: [PATCH] chore(core/build): don't build with Tropic by default [no changelog] --- .github/workflows/core.yml | 2 +- core/Makefile | 2 ++ core/SConscript.unix | 7 +++++-- 3 files changed, 8 insertions(+), 3 deletions(-) diff --git a/.github/workflows/core.yml b/.github/workflows/core.yml index 4ca51d8add..5de0bcf13c 100644 --- a/.github/workflows/core.yml +++ b/.github/workflows/core.yml @@ -197,7 +197,7 @@ jobs: with: submodules: recursive - uses: ./.github/actions/environment - - run: nix-shell --run "poetry run make -C core build_unix" + - run: nix-shell --run "export DISABLE_TROPIC=0; poetry run make -C core build_unix" - run: nix-shell --run "cd vendor/ts-tvl/tvl/server/model_config && poetry install && poetry run model_server tcp -c model_config.yml &" - run: nix-shell --run "poetry run make -C core test" diff --git a/core/Makefile b/core/Makefile index dd231ec7d4..a81f70dac4 100644 --- a/core/Makefile +++ b/core/Makefile @@ -32,6 +32,7 @@ BITCOIN_ONLY ?= 0 BOOTLOADER_QA ?= 0 BOOTLOADER_DEVEL ?= 0 DISABLE_OPTIGA ?= 0 +DISABLE_TROPIC ?= 1 TREZOR_MODEL ?= T2T1 TREZOR_MEMPERF ?= 0 ADDRESS_SANITIZER ?= 0 @@ -125,6 +126,7 @@ SCONS_VARS = \ CFLAGS="$(CFLAGS)" \ CMAKELISTS="$(CMAKELISTS)" \ DISABLE_OPTIGA="$(DISABLE_OPTIGA)" \ + DISABLE_TROPIC="$(DISABLE_TROPIC)" \ LOG_STACK_USAGE="$(LOG_STACK_USAGE)" \ PRODUCTION="$(PRODUCTION)" \ PYOPT="$(PYOPT)" \ diff --git a/core/SConscript.unix b/core/SConscript.unix index 52e1b52a95..3acbd8b635 100644 --- a/core/SConscript.unix +++ b/core/SConscript.unix @@ -11,17 +11,20 @@ TREZOR_MODEL = ARGUMENTS.get('TREZOR_MODEL', 'T2T1') CMAKELISTS = int(ARGUMENTS.get('CMAKELISTS', 0)) HW_REVISION ='emulator' THP = ARGUMENTS.get('THP', '0') == '1' # Trezor-Host Protocol +DISABLE_TROPIC = ARGUMENTS.get('DISABLE_TROPIC', '0') == '1' BENCHMARK = ARGUMENTS.get('BENCHMARK', '0') == '1' PYOPT = ARGUMENTS.get('PYOPT', '1') FROZEN = ARGUMENTS.get('TREZOR_EMULATOR_FROZEN', 0) RASPI = os.getenv('TREZOR_EMULATOR_RASPI') == '1' - if BENCHMARK and PYOPT != '0': print("BENCHMARK=1 works only with PYOPT=0.") exit(1) -FEATURES_WANTED = ["input", "sd_card", "dma2d", "optiga", "tropic"] +FEATURES_WANTED = ["input", "sd_card", "dma2d", "optiga"] + +if not DISABLE_TROPIC: + FEATURES_WANTED.append('tropic') if not models.has_emulator(TREZOR_MODEL): # skip unix build