mirror of
https://github.com/apache/nuttx.git
synced 2025-01-12 19:48:33 +08:00
sim: Fixes the linker 'noexecstack' warning
Signed-off-by: Leo Chung <gewalalb@gmail.com>
This commit is contained in:
parent
43797ea6cc
commit
63c8de5f03
2 changed files with 5 additions and 0 deletions
|
@ -727,6 +727,7 @@ else()
|
|||
OUTPUT nuttx.rel
|
||||
COMMAND
|
||||
${CMAKE_C_COMPILER} ARGS -r $<$<BOOL:${CONFIG_SIM_M32}>:-m32>
|
||||
$<$<BOOL:${CONFIG_HOST_LINUX}>:-Wl,-z,noexecstack>
|
||||
$<TARGET_OBJECTS:sim_head> $<$<NOT:$<BOOL:${APPLE}>>:-Wl,--start-group>
|
||||
${nuttx_libs_paths} $<$<NOT:$<BOOL:${APPLE}>>:-Wl,--end-group> -o
|
||||
nuttx.rel
|
||||
|
|
|
@ -200,3 +200,7 @@ else()
|
|||
add_link_options(-Wl,--gc-sections)
|
||||
add_link_options(-Wl,-Ttext-segment=0x40000000)
|
||||
endif()
|
||||
|
||||
if(CONFIG_HOST_LINUX)
|
||||
add_link_options(-Wl,-z,noexecstack)
|
||||
endif()
|
||||
|
|
Loading…
Reference in a new issue