Skip to content

Commit

Permalink
cmake: add linker_libraries.cmake for Cadence Xtensa linker
Browse files Browse the repository at this point in the history
Follow-up: #78320

Create linker_libraries.cmake for the Cadence Xtensa xt-ld linker to
ensure correct linking of runtime and C libraries as well as correct
link order.

Signed-off-by: Torsten Rasmussen <[email protected]>
  • Loading branch information
tejlmand committed Oct 7, 2024
1 parent 2a67664 commit 4414604
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions cmake/linker/xt-ld/linker_libraries.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Copyright (c) 2024 Nordic Semiconductor
#
# SPDX-License-Identifier: Apache-2.0

set_linker_property(NO_CREATE PROPERTY c_library "-lc")
set_linker_property(NO_CREATE PROPERTY rt_library "-lgcc")
set_linker_property(NO_CREATE PROPERTY c++_library "-lstdc++")
set_linker_property(PROPERTY link_order_library "c;rt")

0 comments on commit 4414604

Please sign in to comment.