Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make sure debug and release builds of .a files are separate #9150

Merged
merged 1 commit into from
Jul 29, 2024

Conversation

grendello
Copy link
Contributor

@grendello grendello commented Jul 29, 2024

Context: a7b5768
Context: 2ec6f54

a7b5768, among other things, reorganized the way we build our native runtime.
One of the changes was subdivision of source code into separate subdirectories,
each of them a separate static library. One of reasons behind it was preparation
for the future work where we will be linking the application native runtime dynamically
at application build time, mixing and matching various libraries as necessary.

For the last reason, some of the .a archives are output to the location where we store
files to be packaged and distributed to end users. However, what a7b5768 missed was
the fact that this mode operation causes later builds to overwrite the earlier ones, since
archive names are the same. This can cause, for instance, the library debug build to be
silently replaced with the release one. While this won't be a problem on CI (and thus in
our distribution packages), it may have weird effects on one's local workflow (e.g. parts
of the runtime may be built for release and parts for debug, depending on the build order).

2ec6f54 added a partial solution to this issue, but one that covered only the UBSAN and
ASAN scenarios and ignored the debug vs release ones. This commit completes the fix by
making all output libraries use the -debug or -release prefix.

Also, libxamarin-native-tracing is not a static library, don't mistakenly treat it as one.

Context: a7b5768
Context: 2ec6f54

Also, libxamarin-native-tracing is not a static library, don't
mistakenly treat it as one.
@grendello grendello requested a review from jonpryor as a code owner July 29, 2024 10:21
@jonpryor jonpryor merged commit c157aed into main Jul 29, 2024
58 checks passed
@jonpryor jonpryor deleted the dev/grendel/unique-native-library-names branch July 29, 2024 16:49
@github-actions github-actions bot locked and limited conversation to collaborators Aug 29, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants