Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Replace packagingOptions to packaging if AGP is 8.0+ #718

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
a-maurice merged 1 commit into googlesamples:master from argzdev:issue_715
Jan 9, 2025

Conversation

Copy link
Collaborator

@argzdev argzdev commented Nov 13, 2024

Fixes #715.

Due to incompatibility of the packagingOptions keyword in Unity 6, this will create unecessary mainTemplate.gradle.backup. Android keyword Packaging is introduced in Android Gradle Plugin version 8.0+.

Use packaging keyword if AGP version is 8.0+, else use packagingOptions

Unity version Gradle version Android Gradle Plug-in version
Unity-6 8.4 8.3.0
2022.3 7.5.1 7.4.2
2021.3 7.5.1 7.4.2

e.g.

// Android Resolver Exclusions Start
android {
 packaging {
 exclude ('/lib/arm64-v8a/*' + '*')
 exclude ('/lib/armeabi/*' + '*')
 exclude ('/lib/mips/*' + '*')
 exclude ('/lib/mips64/*' + '*')
 exclude ('/lib/x86/*' + '*')
 exclude ('/lib/x86_64/*' + '*')
 }

Zamaroht and binouze reacted with thumbs up emoji
@argzdev argzdev changed the title (削除) Add condition for checking AGP (削除ここまで) (追記) Replace packagingOptions to packaging if AGP is 8.0+ (追記ここまで) Nov 13, 2024
Copy link

Thaina commented Nov 30, 2024

@a-maurice Please accept fix to this bug

Copy link

Could we look at getting this approved? It is causing issues with Unity 6 builds.

@a-maurice a-maurice merged commit 5351241 into googlesamples:master Jan 9, 2025
1 check passed
Copy link

Thaina commented Jan 21, 2025
edited
Loading

@a-maurice The merge was not being built and it was not available in UPM

If you don't like to maintain the release please just convert this repo to be source package instead of built package so we can get the latest fix instead of waiting for your build

@googlesamples googlesamples locked and limited conversation to collaborators Feb 9, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Reviewers

@a-maurice a-maurice a-maurice approved these changes

+1 more reviewer

@Zamaroht Zamaroht Zamaroht approved these changes

Reviewers whose approvals may not affect merge requirements
Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

[Bug] gradle modifications not compatible with gradle version latest Unity uses

AltStyle によって変換されたページ (->オリジナル) /