mirror of
https://github.com/ARM-software/arm-trusted-firmware.git
synced 2025-04-16 01:24:27 +00:00
fix(pie): pass -fpie
to the preprocessor as well
When PIE is enabled, the `-fpie` flag is passed to the compiler but not to the preprocessor. This change ensures that both tools are aware of when the image is position-independent when preprocessing, which impacts some pre-defined preprocessor definitions. Change-Id: I5208a591d60ee01312f6bf3dd7343abe6535ee61 Signed-off-by: Chris Kay <chris.kay@arm.com>
This commit is contained in:
parent
ec1c00a79c
commit
966660ecd0
1 changed files with 5 additions and 1 deletions
6
Makefile
6
Makefile
|
@ -654,12 +654,16 @@ endif
|
|||
ifeq ($(ENABLE_PIE),1)
|
||||
ifeq ($(BL2_AT_EL3),1)
|
||||
ifneq ($(BL2_IN_XIP_MEM),1)
|
||||
BL2_CPPFLAGS += -fpie
|
||||
BL2_CFLAGS += -fpie
|
||||
BL2_LDFLAGS += $(PIE_LDFLAGS)
|
||||
endif
|
||||
endif
|
||||
BL31_CFLAGS += -fpie
|
||||
BL31_CPPFLAGS += -fpie
|
||||
BL31_CFLAGS += -fpie
|
||||
BL31_LDFLAGS += $(PIE_LDFLAGS)
|
||||
|
||||
BL32_CPPFLAGS += -fpie
|
||||
BL32_CFLAGS += -fpie
|
||||
BL32_LDFLAGS += $(PIE_LDFLAGS)
|
||||
endif
|
||||
|
|
Loading…
Add table
Reference in a new issue