LedgerHQ / nanos-secure-sdk

Secure (ST31) SDK for Ledger Nano S
Apache License 2.0
96 stars 54 forks source link

Wrong Makefile include order? #24

Closed smogm closed 3 years ago

smogm commented 4 years ago

In the ledger-app-btc (and others) the Makefile.defines is included at the very beginning: https://github.com/LedgerHQ/ledger-app-btc/blob/master/Makefile#L21

The Makefile.defines uses the variable GCCPATH since this commit: https://github.com/LedgerHQ/nanos-secure-sdk/commit/1f2706941b68d897622f75407a868b60eb2be8d7#diff-271b275950a0192e2fae2a1418a2f3b8R44

But the GCCPATH variable is defined afterwards: https://github.com/LedgerHQ/ledger-app-btc/blob/master/Makefile#L256

So I'm getting multiple errors like this:

make: arm-none-eabi-gcc: Kommando nicht gefunden

And I'm sure depending on this I'm getting lots of missing variable errors like this later in the build process:

src/main.c:1790:8: error: use of undeclared identifier 'C_icon_crossmark'
      &C_icon_crossmark,
       ^