Upgrading even a clean UE 5.1 project to UE 5.2 will make project packaging fail.

So we’ve discovered that migrating our project file (then tested with a clean project file) from UE 5.1 to UE 5.2 creates a library issue that causes packaging to fail.

The same errors are encountered when manually building the project via VS, though it doesn’t affect the ability to open the project in UE, work, and run it from editor/standalone/etc. It only affects the ability to actually package the product.

Since we tested with both our product, and then a clean third person template project and produced exactly the same errors and failure to package, I think it’s a bug in the dependencies between 5.1 and 5.2.

Has anyone else encountered this yet and found a solution?

(side note; ignore the OneDrive in the file directories, it’s not actually connected to OneDrive, that’s just the folder name).

1>[17/18] Link [x64] TWS-Win64-Shipping.exe
1>   Creating library C:\Users\amahv\OneDrive\Documents\Unreal Projects\TWS\Binaries\Win64\TWS-Win64-Shipping.lib and object C:\Users\amahv\OneDrive\Documents\Unreal Projects\TWS\Binaries\Win64\TWS-Win64-Shipping.exp
1>Module.Niagara.9_of_12.cpp.obj : error LNK2019: unresolved external symbol __std_init_once_link_alternate_names_and_abort referenced in function "void __cdecl std::call_once<class <lambda_545dfa6eb49ca362ef2cb3c500c8a6b0> >(struct std::once_flag &,class <lambda_545dfa6eb49ca362ef2cb3c500c8a6b0> &&)" (??$call_once@V<lambda_545dfa6eb49ca362ef2cb3c500c8a6b0>@@$$V@std@@YAXAEAUonce_flag@0@$$QEAV<lambda_545dfa6eb49ca362ef2cb3c500c8a6b0>@@@Z)
1>Module.Niagara.12_of_12.cpp.obj : error LNK2001: unresolved external symbol __std_init_once_link_alternate_names_and_abort
1>Module.GeometryAlgorithms.1_of_3.cpp.obj : error LNK2019: unresolved external symbol __std_find_trivial_4 referenced in function "int * __cdecl __std_find_trivial<int,char>(int *,int *,char)" (??$__std_find_trivial@HD@@YAPEAHPEAH0D@Z)
1>Module.GeometryAlgorithms.2_of_3.cpp.obj : error LNK2001: unresolved external symbol __std_find_trivial_4
1>C:\Users\amahv\OneDrive\Documents\Unreal Projects\TWS\Binaries\Win64\TWS-Win64-Shipping.exe : fatal error LNK1120: 2 unresolved externals
1>[18/18] WriteMetadata TWS-Win64-Shipping.target cancelled
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\MSBuild\Microsoft\VC\v160\Microsoft.MakeFile.Targets(45,5): error MSB3073: The command ""C:\Program Files\Epic Games\UE_5.2\Engine\Build\BatchFiles\Build.bat" TWS Win64 Shipping -Project="C:\Users\amahv\OneDrive\Documents\Unreal Projects\TWS\TWS.uproject" -WaitMutex -FromMsBuild" exited with code 6.
1>Done building project "TWS.vcxproj" -- FAILED.
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

I get the exact same errors on project packaging, this is a project upgraded to 5.2 from 4.26

UATHelper: Packaging (Windows): [2/3] Link [x64] BreakOut.exe
UATHelper: Packaging (Windows): Creating library T:\UnrealProjects- 5_2 -\BreakOut\Binaries\Win64\BreakOut.lib and object T:\UnrealProjects- 5_2 -\BreakOut\Binaries\Win64\BreakOut.exp
UATHelper: Packaging (Windows): Module.Niagara.9_of_12.cpp.obj : error LNK2019: unresolved external symbol __std_init_once_link_alternate_names_and_abort referenced in function “void __cdecl std::call_once<class <lambda_545dfa6eb49ca362ef2cb3c500c8a6b0> >(struct std::once_flag &,class <lambda_545dfa6eb49ca362ef2cb3c500c8a6b0> &&)” (??$call_once@V<lambda_545dfa6eb49ca362ef2cb3c500c8a6b0>@@$$V@std@@YAXAEAUonce_flag@0@$$QEAV<lambda_545dfa6eb49ca362ef2cb3c500c8a6b0>@@@Z)
UATHelper: Packaging (Windows): Module.Niagara.12_of_12.cpp.obj : error LNK2001: unresolved external symbol __std_init_once_link_alternate_names_and_abort
UATHelper: Packaging (Windows): Module.GeometryAlgorithms.1_of_3.cpp.obj : error LNK2019: unresolved external symbol __std_find_trivial_4 referenced in function “int * __cdecl __std_find_trivial<int,char>(int *,int *,char)” (??$__std_find_trivial@HD@@YAPEAHPEAH0D@Z)
UATHelper: Packaging (Windows): Module.GeometryAlgorithms.2_of_3.cpp.obj : error LNK2001: unresolved external symbol __std_find_trivial_4
UATHelper: Packaging (Windows): T:\UnrealProjects- 5_2 -\BreakOut\Binaries\Win64\BreakOut.exe : fatal error LNK1120: 2 unresolved externals
UATHelper: Packaging (Windows): [3/3] WriteMetadata BreakOut.target cancelled
UATHelper: Packaging (Windows): Took 30,3734995s to run dotnet.exe, ExitCode=6

And the solution was to change from VS2019 to VS2022

2 Likes

Thank you for this. I spent 2 days banging my head against the desk trying to find a solution, I’m on VS2019. Gonna install and test on VS2022. Project compiles and runs in editor just fine, it’s just the packaging bit that fails.

Edit: Yes, this is the way.

Sorry for the late reply. We figured this out, and forgot about the thread so we never came back here. Big shout out to Alban from Unreal for the help.

Hi all,

I’m using VS 2022. Nevertheless I’m experiencing similar problems when creating a Windows build for a new VR template project:

LogPlayLevel: UAT: Building MyProject2...
LogPlayLevel: UAT: Using Visual Studio 2022 14.32.31329 toolchain (C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.32.31326) and Windows 10.0.19041.0 SDK (C:\Program Files (x86)\Windows Kits\10).
LogPlayLevel: UAT: [Upgrade]
LogPlayLevel: UAT: [Upgrade] Using backward-compatible include order. The latest version of UE has changed the order of includes, which may require code changes. The current setting is:
LogPlayLevel: UAT: [Upgrade]     IncludeOrderVersion = EngineIncludeOrderVersion.Unreal5_0
LogPlayLevel: UAT: [Upgrade] Suppress this message by setting 'IncludeOrderVersion = EngineIncludeOrderVersion.Unreal5_2;' in MyProject2.Target.cs.
LogPlayLevel: UAT: [Upgrade] Alternatively you can set this to 'EngineIncludeOrderVersion.Latest' to always use the latest include order. This will potentially cause compile errors when integrating new versions of the engine.
LogPlayLevel: UAT: [Upgrade]
LogPlayLevel: UAT: Determining max actions to execute in parallel (6 physical cores, 12 logical cores)
LogPlayLevel: UAT:   Executing up to 6 processes, one per physical core
LogPlayLevel: UAT:   Requested 1.5 GB free memory per action, 6.33 GB available: limiting max parallel actions to 4
LogPlayLevel: UAT: Building 2 actions with 2 processes...
LogPlayLevel: UAT: [1/2] Link [x64] MyProject2.exe
LogPlayLevel: UAT:    Creating library C:\Users\info\Documents\Unreal Projects\MyProject2\Binaries\Win64\MyProject2.lib and object C:\Users\info\Documents\Unreal Projects\MyProject2\Binaries\Win64\MyProject2.exp
LogPlayLevel: UAT: Module.GeometryAlgorithms.1_of_3.cpp.obj : error LNK2019: unresolved external symbol __std_find_trivial_4 referenced in function "int * __cdecl __std_find_trivial<int,char>(int *,int *,char)" (??$__std_find_trivial@HD@@YAPEAHPEAH0D@Z)
LogPlayLevel: UAT: Module.GeometryAlgorithms.2_of_3.cpp.obj : error LNK2001: unresolved external symbol __std_find_trivial_4
LogPlayLevel: UAT: C:\Users\info\Documents\Unreal Projects\MyProject2\Binaries\Win64\MyProject2.exe : fatal error LNK1120: 1 unresolved externals
LogPlayLevel: UAT: [2/2] WriteMetadata MyProject2.target cancelled
LogPlayLevel: UAT: Took 18.956860199999998s to run dotnet.exe, ExitCode=6
LogPlayLevel: UAT: UnrealBuildTool failed. See log for more details. (C:\Users\info\AppData\Roaming\Unreal Engine\AutomationTool\Logs\C+Program+Files+Epic+Games+UE_5.2\UBT-MyProject2-Win64-Development.txt)
LogPlayLevel: UAT: AutomationTool executed for 0h 0m 23s
LogPlayLevel: UAT: AutomationTool exiting with ExitCode=6 (6)
LogPlayLevel: Completed Launch On Stage: Build Task, Time: 18.539217
LogPlayLevel: UAT: BUILD FAILED
PackagingResults: Error: Launch failed! Unknown Error