Xcode build errors: Lambda capture...not used
Recently I started getting errors about metal shaders not being found in Unreal due to Xcode being out of date. I recently upgraded to High Sierra and the latest Xcode and now i'm unable to open my .uproject file.
I tried deleting binaries, intermediate, saved and the workspace file, then regenerating the workspace file. Now when I try to build from Xcode I get the following build errors:
Lambda capture 'LocalMapLayoutForCapture' is not used (UnrealType.h) (this error appears twice) Lamdba capture 'LocalSetLayoutForCapture' is not used (UnrealType.h)
I'm not sure how to deal with these errors - I've never seen them before. I was tempted to go and delete them from the UnrealType.h file but don't want to mess anything up within the engine code.
Using UE4.18.3 and Xcode 9.3.The project was a C++ project and was compiling just fine until it started saying Xcode was the wrong version and giving me the metal shader errors.
Anyone know how to get around this? :) Thanks
asked Apr 15 '18 at 04:52 PM in C++ Programming
You need to change
Find the following line:
and below add
then you have to rebuild UnrealBuildTool by
When that's complete (with a bunch of other unused warnings) you can head back and re-run Build.sh which should complete without errors.
answered May 23 '18 at 11:26 AM
I also run into this errors generated from
As an alternative you could also consider to modify UEBuildTool in such a way that the compiler handles unused lambda captures only as warnings, what shouldn't be a big issue anyways as they just should be optimised out.
answered Apr 16 '18 at 04:06 PM
Follow this question
Once you sign in you will be able to subscribe for any updates here