Search Issue Tracker

Fixed

Fixed in 4.4.0

Votes

1

Found in [Package]

4.3.3

4.4.0

Issue ID

XRMB-40

Regression

Yes

[Android][XR] XR Management Package >=4.3.1 deletes UnityLibrary AndroidManifest.xml when exporting a Gradle build

Package: XR Management

-

Steps to reproduce:
1. Open the attached user's project "XRAndroidBug.zip"
2. Export an Android project build
3. Check whether "Build/unityLibrary/src/main" contains "AndroidManifest.xml"
4. If you try and build the project with Android Studio it will fail as the manifest is missing

Expected results: Importing XR Management 4.3.1 or newer does not result in the exported Android builds failing and AndroidManifest.xml is not deleted in OnPostprocessBuild
Actual Results: Importing XR Management 4.3.1 or newer results in exported Android builds failing, because it deletes AndroidManifest.xml in OnPostprocessBuild

Reproducible in: XR Management 4.3.1, 4.3.3 (2020.3.48f1, 2021.3.25f1, 2022.2.18f1, 2023.1.0b16, 2023.2.0a14)
Not reproducible: XR Management 4.2.1 (2020.3.48f1, 2021.3.22f1, 2022.2.15f1, 2023.1.0b12, 2023.2.0a3)

Notes:
-A workaround is to embbed the package and delete the code that causes the issue in XRGeneralBuildprocessor:
public void OnPostprocessBuild(BuildReport report)
{
// Always remember to cleanup preloaded assets after build to make sure we don't
// dirty later builds with assets that may not be needed or are out of date.
CleanOldSettings();

// This is done to clean up XR-provider-specific manifest entries from Android builds when
// the incremental build system fails to rebuild the manifest, as there is currently
// (2023-09-27) no way to mark the manifest as "dirty."
CleanupAndroidManifest();
}

  1. Resolution Note (fix version 4.4.0):

    Verified Android project can be built through Android Studio using XR Management 4.4.0

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.