Repository navigation
Conversation
CMake support for module manager kernels uses file(GLOB ...) to collect
port sources under ${TX_PORT_PATH}/module_manager/src/. In Cortex-M33,
Cortex-M23, and Cortex-A35 SMP ports, sample tx_initialize_low_level.S
files were placed inside module_manager/src/ rather than example_build/.
This caused the sample startup file to be compiled into libthreadx.a,
exporting hardcoded clock constants, memory symbols, and exception
vector handlers (SysTick_Handler, HardFault_Handler, etc.) which led to
multiple-definition linker collisions when linked with applications.
Move tx_initialize_low_level.S to example_build/ across affected ports,
delete the redundant copy in rxv2/iar/module_manager/src/, and update
the Cortex-M23 GNU assembly file to reference the standard GNU linker
symbol __RAM_segment_used_end__.
Additionally, add a regex filter in CMakeLists.txt to exclude any
tx_initialize_low_level files from TX_PORT_SOURCES during module manager
builds as a permanent build-level safeguard.
Fixes eclipse-threadx#852
Signed-off-by: Dev10-sys <kalpanagola9897@gmail.com>
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
In the Cortex-M33, Cortex-M23, and Cortex-A35 SMP module manager ports,
tx_initialize_low_level.Swas sitting insidemodule_manager/src/instead ofexample_build/. When building with-DTHREADX_MODULE_MANAGER=ON, the CMake build globs everything inmodule_manager/src/, which pulled this sample startup file straight intolibthreadx.a. This breaks downstream applications linking against ThreadX because the static library ends up exporting strong definitions forSysTick_Handler,HardFault_Handler, and_tx_initialize_low_level, along with references to sample linker symbols like__RAM_segment_used_end__.To fix this,
tx_initialize_low_level.Shas been moved toexample_build/across the affected ports, matching the layout used by Cortex-M4 and the rest of the ports. The redundant duplicate copy inrxv2/iar/module_manager/src/was removed, and the Cortex-M23 GNU assembly file was updated to use the standard GNU linker symbol__RAM_segment_used_end__instead of Arm Compiler'sImage$$ARM_LIB_STACK$$ZI$$Limit.An explicit filter was also added to
CMakeLists.txtunderTHREADX_MODULE_MANAGERto ensure anytx_initialize_low_levelfiles are excluded from the library build even if one ever ends up in the source directory.Fixes #852