Skip to content

Comments

Enable read environment variable on Android#431

Open
RenfengLiu wants to merge 1 commit intoKhronosGroup:mainfrom
RenfengLiu:android_loader
Open

Enable read environment variable on Android#431
RenfengLiu wants to merge 1 commit intoKhronosGroup:mainfrom
RenfengLiu:android_loader

Conversation

@RenfengLiu
Copy link

This fixs: #430

@CLAassistant
Copy link

CLAassistant commented Oct 16, 2023

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

@rpavlik
Copy link
Contributor

rpavlik commented Oct 16, 2023

The underlying issue is that there's no way to set those environment variables from outside the app, so they don't actually serve the purpose intended. (though, there may not be implicit layer support on android at all yet? or maybe just from manifests?)

A port of the behavior is more likely to be using getprop with some prefix before the environment variable name, I suspect.

What's your use case?

@RenfengLiu
Copy link
Author

RenfengLiu commented Oct 16, 2023

There are two ways applications can set the environment variable:

@RenfengLiu
Copy link
Author

The underlying issue is that there's no way to set those environment variables from outside the app, so they don't actually serve the purpose intended. (though, there may not be implicit layer support on android at all yet? or maybe just from manifests?)

A port of the behavior is more likely to be using getprop with some prefix before the environment variable name, I suspect.

What's your use case?

The use case is hoping that there's will same mechanism used in other platforms that can load the explicit layer or implicit layer when requested. The implict layers without the enable_environment works, but this loads the layer for all applications, which is not the desired behavior.

Using getprop would be another option, but this might require the Android system reserve that prop.

@rpavlik-bot rpavlik-bot added the synced to gitlab Synchronized to OpenXR internal GitLab label Dec 11, 2023
@rpavlik-bot
Copy link
Collaborator

An issue (number 2160) has been filed to correspond to this pull request in the internal Khronos GitLab (Khronos members only: KHR:openxr/openxr#2160 ), to facilitate working group processes.

This GitHub pull request will continue to be the main site of discussion.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

synced to gitlab Synchronized to OpenXR internal GitLab

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants