UE4.9 release + VS 2015 (gen.project.files with ‘-2015’ option) = some build errors + linker errors.
I’ve fixed the following build errors:
- macro IS_POD __is_pod(T) - c4647 behaviour changed. I replaced __is_pod(T) → std::is_pod<< T >>::value in file 4.9\Engine\Source\Runtime\Core\Public\Templates\UnrealTypeTraits.h
- warning threated as error was removed from pragma in Engine\Source\Runtime\Core\Public\Windows\WindowsPlatformCompilerSetup.h. There were some errors pointing to standard locale header or smth similar. Error was like 'printf_s(name) should be used as printf_s("%s", name)". c4774
- Some c4458 declaration of ‘X’ hides class member errors
See build log below.
Is it UE linker issues with VS2015 or my fault?
1>------ Build started: Project: UE4, Configuration: BuiltWithUnrealBuildTool Win32 ------
2>------ Build started: Project: Polygon4, Configuration: Development_Editor x64 ------
2> Parsing headers for Polygon4Editor
2> Running UnrealHeaderTool "H:\Games\Epic Games\Projects\Polygon4\Polygon4.uproject" "H:\Games\Epic Games\Projects\Polygon4\Intermediate\Build\Win64\Polygon4Editor\Development\UnrealHeaderTool.manifest" -LogCmds="loginit warning, logexit warning, logdatabase error" -rocket -installed
2> Reflection code generated for Polygon4Editor in 12,4748387 seconds
2> Performing 4 actions (4 in parallel)
2> Polygon4GameMode.cpp
2> Polygon4.generated.cpp
2> Glider.cpp
2> [4/4] Link UE4Editor-Polygon4.dll
2> Creating library H:\Games\Epic Games\Projects\Polygon4\Intermediate/Build/Win64\UE4Editor\Development\UE4Editor-Polygon4.lib and object H:\Games\Epic Games\Projects\Polygon4\Intermediate/Build/Win64\UE4Editor\Development\UE4Editor-Polygon4.exp
2>MenuGameMode.cpp.obj : error LNK2001: unresolved external symbol "public: virtual bool __cdecl AGameMode::SetPause(class APlayerController *,class TBaseDelegate<bool>)" (?SetPause@AGameMode@@UEAA_NPEAVAPlayerController@@V?$TBaseDelegate@_N$$V@@@Z)
2>Polygon4GameMode.cpp.obj : error LNK2001: unresolved external symbol "public: virtual bool __cdecl AGameMode::SetPause(class APlayerController *,class TBaseDelegate<bool>)" (?SetPause@AGameMode@@UEAA_NPEAVAPlayerController@@V?$TBaseDelegate@_N$$V@@@Z)
2>Polygon4.generated.cpp.obj : error LNK2001: unresolved external symbol "public: virtual bool __cdecl AGameMode::SetPause(class APlayerController *,class TBaseDelegate<bool>)" (?SetPause@AGameMode@@UEAA_NPEAVAPlayerController@@V?$TBaseDelegate@_N$$V@@@Z)
2>Polygon4.cpp.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: static class TBaseDelegate<class UObjectBase * * *> & __cdecl FCoreDelegates::GetObjectArrayForDebugVisualizersDelegate(void)" (__imp_?GetObjectArrayForDebugVisualizersDelegate@FCoreDelegates@@SAAEAV?$TBaseDelegate@PEAPEAPEAVUObjectBase@@$$V@@XZ) referenced in function "void __cdecl `dynamic initializer for 'GObjectArrayForDebugVisualizers''(void)" (??__EGObjectArrayForDebugVisualizers@@YAXXZ)
2>Polygon4.cpp.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: static class TBaseDelegate<int * * *> & __cdecl FCoreDelegates::GetSerialNumberBlocksForDebugVisualizersDelegate(void)" (__imp_?GetSerialNumberBlocksForDebugVisualizersDelegate@FCoreDelegates@@SAAEAV?$TBaseDelegate@PEAPEAPEAH$$V@@XZ) referenced in function "void __cdecl `dynamic initializer for 'GSerialNumberBlocksForDebugVisualizers''(void)" (??__EGSerialNumberBlocksForDebugVisualizers@@YAXXZ)
2>MainMenu.cpp.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: __cdecl FKey::FKey(struct FKey &&)" (__imp_??0FKey@@QEAA@$$QEAU0@@Z) referenced in function "public: __cdecl FReply::FReply(class FReply &&)" (??0FReply@@QEAA@$$QEAV0@@Z)
2>PauseMenu.cpp.obj : error LNK2001: unresolved external symbol "__declspec(dllimport) public: __cdecl FKey::FKey(struct FKey &&)" (__imp_??0FKey@@QEAA@$$QEAU0@@Z)
2>ModListView.cpp.obj : error LNK2001: unresolved external symbol "__declspec(dllimport) public: __cdecl FKey::FKey(struct FKey &&)" (__imp_??0FKey@@QEAA@$$QEAU0@@Z)
2>MainMenu.cpp.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: __cdecl FSlateColor::FSlateColor(struct FSlateColor &&)" (__imp_??0FSlateColor@@QEAA@$$QEAU0@@Z) referenced in function "public: struct FSlateColor __cdecl TMemberFunctionCaller<class STableRow<class TSharedPtr<class polygon4::Modification,0> >,struct FSlateColor (__cdecl STableRow<class TSharedPtr<class polygon4::Modification,0> >::*)(void)const >::operator()<>(void)" (??$?R$$V@?$TMemberFunctionCaller@V?$STableRow@V?$TSharedPtr@VModification@polygon4@@$0A@@@@@P81@EBA?AUFSlateColor@@XZ@@QEAA?AUFSlateColor@@XZ)
2>ModListView.cpp.obj : error LNK2001: unresolved external symbol "__declspec(dllimport) public: __cdecl FSlateColor::FSlateColor(struct FSlateColor &&)" (__imp_??0FSlateColor@@QEAA@$$QEAU0@@Z)
2>MainMenu.cpp.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: struct FSlateColor & __cdecl FSlateColor::operator=(struct FSlateColor &&)" (__imp_??4FSlateColor@@QEAAAEAU0@$$QEAU0@@Z) referenced in function "public: class TAttribute<struct FSlateColor> & __cdecl TAttribute<struct FSlateColor>::operator=(class TAttribute<struct FSlateColor> &&)" (??4?$TAttribute@UFSlateColor@@@@QEAAAEAV0@$$QEAV0@@Z)
2>ModListView.cpp.obj : error LNK2001: unresolved external symbol "__declspec(dllimport) public: struct FSlateColor & __cdecl FSlateColor::operator=(struct FSlateColor &&)" (__imp_??4FSlateColor@@QEAAAEAU0@$$QEAU0@@Z)
2>H:\Games\Epic Games\Projects\Polygon4\Binaries\Win64\UE4Editor-Polygon4.dll : fatal error LNK1120: 6 unresolved externals
2> -------- End Detailed Actions Stats -----------------------------------------------------------
2>ERROR : UBT error : Failed to produce item: H:\Games\Epic Games\Projects\Polygon4\Binaries\Win64\UE4Editor-Polygon4.dll
2> Total build time: 19,75 seconds
2>C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V140\Microsoft.MakeFile.Targets(37,5): error MSB3073: The command ""H:\Games\Epic Games\4.9\Engine\Build\BatchFiles\Build.bat" Polygon4Editor Win64 Development "H:\Games\Epic Games\Projects\Polygon4\Polygon4.uproject" -rocket -2015" exited with code -1.
========== Build: 1 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========