Since using 2018.2.0b4 when building unity compiles absolutely every shader/variant in the project. A majority of them are unused. For example import an asset from asset store. Don’t use any of the shaders incuded in the package. They will still compile on build. Therefore if you have 100 shaders in the project but are only using 1, 99 useless shaders are being compiled, killing build time completely. A project which takes 2 minutes to build on 2017 takes 4hrs plus on the latest beta
Unity Technologies recently published this blog-post:
Not sure if everybody must now follow the new workflow they describe in the blog-post to get acceptable build times, or if you’re actually experiencing a bug.
I would submit a bug-report following this guide though:
Thanks for that info Peter77 I will look into that, looks like I missed that blog
Hi,
This does in fact sound like a bug, especially if it was fine in 2017, if you could submit a bug report with any info you can give us that would be great.
As for the blog post about shader stripping, this is just for additional control over shader variant handling, and this kicks in before the shader compiler receives the shaders and decides what to and what not to compile, this feature was essential to making Scriptable Render Pipelines faster to build as the shader variants were much higher than in the Legacy pipeline.
Hi,
is this problem fixed? I am using 2018.1.7f1 and facing the same problem.
Hello,
2018.2.16f Same problem! Please tell us a solution! It’s frustrating
2019.1.0a13 still same problem.
If you’re able to reproduce this issue, could you please submit a bug-report as described in this document:
Posting “same problem” is most likely not helping to resolve the issue.
just follow this instructions:
https://blogs.unity3d.com/ru/2018/05/14/stripping-scriptable-shader-variants/
it’s help me to redue build time from 40 min to 5 min
Use the scriptable render pipe and the issue is resolved
Are we talking workarounds or actually fixing what @Andre_Mcgrail considered being a bug until todays Unity versions?