Skip to content

Conversation

@mark-inderhees
Copy link
Contributor

In order to compile with C++ exception handling for xtensa, the libgcc location needs to be known. This change uses the same logic from gcc's target.cmake to query the compiler for libgcc location and add the lib to the include list

In order to compile with C++ exception handling for xtensa, the libgcc
location needs to be known. This change uses the same logic from gcc's
target.cmake to query the compiler for libgcc location and add the lib
to the include list.

Signed-off-by: Mark Inderhees <[email protected]>
Copy link
Contributor

@tejlmand tejlmand left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

change looks reasonable to me, so approving based on the code changes as they look, but I don't have a license so I cannot produce the potential issue, and thus not verify the fix itself.

@dcpleung can you verify the fix ?

@stephanosio stephanosio requested a review from dcpleung November 11, 2024 13:20
@stephanosio stephanosio added the block: Toolchain Ensure this PR has been tested with non-GCC toolchains label Nov 11, 2024
@dcpleung
Copy link
Member

My Xtensa toolchains are too old that C++ stuff are pre-C++11 (where std::array was std::tr1:array). The accompanied newlib is not friendly with the POSIX layer in Zephyr. So I was unable to compile our libcxx tests. Though this change does not make matters worse for pure C stuff so I think this can go in.

@nashif nashif merged commit c9d6c4c into zephyrproject-rtos:main Nov 16, 2024
25 checks passed
@mark-inderhees mark-inderhees deleted the xtensa_eh branch October 1, 2025 22:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: Build System area: Toolchains Toolchains block: Toolchain Ensure this PR has been tested with non-GCC toolchains

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants