Download

found problem while packaging my project with unreal marketplace's openxr plugin

Hello there, I’m trying to building a hololens 2 app with openxr plugin in order to try out QR tracking function, but met problem while package project for hololens.
My project could normally package with out openxr plugin.
I haved tried to install lasted winrt nuget in vs2019 , but problem still. I’m new to C++ programming and hope you can help me solve this problem. Thx~~!

console logs here:
UATHelper: Packaging (HoloLens): Setting up ProjectParams for F:\ue4\workspace\MsftOpenXRGame\MsftOpenXRGame.uproject
UATHelper: Packaging (HoloLens): ********** BUILD COMMAND STARTED **********
UATHelper: Packaging (HoloLens): Running: F:\ue4\UE_4.26\Engine\Binaries\DotNET\UnrealBuildTool.exe MsftOpenXRGame HoloLens Development -Project=F:\ue4\workspace\MsftOpenXRGame\MsftOpenXRGame.uproject F:\ue4\workspace\MsftOpenXRGame\MsftOpenXRGame.uproject -NoUBTMakefiles -remoteini=“F:\ue4\workspace\MsftOpenXRGame” -Architecture=arm64 -Manifest=F:\ue4\wor
kspace\MsftOpenXRGame\Intermediate\Build\Manifest.xml -NoHotReload -log=“C:\Users\Hawk\AppData\Roaming\Unreal Engine\AutomationTool\Logs\F+ue4+UE_4.26\UBT-MsftOpenXRGame-HoloLens-Development.txt”
UATHelper: Packaging (HoloLens): Using ARM64 architecture for deploying to HoloLens device
UATHelper: Packaging (HoloLens): Building using Windows SDK version 10.0.19041.0 for HoloLens
UATHelper: Packaging (HoloLens): Your Windows SDK version (10.0.19041.0) for HoloLens is newer than the highest tested with this version of UBT (10.0.18362.2147483647). This is probably fine, but if you encounter issues consider using an earlier SDK.
LogSlate: Took 0.000250 seconds to synchronously load lazily loaded font ‘…/…/…/Engine/Content/Slate/Fonts/DroidSansMono.ttf’ (77K)
LogSlate: Took 0.001146 seconds to synchronously load lazily loaded font ‘…/…/…/Engine/Content/Slate/Fonts/DroidSansFallback.ttf’ (3848K)
UATHelper: Packaging (HoloLens): Writing manifest to F:\ue4\workspace\MsftOpenXRGame\Intermediate\Build\Manifest.xml
UATHelper: Packaging (HoloLens): Building MsftOpenXRGame…
UATHelper: Packaging (HoloLens): Building 2 actions with 12 processes…
UATHelper: Packaging (HoloLens): [1/2] MsftOpenXRGamearm64.exe
UATHelper: Packaging (HoloLens): MixedRealityInteropHoloLens.lib(AzureSpatialAnchors.obj) : error LNK2038: mismatch detected for ‘C++/WinRT version’: value ‘2.0.201113.7’ doesn’t match value ‘2.0.201217.4’ in PCH.MicrosoftOpenXR.h.obj
UATHelper: Packaging (HoloLens): MixedRealityInteropHoloLens.lib(MixedRealityInterop.obj) : error LNK2038: mismatch detected for ‘C++/WinRT version’: value ‘2.0.201113.7’ doesn’t match value ‘2.0.201217.4’ in PCH.MicrosoftOpenXR.h.obj
UATHelper: Packaging (HoloLens): MixedRealityInteropHoloLens.lib(CameraImageCapture.obj) : error LNK2038: mismatch detected for ‘C++/WinRT version’: value ‘2.0.201113.7’ doesn’t match value ‘2.0.201217.4’ in PCH.MicrosoftOpenXR.h.obj
UATHelper: Packaging (HoloLens): MixedRealityInteropHoloLens.lib(SpatialAnchorHelper.obj) : error LNK2038: mismatch detected for ‘C++/WinRT version’: value ‘2.0.201113.7’ doesn’t match value ‘2.0.201217.4’ in PCH.MicrosoftOpenXR.h.obj
UATHelper: Packaging (HoloLens): MixedRealityInteropHoloLens.lib(HandMeshObserver.obj) : error LNK2038: mismatch detected for ‘C++/WinRT version’: value ‘2.0.201113.7’ doesn’t match value ‘2.0.201217.4’ in PCH.MicrosoftOpenXR.h.obj
UATHelper: Packaging (HoloLens): MixedRealityInteropHoloLens.lib(MeshObserver.obj) : error LNK2038: mismatch detected for ‘C++/WinRT version’: value ‘2.0.201113.7’ doesn’t match value ‘2.0.201217.4’ in PCH.MicrosoftOpenXR.h.obj
UATHelper: Packaging (HoloLens): MixedRealityInteropHoloLens.lib(SceneUnderstandingObserver.obj) : error LNK2038: mismatch detected for ‘C++/WinRT version’: value ‘2.0.201113.7’ doesn’t match value ‘2.0.201217.4’ in PCH.MicrosoftOpenXR.h.obj
UATHelper: Packaging (HoloLens): MixedRealityInteropHoloLens.lib(QRCodeObserver.obj) : error LNK2038: mismatch detected for ‘C++/WinRT version’: value ‘2.0.201113.7’ doesn’t match value ‘2.0.201217.4’ in PCH.MicrosoftOpenXR.h.obj
UATHelper: Packaging (HoloLens): Creating library F:\ue4\workspace\MsftOpenXRGame\Binaries\HoloLens\MsftOpenXRGamearm64.lib and object F:\ue4\workspace\MsftOpenXRGame\Binaries\HoloLens\MsftOpenXRGamearm64.exp
UATHelper: Packaging (HoloLens): F:\ue4\workspace\MsftOpenXRGame\Binaries\HoloLens\MsftOpenXRGamearm64.exe : fatal error LNK1319: 8 mismatches detected
UATHelper: Packaging (HoloLens): Took 18.1333085s to run UnrealBuildTool.exe, ExitCode=6
UATHelper: Packaging (HoloLens): UnrealBuildTool failed. See log for more details. (C:\Users\Hawk\AppData\Roaming\Unreal Engine\AutomationTool\Logs\F+ue4+UE_4.26\UBT-MsftOpenXRGame-HoloLens-Development.txt)
UATHelper: Packaging (HoloLens): AutomationTool exiting with ExitCode=6 (6)
UATHelper: Packaging (HoloLens): BUILD FAILED

