Skip to content

Instantly share code, notes, and snippets.

@jonathanpeppers
Last active September 10, 2018 20:00
Show Gist options
  • Save jonathanpeppers/a207a8828317460239a12a8b0cc918d7 to your computer and use it in GitHub Desktop.
Save jonathanpeppers/a207a8828317460239a12a8b0cc918d7 to your computer and use it in GitHub Desktop.
Notes for where we use `DirectoryAssemblyResolver`

Readonly:

  • src/Xamarin.Android.Build.Tasks/Tasks/BuildApk.cs: extract EmbeddedResource
  • src/Xamarin.Android.Build.Tasks/Tasks/CheckTargetFrameworks.cs: look at assembly attributes
  • src/Xamarin.Android.Build.Tasks/Tasks/GenerateJavaStubs.cs: look at all the types
  • src/Xamarin.Android.Build.Tasks/Tasks/GenerateResourceDesigner.cs: look at all the types
  • src/Xamarin.Android.Build.Tasks/Tasks/GetAdditionalResourcesFromAssemblies.cs: look at assembly attributes
  • src/Xamarin.Android.Build.Tasks/Tasks/ResolveAssemblies.cs: look at assembly references
  • src/Xamarin.Android.Build.Tasks/Tasks/ResolveLibraryProjectImports.cs: look at EmbeddedResource

Read/Write:

  • src/Xamarin.Android.Build.Tasks/Tasks/LinkAssemblies.cs: linker, look at types changes things, write back
  • src/Xamarin.Android.Build.Tasks/Tasks/StripEmbeddedLibraries.cs: strip EmbeddedResource, write back

NOTE: StripEmbeddedLibraries will soon be removed: dotnet/android#2162

Build Order:

  1. ResolveLibraryProjectImports
  2. GetAdditionalResourcesFromAssemblies
  3. GenerateResourceDesigner
  4. Compile
  5. ResolveAssemblies
  6. CheckTargetFrameworks
  7. LinkAssemblies
  8. GenerateJavaStubs
  9. BuildApk
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment