[5.4.1] Installed build : need clarification

Hello,

We are a mid-sized studio and starting to work with Unreal for our next project.

As it will ship on console, we are trying to make our own Installed build version of the Editor/Engine, and distribute internally.

We have sucessfully managed to create that installed build by following the documentation, but we now face multiples issues we don’t really understand (probably because we are novices with the Unreal Environment):

  1. The Installed build size is large (350GB). We can cut down that size by removing .pdbs and intermediate folders. We though intermediate folder only contained binaries that could be rebuilt, just like the project intermediate folder, but it seems that it also contains files that aren’t rebuilt automatically and will prevent the editor from working properly (for example, we can’t generate game packages anymore). So, Is it correct that we shouldn’t touch the generated intermediate folder ? Any advice to make it lighter ?

  2. We are facing issues with a lot of TargetRules.GlobalDefinitions. We’re not sure of what is happening, as our project run fine with the Installed build downloaded from the epic Launcher, but will not open with our own-build one. Here is an example of the issue we get :

Unable to instantiate instance of 'EventLoopUnitTestsTarget' object type from compiled assembly 'UE5ProgramRules'.  Unreal Build Tool creates an instance of your module's 'Rules' object in order to find out about your module's requirements.  The CLR exception details may provide more information: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation.

 ---> System.MissingFieldException: Field not found: 'UnrealBuildTool.TargetRules.GlobalDefinitions'.

   at EventLoopUnitTestsTarget..ctor(TargetInfo Target)

   --- End of inner exception stack trace ---

   at System.RuntimeMethodHandle.InvokeMethod(Object target, Span`1& arguments, Signature sig, Boolean constructor, Boolean wrapExceptions)

   at System.Reflection.RuntimeConstructorInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)

   at System.Reflection.MethodBase.Invoke(Object obj, Object[] parameters)

   at UnrealBuildTool.TargetRules.Create(Type rulesType, TargetInfo targetInfo, FileReference baseFile, FileReference platformFile, IEnumerable`1 targetFiles, Nullable`1 defaultBuildSettings, ILogger logger) in D:\Windows\Engine\Source\Programs\UnrealBuildTool\Configuration\TargetRules.cs:line 2838

Is there something else we need to build on top of the Installed Build ? Like, the UAT, UBT, or another one ?

  1. It seems that replacing the Engine\Intermediate\Build folder ( specially the BuildRules and BuildRulesProjects) with the one included with the launcher Installed build fix most of our issues (including the one above). Why is that ? Why didn’t our own Installed build generated these files properly ?

Thanks, i know some of these questions have already been asked (the installed build size for example), but i would love to have a chat with people that worked around these issues !