scripts: gen_handles.py: take device start symbol as argument.
The current gen_handles.py script uses linker defined symbols. As preparation for support of more linkers the gen_tables.py now takes the device start symbol as argument. For example, armlink and ld uses different symbols. With ld those can be named explicitly, but for armlink the linker decides the names. For ld, Zephyr defines: __device_start For armlink, the symbol is defined as: Image$$<section name>$$Base Therefore knowledge of the linker symbol to be used must be passed to gen_handles.py so that the correct symbol can be used for locating devices. To support this change, the creation of the asm, compiler, compiler-cpp, linker targets has been moved from target_toolchain_flags.cmake to target_toolchain.cmake. All linkers has been updated to support the use of the device_start_symbol on the linker target. List of linkers updated: - ld - lld - arcmwdt Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
This commit is contained in:
parent
a9db9a3aa8
commit
c9804d24fe
7 changed files with 20 additions and 10 deletions
|
@ -795,6 +795,7 @@ if(CONFIG_HAS_DTS)
|
|||
--output-source dev_handles.c
|
||||
--kernel $<TARGET_FILE:${ZEPHYR_PREBUILT_EXECUTABLE}>
|
||||
--zephyr-base ${ZEPHYR_BASE}
|
||||
--start-symbol "$<TARGET_PROPERTY:linker,devices_start_symbol>"
|
||||
DEPENDS ${ZEPHYR_PREBUILT_EXECUTABLE}
|
||||
)
|
||||
set_property(GLOBAL APPEND PROPERTY GENERATED_KERNEL_SOURCE_FILES dev_handles.c)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue