2022-02-10 09:42:46 +00:00
|
|
|
NAME = bootloader-unaligned
|
2014-10-23 16:09:41 +00:00
|
|
|
|
|
|
|
OBJS += bootloader.o
|
|
|
|
OBJS += usb.o
|
|
|
|
|
2021-11-29 15:06:45 +00:00
|
|
|
# Overrides from libtrezor.
|
|
|
|
# Objects ending with 'small.o' are built with -Os to make the bootloader smaller.
|
2019-11-09 18:54:13 +00:00
|
|
|
CFLAGS += -DFONT_SKIP_FIXED=1
|
2021-11-29 14:03:13 +00:00
|
|
|
OBJS += ../buttons.small.o
|
|
|
|
OBJS += ../common.small.o
|
|
|
|
OBJS += ../flash.small.o
|
2022-05-03 12:52:18 +00:00
|
|
|
OBJS += ../fw_signatures.small.o
|
2021-11-29 15:06:45 +00:00
|
|
|
OBJS += ../gen/bitmaps.small.o
|
|
|
|
OBJS += ../gen/fonts.small.o
|
2021-11-29 14:03:13 +00:00
|
|
|
OBJS += ../layout.small.o
|
2021-11-29 15:06:45 +00:00
|
|
|
OBJS += ../memory.small.o
|
2021-11-29 14:03:13 +00:00
|
|
|
OBJS += ../oled.small.o
|
|
|
|
OBJS += ../random_delays.small.o
|
|
|
|
OBJS += ../rng.small.o
|
|
|
|
OBJS += ../setup.small.o
|
2021-11-29 15:06:45 +00:00
|
|
|
OBJS += ../startup.o
|
2021-11-29 14:03:13 +00:00
|
|
|
OBJS += ../supervise.small.o
|
|
|
|
OBJS += ../timer.small.o
|
|
|
|
OBJS += ../usb21_standard.small.o
|
2021-11-29 15:06:45 +00:00
|
|
|
OBJS += ../usb_standard.small.o
|
|
|
|
OBJS += ../util.small.o
|
2021-11-29 14:03:13 +00:00
|
|
|
OBJS += ../webusb.small.o
|
|
|
|
OBJS += ../winusb.small.o
|
2019-11-09 18:54:13 +00:00
|
|
|
|
2021-11-29 14:03:13 +00:00
|
|
|
# Overrides from trezor-crypto
|
2019-11-09 18:54:13 +00:00
|
|
|
CFLAGS += -DUSE_PRECOMPUTED_CP=0
|
2021-11-29 15:06:45 +00:00
|
|
|
CFLAGS += -DUSE_PRECOMPUTED_IV=0
|
2017-07-04 18:21:10 +00:00
|
|
|
OBJS += ../vendor/trezor-crypto/bignum.small.o
|
2015-12-15 22:01:54 +00:00
|
|
|
OBJS += ../vendor/trezor-crypto/ecdsa.small.o
|
2021-11-29 15:06:45 +00:00
|
|
|
OBJS += ../vendor/trezor-crypto/hmac_drbg.small.o
|
|
|
|
OBJS += ../vendor/trezor-crypto/memzero.small.o
|
2015-12-15 22:01:54 +00:00
|
|
|
OBJS += ../vendor/trezor-crypto/secp256k1.small.o
|
2017-07-04 18:21:10 +00:00
|
|
|
OBJS += ../vendor/trezor-crypto/sha2.small.o
|
2014-10-23 16:09:41 +00:00
|
|
|
|
2017-07-04 18:21:10 +00:00
|
|
|
OPTFLAGS ?= -Os
|
|
|
|
|
2015-08-05 14:57:23 +00:00
|
|
|
include ../Makefile.include
|
2014-10-23 16:09:41 +00:00
|
|
|
|
2021-11-29 14:03:13 +00:00
|
|
|
# Remove libtrezor from linking since we specified the small versions
|
|
|
|
LDLIBS := $(filter-out -ltrezor,$(LDLIBS))
|
|
|
|
|
2022-02-10 09:42:46 +00:00
|
|
|
bootloader.bin: $(NAME).bin
|
|
|
|
./firmware_align.py $< $@
|
|
|
|
|
|
|
|
all: bootloader.bin
|