Repository navigation
Conversation
objcopy --localize-hidden also localizes hidden weak (COMDAT) symbols. The final link keeps another object's copy of each group and discards the bundle's, so the bundle's now-local references point into discarded sections and the link fails. Localize only hidden GLOBAL definitions, listed with readelf -sW; hidden weak symbols stay weak and merge by name.
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
docker/Dockerfileonpeering/moq-peering(1aae13b, 8c3a9e6) fails at the final moqx link on its own bookworm image (GCC 12.2, binutils 2.40), with 1,410 errors like:objcopy --localize-hiddenincmake/bundle-peering.cmakealso localizes hidden weak symbols. Those are COMDAT group members: inline libstdc++ and spdlog code, hidden byVISIBILITY_INLINES_HIDDEN. The final link keeps an earlier object's copy of each group and discards the bundle's, so the bundle's now-local references point into discarded sections.This change localizes only hidden GLOBAL definitions, listed from
readelf -sW. Hidden weak symbols stay weak and merge by name, as they would without the bundle. picoquic stays isolated: nopicoquic_orptls_symbol is global in the bundle (1,872 symbols localized, 1,216 weak hidden left).Tested:
docker/Dockerfileat 8c3a9e6 with this change builds and links, and a moqx / LAPS / moqx fabric on moq-fabric f10e8bc5 using that image peers and delivers (steady streams, datagrams, path changes, relay restarts).This change is