Build: Avoid merging const strings under Armclang
Armclang default merges const strings with the same content, which
causes data access violation under high isolation levels. Apply
'--no_merge' to the linker to suppress this.
Change-Id: I1648c87206890b00659d6931389f6d4eefc6aef3
Signed-off-by: Shawn Shan <Shawn.Shan@arm.com>
diff --git a/toolchain_ARMCLANG.cmake b/toolchain_ARMCLANG.cmake
index 97e1b4f..13df5bd 100644
--- a/toolchain_ARMCLANG.cmake
+++ b/toolchain_ARMCLANG.cmake
@@ -60,6 +60,7 @@
--strict
--symbols
--xref
+ $<$<VERSION_GREATER:${TFM_ISOLATION_LEVEL},1>:--no-merge>
# Suppress link warnings that are consistant (and therefore hopefully
# harmless)
# https://developer.arm.com/documentation/100074/0608/linker-errors-and-warnings/list-of-the-armlink-error-and-warning-messages