Generate BTI GNU note for TS assembly files
Add GNU note after compiling assembly files to
avoid having warning.
Signed-off-by: Gabor Toth <gabor.toth2@arm.com>
Change-Id: I9c293826ec0d0a3ad7df5d19eab80e1d0d8069ae
diff --git a/environments/opteesp/default_toolchain_file.cmake b/environments/opteesp/default_toolchain_file.cmake
index 00ddf89..613cd43 100644
--- a/environments/opteesp/default_toolchain_file.cmake
+++ b/environments/opteesp/default_toolchain_file.cmake
@@ -34,6 +34,7 @@
# flag, and to turn on the BTI flag in the output anyway.
set(TS_MANDATORY_AARCH_FLAGS "${TS_MANDATORY_AARCH_FLAGS} -mbranch-protection=bti")
set(TS_MANDATORY_LINKER_FLAGS "${TS_MANDATORY_LINKER_FLAGS} -zforce-bti")
+ add_compile_definitions("BTI_ENABLED")
elseif(BTI_ENABLED STREQUAL "OFF")
set(TS_MANDATORY_AARCH_FLAGS "${TS_MANDATORY_AARCH_FLAGS} -mbranch-protection=none")
endif()