Built In Shaders dependency - is it necessary?

I’ve been testing out Addressables in an existing project which made use of asset bundles for providing remote content to players via a CDN. As a test, I created a new asset group for an existing prefab and built using the packed mode (default build script). It output 2 bundles:

If I try to just upload the main bundle to my CDN and load that, the Addressables system throws a dependency exception looking for the the unitybuiltinshaders bundle.

Ideally I would like to remove the main bundle’s dependency on a separate unitybuiltinshaders bundle. What would be the best way to go about this? Shouldn’t the built in shader already be included in the build and not be needed as a separate bundle? If not, could it simply be included inside the main asset’s bundle?
Thanks!

EDIT: Using Unity 2019.1.14 and Addressables 1.8.3

I seem to have found the answer. I had to uncheck the “Include Resources Folders” toggle for the “Built In Data” group (see attached screenshot). Now when I rebuild only my single, expected bundle is created.

5903120--630041--image (3).png

I still get an InternalId and Key in the resulting catalog.
Something like:

"{UnityEngine.AddressableAssets.Addressables.RuntimePath}/Android/defaultlocalgroup_unitybuiltinshaders_9a6a042faae479a7c7d3c0c5bf797553.bundle"

Since this bundle doesn’t get built, where is it pointing? Or would there be a way to strip it out?

I’m running into this now as well.It seems if I delete the Default Local Group then the builtinshader dependency gets added back to my Test Asset group.
Reviewing the documentation again, if a group (Default Local Group in this case) is set to use the LocalLoadPath then it will be copied to StreamingAssets at application build time.

I tried moving the builtinshader.bundle from Library/com.unity.addressables/Android/Android into Assets/StreamingAssets, but had no luck. I get this exception:

I’m using play mode script “Use Existing Build” so I can test functionality with my CDN. I have three asset groups (Built In Data, Default Local Group(empty), Test Asset Group(single prefab)). It seems to me that this builtinshader.bundle shouldn’t be so hard to handle as it should be using the LocalLoadPath which is set to use the default Asset Bundle provider etc.

@boatnik Did you ever figure this out? :slight_smile:

I did not and moved on from trying to use Addressables for that project unfortunately.

Hi all this is by design. The default Unity shaders are stored in the built in shader bundle rather than your player data. This is due to how dependencies are calculated during the build.
https://docs.unity3d.com/Packages/com.unity.addressables@1.20/manual/BuildArtifacts.html#shared-assetbundles

The size of default_unitybuiltinshaders_[GUID].bundle is 132 mb.
This bundle (unlike other bundles) is going to .apk
Unity near empty build is 30-50 mb.
The less build possible to have is 180+ mb.
Google Play limitation is 150 mb for .apk.

Any idea?
Can you suggest any workaround or solution how to download remote default_unitybuiltinshaders_[GUID].bundle?
On any other way to be within 150 mb build?
Thank you for reply.