UBT ERROR: Failed to produce item, Unrealtype.h
I have a problem with Android packaging, The packaging works fine without plugin, but the plugin makes lots of errors ( I was able to package it before I reinstalled Windows). Using VS2015, CodeWorks1R7 (tried with 1R6-same problem, Windows SDK 8.1) All the errors are about UNREALTYPE.H Example of error:
In file included from Runtime/CoreUObject/Public/UObject/ScriptMacros.h:12: Runtime/CoreUObject/Public\UObject/UnrealType.h(3277,37): error: lambda capture 'LocalMapLayoutForCapture' is not used [-Werror,-Wunused-lambda-capture] [LocalKeyPropForCapture, KeyPtr, LocalMapLayoutForCapture](void* NewElementKey) Runtime/CoreUObject/Public\UObject/UnrealType.h(3290,41): error: lambda capture 'LocalMapLayoutForCapture' is not used [-Werror,-Wunused-lambda-capture] [LocalValuePropForCapture, ValuePtr, LocalMapLayoutForCapture](void* NewElementValue) Runtime/CoreUObject/Public\UObject/UnrealType.h(3786,47): error: lambda capture 'LocalSetLayoutForCapture' is not used [-Werror,-Wunused-lambda-capture] [LocalElementPropForCapture, ElementToAdd, LocalSetLayoutForCapture](void* NewElement)
full log attached
The solution will be next: Add next lines to the topmost header of your include hierarchy
Hopefully it'll solve. If u r getting the error still, complaining about YourProjectName.generated.cpp then u r screwed. Post here, and i will post a workaround, which is ugly, bad, but unfortunately the only way i found to pacify UHT(UnrealHeaderTool).
If u r not developing plugin, or can use Unreal locally, just go to UnrealType.h and fix the d@mn problem by commenting out the unused variables in the capture list. This will be right and gracious thing to do.
Follow this question
Once you sign in you will be able to subscribe for any updates here