Skip to content

Conversation

@erhankur
Copy link
Contributor

@erhankur erhankur commented Nov 6, 2024

Swift examples add additional sections (.got, .got.plt, and .swift_modhash) into the final ELF, leading to linker errors due to unexpected memory regions in the IDF linker scripts.
To address this, we initially introduced a custom linker file here. However, as of IDF version 5.4 and later, the .got and .got.plt sections are discarded at link time.
In this PR, we remove the remaining .swift_modhash section using a custom CMake command. This change resolves the linker errors, making the custom linker file unnecessary.

@kubamracek kubamracek merged commit c617e5b into swiftlang:main Nov 7, 2024
trundlebits pushed a commit to trundlebits/swift-embedded-examples that referenced this pull request Jul 18, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants