Platform dependent plugins and manifest

I’m working on an application that runs on Google Cardboard and Gear VR with Daydream support in the pipeline. These platforms require different plugins and a different manifest. Are there any best practices, assets or solutions that can help simplify the workflow? Right now I have three manifest files and have to rename when I switch builds. I’m also using platform dependent prefabs with preprocessor directives to manage scene objects. I have also been removing the Google VR plugins when building for Gear VR and vice versa although I suspect that this is unnecessary.

I cannot use Unity’s native Cardboard support as there is a regression in 5.6 that breaks OES texture support on many devices. Any help/ideas would be much appreciated.

Not that i’m aware of. When approached this issue in the past (building the same platform, such as “Android”, only for different variants like Google Play or Amazon), we had to roll our own solution. It is far from perfect, but it worked and allowed us to release the game under different “flavors” more easily.

You can read about how we handled it in this older post: https://forum.unity3d.com/threads/multiple-android-platforms.445305/#post-2881843

I’ve also talked to other developers back then about their own solutions, and essentially it’s all pretty similar:
Unity doesn’t provide a way to have different assets (code, textures, etc) only available for a particular “configuration” (i say configurations and not platform, since the same platform from Unity’s perspective can be built using different configurations to look and behave differently).

What most devs do is come up with their own way to mark assets to belong to a certain configuration, and provide a way to build the game using their own custom build script. in that way, you can do some manipulations before / after the build to configure what you need.

For example: you might want to process scenes before they get built, to strip any objects that are not part of the current configuration.

So, to sum it up, i don’t think there are any best practices, let alone any assets (on the asset store) that manage this for you.

Let me know if you need any more help !