/// <summary> /// Sets %(DestinationSubDirectory) and %(DestinationSubPath) based on %(RuntimeIdentifier) /// </summary> void SetDestinationSubDirectory(ITaskItem assembly, string fileName, ITaskItem symbol) { var rid = assembly.GetMetadata("RuntimeIdentifier"); var abi = MonoAndroidHelper.RuntimeIdentifierToAbi(rid); if (!string.IsNullOrEmpty(abi)) { string destination = Path.Combine(assembly.GetMetadata("DestinationSubDirectory"), abi); assembly.SetMetadata("DestinationSubDirectory", destination + Path.DirectorySeparatorChar); assembly.SetMetadata("DestinationSubPath", Path.Combine(destination, fileName)); if (symbol != null) { destination = Path.Combine(symbol.GetMetadata("DestinationSubDirectory"), abi); symbol.SetMetadata("DestinationSubDirectory", destination + Path.DirectorySeparatorChar); symbol.SetMetadata("DestinationSubPath", Path.Combine(destination, Path.GetFileName(symbol.ItemSpec))); } } else { Log.LogDebugMessage($"Android ABI not found for: {assembly.ItemSpec}"); assembly.SetDestinationSubPath(); symbol?.SetDestinationSubPath(); } }