-
Notifications
You must be signed in to change notification settings - Fork 128
Closed
Description
As part of #1164 work we need to rethink how we are going to allow custom steps to mark additional elements either conditionally or unconditionally. Currently, many custom steps are run before mark as BaseSubStep called via SubStepsDispatcher which means they assume that context.GetAssemblies ()
returns full assemblies set. This needs to change if we want to really delay load assemblies.
The logic inside these custom sub-steps is usually something that marks type or type members when the type is found. Here are a few examples
- https://github.com/xamarin/xamarin-android/blob/master/src/Microsoft.Android.Sdk.ILLink/PreserveRegistrations.cs
- https://github.com/xamarin/xamarin-android/blob/master/src/Xamarin.Android.Build.Tasks/Linker/MonoDroid.Tuner/PreserveApplications.cs
- https://github.com/xamarin/xamarin-android/blob/master/src/Xamarin.Android.Build.Tasks/Linker/MonoDroid.Tuner/PreserveJavaTypeRegistrations.cs
- https://github.com/xamarin/xamarin-android/blob/master/src/Xamarin.Android.Build.Tasks/Linker/MonoDroid.Tuner/PreserveJavaExceptions.cs
It seems like if we had a solution on how to run additional marking logic for types and members conditionally we could convert these SubSteps into something that does not need GetAssemblies
call.
sbomer