Skip to content

Commit

Permalink
Cleanup src_plugin_sdk directory
Browse files Browse the repository at this point in the history
- No need to copy local files
- No need to keep local copy of 'etherum-plugin-sdk' files
- Select needed files directly from the Makefile
  • Loading branch information
cedelavergne-ledger committed Apr 15, 2024
1 parent 5e21c7c commit 1ddd0e9
Show file tree
Hide file tree
Showing 19 changed files with 12 additions and 1,373 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/codespell.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,4 @@ jobs:
with:
builtin: clear,rare
check_filenames: true
path: src, src_bagl, src_common, src_features, src_nbgl, src_plugin_sdk, src_plugins, doc, client
path: src, src_bagl, src_features, src_nbgl, src_plugin_sdk, src_plugins, doc, client
25 changes: 4 additions & 21 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -38,38 +38,21 @@ ifneq ($(CHAIN),$(filter $(CHAIN),$(SUPPORTED_CHAINS)))
endif
include ./makefile_conf/chain/$(CHAIN).mk

### initialize plugin SDK submodule if needed, rebuild it, and warn if a difference is noticed
ifeq ($(CHAIN),ethereum)
ifneq ($(shell git submodule status | grep '^[-+]'),)
$(info INFO: Need to reinitialize git submodules)
$(shell git submodule update --init)
endif

# rebuild SDK
$(shell ./tools/build_sdk.sh)

# check if a difference is noticed (fail if it happens in CI build)
ifneq ($(shell git status | grep 'ethereum-plugin-sdk'),)
ifneq ($(JENKINS_URL),)
$(error ERROR: please update ethereum-plugin-sdk submodule first)
else
$(warning WARNING: please update ethereum-plugin-sdk submodule first)
endif
endif
endif

APPVERSION_M = 1
APPVERSION_N = 11
APPVERSION_P = 0
APPVERSION = $(APPVERSION_M).$(APPVERSION_N).$(APPVERSION_P)-dev

# Application source files
APP_SOURCE_PATH += src_common src src_features src_plugins
APP_SOURCE_PATH += src src_features src_plugins
ifeq ($(TARGET_NAME),TARGET_STAX)
APP_SOURCE_PATH += src_nbgl
else
APP_SOURCE_PATH += src_bagl
endif
APP_SOURCE_FILES += ./ethereum-plugin-sdk/src/common_utils.c
APP_SOURCE_FILES += ./ethereum-plugin-sdk/src/plugin_utils.c
INCLUDES_PATH += ./ethereum-plugin-sdk/src
APP_SOURCE_FILES += ${BOLOS_SDK}/lib_standard_app/crypto_helpers.c
INCLUDES_PATH += ${BOLOS_SDK}/lib_standard_app

Expand Down
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,12 @@ If you prefer using a terminal to perform the steps manually, you can use the gu

Setup a compilation environment by following the [shell with docker approach](#with-a-terminal).

Be sure you checkout the submodule:

```shell
git submodule update --init
```

From inside the container, use the following command to build the app:

```shell
Expand Down
51 changes: 0 additions & 51 deletions src_common/asset_info.h

This file was deleted.

34 changes: 0 additions & 34 deletions src_common/caller_api.h

This file was deleted.

Loading

0 comments on commit 1ddd0e9

Please sign in to comment.