mirror of
https://github.com/apache/nuttx.git
synced 2026-08-01 20:28:58 +00:00
cmake: Omit default priority ELF symbol.
nuttx_add_application() encoded SCHED_PRIORITY_DEFAULT as a zero-valued nx_priority linker symbol. A zero priority is invalid for a runnable ELF application task. Do not emit nx_priority for the symbolic default. When the symbol is absent, the ELF loader retains its scheduler default. Continue emitting nx_priority for explicit numeric priorities. Companion to apache/nuttx-apps#3667. Assisted-by: Zed:GPT-5.6 Terra Signed-off-by: Marco Casaroli <marco.casaroli@gmail.com>
This commit is contained in:
parent
7fc26fd50c
commit
7eb9bb0be6
1 changed files with 1 additions and 4 deletions
|
|
@ -153,10 +153,7 @@ function(nuttx_add_application)
|
|||
set(SYMBOL_STACKSIZE $<$<NOT:$<BOOL:${USE_LINKER}>>:-Wl,>--defsym
|
||||
nx_stacksize=${STACKSIZE})
|
||||
endif()
|
||||
if(PRIORITY)
|
||||
if(PRIORITY STREQUAL "SCHED_PRIORITY_DEFAULT")
|
||||
set(PRIORITY "0")
|
||||
endif()
|
||||
if(PRIORITY AND NOT PRIORITY STREQUAL "SCHED_PRIORITY_DEFAULT")
|
||||
set(SYMBOL_PRIORITY $<$<NOT:$<BOOL:${USE_LINKER}>>:-Wl,>--defsym
|
||||
nx_priority=${PRIORITY})
|
||||
endif()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue