Skip to content

Commit eedc25e

Browse files
tejlmandthst-nordic
authored andcommitted
[nrf noup] cmake: multiimage: app mem partition flexibility
This commits adds ${IMAGE} in order to support multiimage in the app memory partition feature Signed-off-by: Torsten Rasmussen <[email protected]>
1 parent aa7f620 commit eedc25e

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1086,7 +1086,7 @@ if(CONFIG_USERSPACE)
10861086
-d ${OBJ_FILE_DIR}
10871087
-o ${APP_SMEM_UNALIGNED_LD}
10881088
${NEWLIB_PART} ${MBEDTLS_PART}
1089-
$<TARGET_PROPERTY:zephyr_property_target,COMPILE_OPTIONS>
1089+
$<TARGET_PROPERTY:${IMAGE}zephyr_property_target,COMPILE_OPTIONS>
10901090
$<$<BOOL:${CMAKE_VERBOSE_MAKEFILE}>:--verbose>
10911091
DEPENDS
10921092
kernel
@@ -1137,7 +1137,7 @@ if(CONFIG_USERSPACE)
11371137
-e $<TARGET_FILE:app_smem_unaligned_prebuilt>
11381138
-o ${APP_SMEM_ALIGNED_LD}
11391139
${NEWLIB_PART} ${MBEDTLS_PART}
1140-
$<TARGET_PROPERTY:zephyr_property_target,COMPILE_OPTIONS>
1140+
$<TARGET_PROPERTY:${IMAGE}zephyr_property_target,COMPILE_OPTIONS>
11411141
$<$<BOOL:${CMAKE_VERBOSE_MAKEFILE}>:--verbose>
11421142
DEPENDS
11431143
${KERNEL_LIBRARY}

cmake/app/boilerplate.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -635,7 +635,7 @@ endif()
635635
#
636636
# Currently used properties:
637637
# - COMPILES_OPTIONS: Used by application memory partition feature
638-
add_custom_target(zephyr_property_target)
638+
add_custom_target(${IMAGE}zephyr_property_target)
639639

640640
# "app" is a CMake library containing all the application code and is
641641
# modified by the entry point ${APPLICATION_SOURCE_DIR}/CMakeLists.txt

cmake/extensions.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -531,7 +531,7 @@ endfunction()
531531
# Note: Ensure the given partition has been define using
532532
# K_APPMEM_PARTITION_DEFINE in source code.
533533
function(zephyr_library_app_memory partition)
534-
set_property(TARGET zephyr_property_target
534+
set_property(TARGET ${IMAGE}zephyr_property_target
535535
APPEND PROPERTY COMPILE_OPTIONS
536536
"-l" $<TARGET_FILE_NAME:${ZEPHYR_CURRENT_LIBRARY}> "${partition}")
537537
endfunction()

0 commit comments

Comments
 (0)