android / android/android-xr-unity-package

Unintended Manifest Modifications by XRSessionFeatureBuildHooks for Non-AndroidXR OpenXR Platforms in Unity

Open
#9 2 comments 0 reactions 0 assignees View on GitHub
Dominant language
C#
Stars
94
Forks
17
PR merge metrics
No merged PRs in 30d

Description

Hi Google Team,
we have noticed an issue with the XRSessionFeatureBuildHooks Class in Unity Projects that use the OpenXR plugin across multiple plattforms.

When the AndroidXR Package is present in the project, the class injects additional configurations in the manifest files on build time, regardless of whether the current build target is AndroidXR or another OpenXR Plattform.

Currently the compiler flag UNITY_OPEN_XR_ANDROID_XR is defined as soon as the AndroidXR package is included in the project, rather than being conditional on the actual build profile. As a result, AndroidXRBuildUtils.IsUnityAndroidXRActive() always returns true, leading to unwanted manifest modifications for non AndroidXR builds.

Please adjust the detection logic in ProvideManifestRequirement() and AndroidXRBuildUtils.IsUnityAndroidXRActive(), so that they only modify the manifest and return true respectively when the active build target is AndroidXR.

Thanks

Best regards
David Schrott
SAP SE

Contributor guide

Open the contributing guide

Research direction

Start by locating XRSessionFeatureBuildHooks.ProvideManifestRequirement() and AndroidXRBuildUtils.IsUnityAndroidXRActive(), then inspect how the active Unity build target or profile is detected. Done means non-AndroidXR OpenXR builds leave manifests unchanged while AndroidXR builds still receive the required modifications.

Written by the indexing model from the issue text.

Assessment

Tech stack
android, csharp, unity
Domain
build-system, mobile-dev
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.