And then I tried to alter the packages.config in NuGetModule folder and rebuild solution in order to fix the version problem ,
if I turn off the WindowsMixedReality pulgin , package for hololens successed, but do not work well on hololens , able to start up but not work normually.
And when I package for hololens with WindowsMixedReality pulgin on, another exception comes.
console logs here:

UATHelper: Packaging (HoloLens): LogHttp: Display: Http module shutting down, but needs to wait on 1 outstanding Http requests:
UATHelper: Packaging (HoloLens): LogHttp: Display: verb=[GET] url=[https://169.254.232.222:443/] refs=[1] status=Processing
UATHelper: Packaging (HoloLens): LogHttp: Display: cleaning up 1 outstanding Http requests.
UATHelper: Packaging (HoloLens): LogContentStreaming: Display: There are 1 unreleased StreamingManagers
UATHelper: Packaging (HoloLens): Took 13.816607s to run UE4Editor-Cmd.exe, ExitCode=0
UATHelper: Packaging (HoloLens): ********** COOK COMMAND COMPLETED **********
UATHelper: Packaging (HoloLens): ********** STAGE COMMAND STARTED **********
UATHelper: Packaging (HoloLens): Creating UE4CommandLine.txt
UATHelper: Packaging (HoloLens): Creating Staging Manifest…
UATHelper: Packaging (HoloLens): Excluding config file F:\ue4\UE_4.26\Engine\Config\BaseEditor.ini
UATHelper: Packaging (HoloLens): Excluding config file F:\ue4\UE_4.26\Engine\Config\BaseEditorKeyBindings.ini
UATHelper: Packaging (HoloLens): Excluding config file F:\ue4\UE_4.26\Engine\Config\BaseEditorPerProjectUserSettings.ini
UATHelper: Packaging (HoloLens): Excluding config file F:\ue4\UE_4.26\Engine\Config\BaseEditorSettings.ini
UATHelper: Packaging (HoloLens): Excluding config file F:\ue4\UE_4.26\Engine\Config\BaseLightmass.ini
UATHelper: Packaging (HoloLens): Excluding config file F:\ue4\UE_4.26\Engine\Config\BasePakFileRules.ini
UATHelper: Packaging (HoloLens): Excluding config file F:\ue4\UE_4.26\Engine\Config\Localization\Category.ini
UATHelper: Packaging (HoloLens): Excluding config file F:\ue4\UE_4.26\Engine\Config\Localization\Editor.ini
UATHelper: Packaging (HoloLens): Excluding config file F:\ue4\UE_4.26\Engine\Config\Localization\EditorTutorials.ini
UATHelper: Packaging (HoloLens): Excluding config file F:\ue4\UE_4.26\Engine\Config\Localization\Engine.ini
UATHelper: Packaging (HoloLens): Excluding config file F:\ue4\UE_4.26\Engine\Config\Localization\Keywords.ini
UATHelper: Packaging (HoloLens): Excluding config file F:\ue4\UE_4.26\Engine\Config\Localization\PortableObjectExport.ini
UATHelper: Packaging (HoloLens): Excluding config file F:\ue4\UE_4.26\Engine\Config\Localization\PortableObjectImport.ini
UATHelper: Packaging (HoloLens): Excluding config file F:\ue4\UE_4.26\Engine\Config\Localization\PropertyNames.ini
UATHelper: Packaging (HoloLens): Excluding config file F:\ue4\UE_4.26\Engine\Config\Localization\RepairData.ini
UATHelper: Packaging (HoloLens): Excluding config file F:\ue4\UE_4.26\Engine\Config\Localization\ToolTips.ini
UATHelper: Packaging (HoloLens): Excluding config file F:\ue4\UE_4.26\Engine\Config\Localization\WordCount.ini
UATHelper: Packaging (HoloLens): Excluding config file F:\ue4\workspace\MsftOpenXRGame\Config\DefaultEditor.ini
UATHelper: Packaging (HoloLens): Cleaning Stage Directory: F:\ue4\workspace\MsftOpenXRGame\Saved\StagedBuilds\HoloLens
UATHelper: Packaging (HoloLens): Creating pak using staging manifest.
UATHelper: Packaging (HoloLens): Executing 1 UnrealPak command…
UATHelper: Packaging (HoloLens): Waiting for child processes to complete (1/1)
UATHelper: Packaging (HoloLens): Output from: F:\ue4\workspace\MsftOpenXRGame\MsftOpenXRGame.uproject F:\ue4\workspace\MsftOpenXRGame\Saved\StagedBuilds\HoloLens\MsftOpenXRGame\Content\Paks\MsftOpenXRGame-HoloLens.pak -create=“C:\Users\Hawk5\AppData\Roaming\Unreal Engine\AutomationTool\Logs\F+ue4+UE_4.26\PakList_MsftOpenXRGame-HoloLens.txt” -cryptokeys=F:\ue
4\workspace\MsftOpenXRGame\Saved\Cooked\HoloLens\MsftOpenXRGame\Metadata\Crypto.json -order=F:\ue4\workspace\MsftOpenXRGame\Build\HoloLens\FileOpenOrder\CookerOpenOrder.log -platform=HoloLens -multiprocess -abslog=“C:\Users\Hawk5\AppData\Roaming\Unreal Engine\AutomationTool\Logs\F+ue4+UE_4.26\UnrealPak-MsftOpenXRGame-HoloLens-2021.03.09-18.37.06.txt”
UATHelper: Packaging (HoloLens): LogPakFile: Display: Parsing crypto keys from a crypto key cache file
UATHelper: Packaging (HoloLens): LogPakFile: Display: Loading response file C:\Users\Hawk5\AppData\Roaming\Unreal Engine\AutomationTool\Logs\F+ue4+UE_4.26\PakList_MsftOpenXRGame-HoloLens.txt
UATHelper: Packaging (HoloLens): LogPakFile: Display: Added 1405 entries to add to pak file.
UATHelper: Packaging (HoloLens): LogPakFile: Display: Loading pak order file F:\ue4\workspace\MsftOpenXRGame\Build\HoloLens\FileOpenOrder\CookerOpenOrder.log…
UATHelper: Packaging (HoloLens): LogPakFile: Display: Finished loading pak order file F:\ue4\workspace\MsftOpenXRGame\Build\HoloLens\FileOpenOrder\CookerOpenOrder.log.
UATHelper: Packaging (HoloLens): LogPakFile: Display: Collecting files to add to pak file…
UATHelper: Packaging (HoloLens): LogPakFile: Display: Collected 1405 files in 0.01s.
UATHelper: Packaging (HoloLens): LogPakFile: Display: Creating pak F:\ue4\workspace\MsftOpenXRGame\Saved\StagedBuilds\HoloLens\MsftOpenXRGame\Content\Paks\MsftOpenXRGame-HoloLens.pak.
UATHelper: Packaging (HoloLens): LogDerivedDataCache: Display: Pak cache opened for reading …/…/…/Engine/DerivedDataCache/Compressed.ddp.
UATHelper: Packaging (HoloLens): LogDerivedDataCache: Display: Performance to C:/Users/Hawk5/AppData/Local/UnrealEngine/Common/DerivedDataCache: Latency=0.00ms. RandomReadSpeed=999.00MBs, RandomWriteSpeed=999.00MBs. Assigned SpeedClass ‘Local’
UATHelper: Packaging (HoloLens): LogPakFile: Display: Added 1405 files, 83844894 bytes total, time 0.48s.
UATHelper: Packaging (HoloLens): LogPakFile: Display: PrimaryIndex size: 16974 bytes
UATHelper: Packaging (HoloLens): LogPakFile: Display: PathHashIndex size: 36102 bytes
UATHelper: Packaging (HoloLens): LogPakFile: Display: FullDirectoryIndex size: 47175 bytes
UATHelper: Packaging (HoloLens): LogPakFile: Display: Encryption - DISABLED
UATHelper: Packaging (HoloLens): LogPakFile: Display: Unreal pak executed in 0.516516 seconds
UATHelper: Packaging (HoloLens): UnrealPak terminated with exit code 0
UATHelper: Packaging (HoloLens): Copying NonUFSFiles to staging directory: F:\ue4\workspace\MsftOpenXRGame\Saved\StagedBuilds\HoloLens
UATHelper: Packaging (HoloLens): ********** STAGE COMMAND COMPLETED **********
UATHelper: Packaging (HoloLens): ********** PACKAGE COMMAND STARTED **********
UATHelper: Packaging (HoloLens): bStartInVR = True
UATHelper: Packaging (HoloLens): Writing cmd line to: F:\ue4\workspace\MsftOpenXRGame\Saved\StagedBuilds\HoloLens\UE4CommandLine.txt
UATHelper: Packaging (HoloLens): Creating UE4CommandLine.txt
UATHelper: Packaging (HoloLens): Running: C:\Program Files (x86)\Windows Kits\10\bin\10.0.19041.0\x64\makeappx.exe pack /o /f “F:\ue4\workspace\MsftOpenXRGame\Intermediate\Deploy\arm64\MsftOpenXRGame_HoloLens_Development_arm64.pkgmap” /p “F:\ue4\workspace\MsftOpenXRGame\Saved\StagedBuilds\HoloLens\MsftOpenXRGame_HoloLens_Development_arm64.appx”
UATHelper: Packaging (HoloLens): Took 0.089001s to run makeappx.exe, ExitCode=1
UATHelper: Packaging (HoloLens): Command failed (Result:1): C:\Program Files (x86)\Windows Kits\10\bin\10.0.19041.0\x64\makeappx.exe pack /o /f “F:\ue4\workspace\MsftOpenXRGame\Intermediate\Deploy\arm64\MsftOpenXRGame_HoloLens_Development_arm64.pkgmap” /p “F:\ue4\workspace\MsftOpenXRGame\Saved\StagedBuilds\HoloLens\MsftOpenXRGame_HoloLens_Development_arm64.a
ppx”. See logfile for details: ‘makeappx-2021.03.09-18.37.08.txt’
UATHelper: Packaging (HoloLens): AutomationTool exiting with ExitCode=1 (Error_Unknown)
UATHelper: Packaging (HoloLens): BUILD FAILED

You must disable Windows Mixed Reality plugin while packaging with OpenXR.