File tree 7 files changed +75
-2
lines changed
7 files changed +75
-2
lines changed Original file line number Diff line number Diff line change 1
1
#-------------------------------------------------------------------------------
2
- # Copyright (c) 2021-2023 , Arm Limited. All rights reserved.
2
+ # Copyright (c) 2021-2024 , Arm Limited. All rights reserved.
3
3
#
4
4
# SPDX-License-Identifier: BSD-3-Clause
5
5
#
@@ -26,6 +26,16 @@ target_link_options(bl1_1
26
26
$<$<C_COMPILER_ID:IAR>:--map\;${CMAKE_BINARY_DIR} /bin/bl1_1.map>
27
27
)
28
28
29
+ target_compile_options (bl1_1
30
+ PUBLIC
31
+ ${BL1_COMPILER_CP_FLAG}
32
+ )
33
+
34
+ target_link_options (bl1_1
35
+ PUBLIC
36
+ ${BL1_LINKER_CP_OPTION}
37
+ )
38
+
29
39
target_sources (bl1_1
30
40
PRIVATE
31
41
main.c
Original file line number Diff line number Diff line change @@ -105,4 +105,34 @@ if(TFM_BL1_SOFTWARE_CRYPTO)
105
105
$<$<C_COMPILER_ID:GNU>:-Wno-unused-parameter>
106
106
$<$<C_COMPILER_ID:ARMClang>:-Wno-unused-parameter>
107
107
)
108
+
109
+ target_compile_options (bl1_1_crypto_mbedcrypto
110
+ PRIVATE
111
+ ${BL1_COMPILER_CP_FLAG}
112
+ )
113
+
114
+ target_link_options (bl1_1_crypto_mbedcrypto
115
+ PUBLIC
116
+ ${BL1_LINKER_CP_OPTION}
117
+ )
118
+
119
+ target_compile_options (bl1_1_crypto_mbedtls
120
+ PRIVATE
121
+ ${BL1_COMPILER_CP_FLAG}
122
+ )
123
+
124
+ target_link_options (bl1_1_crypto_mbedtls
125
+ PUBLIC
126
+ ${BL1_LINKER_CP_OPTION}
127
+ )
128
+
129
+ target_compile_options (bl1_1_crypto_mbedx509
130
+ PRIVATE
131
+ ${BL1_COMPILER_CP_FLAG}
132
+ )
133
+
134
+ target_link_options (bl1_1_crypto_mbedx509
135
+ PUBLIC
136
+ ${BL1_LINKER_CP_OPTION}
137
+ )
108
138
endif ()
Original file line number Diff line number Diff line change @@ -28,6 +28,16 @@ target_link_options(bl1_2
28
28
$<$<C_COMPILER_ID:IAR>:--map\;${CMAKE_BINARY_DIR} /bin/bl1_2.map>
29
29
)
30
30
31
+ target_compile_options (bl1_2
32
+ PUBLIC
33
+ ${BL1_COMPILER_CP_FLAG}
34
+ )
35
+
36
+ target_link_options (bl1_2
37
+ PUBLIC
38
+ ${BL1_LINKER_CP_OPTION}
39
+ )
40
+
31
41
target_sources (bl1_2
32
42
PRIVATE
33
43
main.c
Original file line number Diff line number Diff line change @@ -48,8 +48,9 @@ target_compile_options(bl2
48
48
target_link_options (bl2
49
49
PRIVATE
50
50
$<$<C_COMPILER_ID:GNU>:-Wl,-Map=${CMAKE_BINARY_DIR} /bin/bl2.map>
51
- $<$<C_COMPILER_ID:ARMClang>:--map; ${BL2_LINKER_CP_OPTION} >
51
+ $<$<C_COMPILER_ID:ARMClang>:--map>
52
52
$<$<C_COMPILER_ID:IAR>:--map\;${CMAKE_BINARY_DIR} /bin/bl2.map>
53
+ ${BL2_LINKER_CP_OPTION}
53
54
)
54
55
55
56
target_compile_definitions (bl2
Original file line number Diff line number Diff line change @@ -273,6 +273,12 @@ if(BL1 AND PLATFORM_DEFAULT_BL1)
273
273
target_compile_options (platform_bl1_1
274
274
PUBLIC
275
275
$<$<BOOL :${BL1_1_SANITIZE} >:-fsanitize=${BL1_1_SANITIZE} >
276
+ ${BL1_COMPILER_CP_FLAG}
277
+ )
278
+
279
+ target_link_options (platform_bl1_1
280
+ PUBLIC
281
+ ${BL1_LINKER_CP_OPTION}
276
282
)
277
283
278
284
target_sources (platform_bl1_1
@@ -352,6 +358,12 @@ if(BL1 AND PLATFORM_DEFAULT_BL1)
352
358
target_compile_options (platform_bl1_2
353
359
PUBLIC
354
360
$<$<BOOL :${BL1_2_SANITIZE} >:-fsanitize=${BL1_2_SANITIZE} >
361
+ ${BL1_COMPILER_CP_FLAG}
362
+ )
363
+
364
+ target_link_options (platform_bl1_2
365
+ PUBLIC
366
+ ${BL1_LINKER_CP_OPTION}
355
367
)
356
368
endif ()
357
369
Original file line number Diff line number Diff line change @@ -233,6 +233,12 @@ macro(tfm_toolchain_reload_compiler)
233
233
# is not actually enabled in BL2, it will cause BL2 runtime fault.
234
234
set (BL2_LINKER_CP_OPTION --fpu=SoftVFP)
235
235
236
+ set (BL1_COMPILER_CP_FLAG
237
+ $<$<COMPILE_LANGUAGE:C>:-mfpu=softvfp>
238
+ $<$<COMPILE_LANGUAGE:ASM>:--fpu=softvfp>
239
+ )
240
+ set (BL1_LINKER_CP_OPTION --fpu=SoftVFP)
241
+
236
242
if (CONFIG_TFM_FLOAT_ABI STREQUAL "hard" )
237
243
set (COMPILER_CP_FLAG
238
244
$<$<COMPILE_LANGUAGE:C>:-mfloat-abi=hard>
Original file line number Diff line number Diff line change @@ -180,6 +180,10 @@ set(CMAKE_CXX_FLAGS ${CMAKE_CXX_FLAGS_INIT})
180
180
set (CMAKE_ASM_FLAGS ${CMAKE_ASM_FLAGS_INIT} )
181
181
182
182
set (BL2_COMPILER_CP_FLAG -mfloat-abi=soft)
183
+ set (BL2_LINKER_CP_OPTION -mfloat-abi=soft)
184
+
185
+ set (BL1_COMPILER_CP_FLAG -mfloat-abi=soft)
186
+ set (BL1_LINKER_CP_OPTION -mfloat-abi=soft)
183
187
184
188
if (CONFIG_TFM_FLOAT_ABI STREQUAL "hard" )
185
189
set (COMPILER_CP_FLAG -mfloat-abi=hard)
You can’t perform that action at this time.
0 commit comments