File tree 2 files changed +10
-1
lines changed
source/AndroidResolver/src
2 files changed +10
-1
lines changed Original file line number Diff line number Diff line change
1
+ # Upcoming
2
+ * Android Resolver - Update and resolve ` packaging ` keyword in maintemplate based on android gradle plugin version. Fixes #715
3
+
1
4
# Version 1.2.183 - Sep 18, 2024
2
5
* Android Resolver - Handle package paths that don't include a version hash,
3
6
which is no longer present with Unity 6. Fixes #697
Original file line number Diff line number Diff line change @@ -2352,7 +2352,13 @@ internal static IList<string> PackagingOptionsLines(ICollection<Dependency> depe
2352
2352
var sortedExcludeFiles = new List < string > ( excludeFiles ) ;
2353
2353
sortedExcludeFiles . Sort ( ) ;
2354
2354
lines . Add ( "android {" ) ;
2355
- lines . Add ( " packagingOptions {" ) ;
2355
+
2356
+ // `packagingOptions` is replaced by `packaging` keyword in Android Gradle plugin 8.0+
2357
+ if ( ( new Dependency . VersionComparer ( ) ) . Compare ( "8.0" , AndroidGradlePluginVersion ) <= 0 ) {
2358
+ lines . Add ( " packaging {" ) ;
2359
+ } else {
2360
+ lines . Add ( " packagingOptions {" ) ;
2361
+ }
2356
2362
foreach ( var filename in sortedExcludeFiles ) {
2357
2363
// Unity's Android extension replaces ** in the template with an empty
2358
2364
// string presumably due to the token expansion it performs. It's not
You can’t perform that action at this time.
0 commit comments