Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# Upcoming
* Android Resolver - Update and resolve `packaging` keyword in maintemplate based on android gradle plugin version. Fixes #715

# Version 1.2.183 - Sep 18, 2024
* Android Resolver - Handle package paths that don't include a version hash,
which is no longer present with Unity 6. Fixes #697
Expand Down
8 changes: 7 additions & 1 deletion source/AndroidResolver/src/PlayServicesResolver.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2352,7 +2352,13 @@ internal static IList<string> PackagingOptionsLines(ICollection<Dependency> depe
var sortedExcludeFiles = new List<string>(excludeFiles);
sortedExcludeFiles.Sort();
lines.Add("android {");
lines.Add(" packagingOptions {");

// `packagingOptions` is replaced by `packaging` keyword in Android Gradle plugin 8.0+
if ((new Dependency.VersionComparer()).Compare("8.0", AndroidGradlePluginVersion) <= 0) {
lines.Add(" packaging {");
} else {
lines.Add(" packagingOptions {");
}
foreach (var filename in sortedExcludeFiles) {
// Unity's Android extension replaces ** in the template with an empty
// string presumably due to the token expansion it performs. It's not
Expand Down
Loading