Skip to content

Turn ForceLoad back on, now that the archive has no duplicates - #24

Merged
jcant0n merged 1 commit into
mainfrom
forceload-back-on
Aug 9, 2026
Merged

Turn ForceLoad back on, now that the archive has no duplicates#24
jcant0n merged 1 commit into
mainfrom
forceload-back-on

Conversation

@jcant0n

@jcant0n jcant0n commented Aug 9, 2026

Copy link
Copy Markdown
Member

Both settings were tried against a real link. This is the one that works.

Without it, the linker keeps only the members something references, and every entry point here is reached from managed code rather than from native. The application built, weighed 30 MB, and did not define cesium_async_system_create at all — the member carrying it had been dropped. A P/Invoke into it would have failed on a device, in somebody else's application, long after every build went green.

With it, the link used to die on duplicate symbols, because the archive carried libjpeg.a beside libturbojpeg.a and libwebpdecoder.a beside libwebp.a. That is now fixed where it belonged — in the merge in CesiumC#19, which no longer takes archives nothing links. The archive went from 61.0 MB across 143 archives to 59.9 MB across 141, and both iOS legs build there.

The smoke leg is what made this a measurement rather than an argument

It reads the built executable and fails if cesium_async_system_create is not among its defined symbols. That is exactly how the dropped member was found, and it is why flipping this back is a one-line change rather than a hope.

Needs the CesiumC release to be re-cut first, which is in flight; the new archive is what makes ForceLoad safe.

Both settings were tried against a real link, and this is the one that
works.

Without it the linker keeps only the members something references, and
every entry point here is reached from managed code rather than from
native. The application built, weighed 30 MB and did not define
cesium_async_system_create at all: the member carrying it had been
dropped. A P/Invoke into it would have failed on a device, in somebody
else's application, long after every build went green.

With it, the link used to die on duplicate symbols, because the archive
carried libjpeg.a beside libturbojpeg.a and libwebpdecoder.a beside
libwebp.a. That is fixed where it belonged, in the merge in CesiumC,
which no longer takes archives nothing links.

The smoke leg is what turned this from an argument into a measurement.
It reads the built executable and fails if cesium_async_system_create is
not among its defined symbols, which is exactly how the dropped member
was found.
@github-actions

github-actions Bot commented Aug 9, 2026

Copy link
Copy Markdown
Contributor

API gate: additive

Every symbol that existed still exists, unchanged. Nothing that compiled before stops compiling.

Target framework Added Removed
net10.0-ios +0 -0
net10.0 +0 -0

Enum and constant values are part of the measured surface: a renumbering keeps compiling and sends the wrong number to the driver, so it counts as a removal.

@jcant0n
jcant0n merged commit 1e3c29c into main Aug 9, 2026
4 checks passed
@jcant0n
jcant0n deleted the forceload-back-on branch August 9, 2026 07:44
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.

1 participant