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
#
@@ -231,6 +216,10 @@ endfunction()
231
216
# Set post build operations
232
217
#
233
218
function (mbed_set_post_build target )
219
+ # The mapfile name includes the top-level target name and the
220
+ # executable suffix for all toolchains as CMake hardcodes the name of the
221
+ # diagnostic output file for some toolchains.
222
+ mbed_configure_memory_map(mbed-core "${CMAKE_CURRENT_BINARY_DIR} /${target}${CMAKE_EXECUTABLE_SUFFIX} .map" )
234
223
mbed_validate_application_profile(${target} )
235
224
mbed_generate_bin_hex(${target} )
236
225
@@ -247,3 +236,7 @@ if ("${CMAKE_GENERATOR}" MATCHES "Ninja")
247
236
set (CMAKE_NINJA_FORCE_RESPONSE_FILE 1 CACHE INTERNAL "" )
248
237
endif ()
249
238
endif ()
239
+
240
+ # TODO: Remove once all example applications have removed it
241
+ function (mbed_configure_app_target target )
242
+ endfunction ()
0 commit comments