Skip to content

Conversation

@jonathanpeppers
Copy link
Member

@jonathanpeppers jonathanpeppers commented May 6, 2024

pjcollins added 3 commits May 6, 2024 16:26
Context: 6ba9992

Updates xaprepare and other relevant build tools to remove installation
of and reference to dependencies required to compile Host OS runtimes
such as mingw and mman-win32.  These runtime builds were disabled in
commit 6ba9992, and the dependencies are no longer required.
Fixes: #3132

Context: xamarin/monodroid@b934949

`Xamarin.Android.Cecil.dll` was created to avoid potential conflicts
and versioning issues with the copy of Cecil that Xamarin Studio was
using at the time; from April 2013:

> The issue is that when Xamarin Studio builds MSBuild-based
> projects, it does so through an intermediary
> `MonoDevelop.Projects.Formats.MSBuild.exe` process, which is
> responsible for using the `Microsoft.Build.*` assemblies to
> actually build the project.
>
> The problem is that the directory containing
> `MonoDevelop.Projects.Formats.MSBuild.exe` --
> `/Applications/Xamarin Studio.app/Contents/MacOS/lib/monodevelop/bin`
> -- contains its own copy of `Mono.Cecil.dll`, and _that_ is the
> version that was used!
>
> Meaning that in order to fix a Xamarin.Android bug, we would need
> an updated Xamarin Studio release.

Considering our migration to .NET, and how infrequently we change our
`Mono.Cecil` reference these days, these potential issues are likely
no longer a concern.

Our unique `Xamarin.Android.Cecil.dll` copy has been removed in favor
of `Mono.Cecil` package references in all projects that depend on it.

Conflicts:
    .external
    src/Xamarin.Android.Build.Tasks/Xamarin.Android.Build.Tasks.csproj
Context: b830f57
Context: 5daf102
Context: a831d62
Context: 8f33823

All of the dependencies we had on the contents of the mono archive from
commit mono/mono@6dd9def57ce have been removed from main.  We can now
remove all of the xaprepare sources that were used to download, prepare,
and install components from the mono bundle.

Conflicts:
    .external
@jonathanpeppers jonathanpeppers added the use-rebase-and-merge Normally we squash-and-merge PRs. Use this label so we instead rebase & merge. label May 6, 2024
The `Xamarin.Android.Build.Tasks` and `Microsoft.Android.Sdk.ILLink`
projects have been updated to only compile the linker sources that they
require, rather than including everything from the
`src/Xamarin.Android.Build.Tasks/Linker` folder.

Linker sources from mono/mono@6dd9def
have been added to `src/Xamarin.Android.Build.Tasks/Linker/External`.
Adding the couple dozen files we still depend on directly to the repo
removes one of the last dependencies we have on the mono bundle.

The `LinkAssembliesNoShrink` task is the main piece of XABT that depends
on these mono linker sources.  In the future we should try to see if we
can migrate this tasks functionality to some ILLink tool/task invocation.
@jonathanpeppers
Copy link
Member Author

Closing in favor of: #8931

We could consider revisiting this later.

@github-actions github-actions bot locked and limited conversation to collaborators Jun 8, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

use-rebase-and-merge Normally we squash-and-merge PRs. Use this label so we instead rebase & merge.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants