Skip to content

Commit 8a192e3

Browse files
committed
Move more assembly packaging code to the helper class
1 parent 05b5f98 commit 8a192e3

File tree

2 files changed

+1
-17
lines changed

2 files changed

+1
-17
lines changed

src/Xamarin.Android.Build.Tasks/Tasks/BuildApk.cs

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -459,7 +459,7 @@ void AddAssemblies (ZipArchiveEx apk, bool debug, bool compress, IDictionary<And
459459
AddFileToArchiveIfNewer (apk, wrappedSourcePath, inArchivePath, GetCompressionMethod (inArchivePath));
460460
}
461461

462-
void DoAddAssembliesFromArchCollection (AndroidTargetArch arch, Dictionary<string, ITaskItem> assemblies)
462+
void DoAddAssembliesFromArchCollection (TaskLoggingHelper log, AndroidTargetArch arch, ITaskItem assembly)
463463
{
464464
// In the "all assemblies are per-RID" world, assemblies, pdb and config are disguised as shared libraries (that is,
465465
// their names end with the .so extension) so that Android allows us to put them in the `lib/{ARCH}` directory.
@@ -501,14 +501,6 @@ void DoAddAssembliesFromArchCollection (AndroidTargetArch arch, Dictionary<strin
501501
);
502502
}
503503

504-
void EnsureCompressedAssemblyData (string sourcePath, uint descriptorIndex)
505-
{
506-
if (compressedAssembly == null)
507-
compressedAssembly = new AssemblyCompression.AssemblyData (sourcePath, descriptorIndex);
508-
else
509-
compressedAssembly.SetData (sourcePath, descriptorIndex);
510-
}
511-
512504
string CompressAssembly (ITaskItem assembly)
513505
{
514506
if (!compress) {

src/Xamarin.Android.Build.Tasks/Utilities/AssemblyPackagingHelper.cs

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,7 @@ namespace Xamarin.Android.Tasks;
1010

1111
static class AssemblyPackagingHelper
1212
{
13-
<<<<<<< HEAD
1413
public static void AddAssembliesFromCollection (TaskLoggingHelper Log, ICollection<string> SupportedAbis, ICollection<ITaskItem> assemblies, Action<TaskLoggingHelper, AndroidTargetArch, ITaskItem> doAddAssembly)
15-
=======
16-
public static void AddAssembliesFromCollection (TaskLoggingHelper Log, ICollection<string> SupportedAbis, ICollection<ITaskItem> assemblies, Action<AndroidTargetArch, Dictionary<string, ITaskItem>> doAddAssemblies)
17-
>>>>>>> c4d883405 (Move some of assembly packaging code to a helper class)
1814
{
1915
Dictionary<AndroidTargetArch, Dictionary<string, ITaskItem>> perArchAssemblies = MonoAndroidHelper.GetPerArchAssemblies (
2016
assemblies,
@@ -32,7 +28,6 @@ public static void AddAssembliesFromCollection (TaskLoggingHelper Log, ICollecti
3228

3329
foreach (var kvp in perArchAssemblies) {
3430
Log.LogDebugMessage ($"Adding assemblies for architecture '{kvp.Key}'");
35-
<<<<<<< HEAD
3631
DoAddAssembliesFromArchCollection (Log, kvp.Key, kvp.Value, doAddAssembly);
3732
}
3833
}
@@ -45,9 +40,6 @@ static void DoAddAssembliesFromArchCollection (TaskLoggingHelper Log, AndroidTar
4540
}
4641

4742
doAddAssembly (Log, arch, assembly);
48-
=======
49-
doAddAssemblies (kvp.Key, kvp.Value);
50-
>>>>>>> c4d883405 (Move some of assembly packaging code to a helper class)
5143
}
5244
}
5345
}

0 commit comments

Comments
 (0)