1
- # Copyright (c) 2020 ARM Limited. All rights reserved.
1
+ # Copyright (c) 2020-2021 ARM Limited. All rights reserved.
2
2
# SPDX-License-Identifier: Apache-2.0
3
3
4
4
# This is the boilerplate for Mbed OS
@@ -139,21 +139,6 @@ string(PREPEND MBED_TARGET_CONVERTED "mbed-")
139
139
140
140
target_link_libraries (mbed-core INTERFACE ${MBED_TARGET_CONVERTED} )
141
141
142
- #
143
- # Configures the application
144
- # Note, this function will be removed in the next revisions
145
- #
146
- function (mbed_configure_app_target target )
147
- # Gcc Arm requires memap to be set with app name, equally to ARMClang
148
- # TODO: move this to toolchain and set properly
149
- if (MBED_TOOLCHAIN STREQUAL "GCC_ARM" )
150
- target_link_options (mbed-core
151
- INTERFACE
152
- "-Wl,-Map=${CMAKE_CURRENT_BINARY_DIR} /${target}${CMAKE_EXECUTABLE_SUFFIX} .map"
153
- )
154
- endif ()
155
- endfunction ()
156
-
157
142
#
158
143
# Converts output file of `target` to binary file and to Intel HEX file.
159
144
#
@@ -233,6 +218,10 @@ endfunction()
233
218
# Set post build operations
234
219
#
235
220
function (mbed_set_post_build target )
221
+ # The mapfile name includes the top-level target name and the
222
+ # executable suffix for all toolchains as CMake hardcodes the name of the
223
+ # diagnostic output file for some toolchains.
224
+ mbed_configure_memory_map(mbed-core "${CMAKE_CURRENT_BINARY_DIR} /${target}${CMAKE_EXECUTABLE_SUFFIX} .map" )
236
225
mbed_validate_application_profile(${target} )
237
226
mbed_generate_bin_hex(${target} )
238
227
@@ -249,3 +238,7 @@ if ("${CMAKE_GENERATOR}" MATCHES "Ninja")
249
238
set (CMAKE_NINJA_FORCE_RESPONSE_FILE 1 CACHE INTERNAL "" )
250
239
endif ()
251
240
endif ()
241
+
242
+ # TODO: Remove once all example applications have removed it
243
+ function (mbed_configure_app_target target )
244
+ endfunction ()
0 commit comments