System.Private.CoreApp.dll not found during NET Native UWP build

167 Views Asked by At

I am trying to build geewallet (frontend branch) with UWP and .NET Native.

During build, VS2019 complains:

ILT0005: 'C:\Program Files (x86)\Microsoft SDKs\UWPNuGetPackages\runtime.win10-x86.microsoft.net.native.compiler\2.2.7-rel-27913-00\tools\x86\ilc\ilc.exe --gatekeeper @"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\intermediate\gkargs.rsp"' returned exit code 1

So I tried executing that command in a PowerShell to see the error message:

PS C:\Users\janus> & 'C:\Program Files (x86)\Microsoft SDKs\UWPNuGetPackages\runtime.win10-x86.microsoft.net.native.compiler\2.2.7-rel-27913-00\tools\x86\ilc\ilc.exe' --gatekeeper C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\intermediate\gkargs.rsp
Microsoft (R) .NET Native Gatekeeper Version 2.2.27913.00
Copyright (C) Microsoft Corporation.  All rights reserved.

Error: System.Private.CoreLib.dll was not found in any of the library paths ''. Please ensure
System.Private.CoreLib.dll is found within one of the directories specified with the /Lib command line switch.

But when I look in the rsp file it contains:

"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\BouncyCastle.Crypto.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\Common.Logging.Core.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\FSharp.Core.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\FSharp.Data.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\GWallet.Backend.NetStandard.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\GWallet.Frontend.XF.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\GWallet.Frontend.XF.UWP.exe"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\HtmlAgilityPack.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\JsonRpcSharp.Client.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\JsonRpcSharp.IpcClient.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\JsonRpcSharp.RpcClient.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\JsonRpcSharp.TcpClient.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\JsonRpcSharp.WebSocketClient.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\Microsoft.Extensions.Logging.Abstractions.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\Microsoft.Graphics.Canvas.winmd"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\NBitcoin.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\NBitcoin.Altcoins.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\Nethereum.ABI.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\Nethereum.Accounts.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\Nethereum.Contracts.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\Nethereum.Hex.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\Nethereum.KeyStore.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\Nethereum.RLP.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\Nethereum.RPC.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\Nethereum.Signer.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\Nethereum.StandardTokenEIP20.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\Nethereum.Util.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\Nethereum.Web3.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\Newtonsoft.Json.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\SharpRaven.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\SkiaSharp.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\SkiaSharp.Extended.Svg.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\Xamarin.Essentials.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\Xamarin.Forms.Core.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\Xamarin.Forms.Platform.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\Xamarin.Forms.Platform.UAP.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\Xamarin.Forms.Xaml.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\ZXing.Net.Mobile.Core.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\ZXing.Net.Mobile.Forms.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\ZXing.Net.Mobile.Forms.WindowsUniversal.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\zxing.portable.dll"
"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\ZXingNetMobile.dll"
/Lib:"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in"
/Lib:"C:\Program Files (x86)\Microsoft SDKs\UWPNuGetPackages\runtime.win10-x86.microsoft.net.native.compiler\2.2.7-rel-27913-00\tools\x86\ilc\lib\Private"
/WinMD:"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\WinMetadata\Microsoft.UI.Xaml.winmd"
/WinMD:"C:\Users\janus\source\repos\geewallet\src\GWallet.Frontend.XF.UWP\obj\x86\Debug\ilc\in\WinMetadata\Windows.winmd"
/VSTelemetrySessionSettings:"{"IsOptedIn":true,"HostName":"Dev14","AppInsightsInstrumentationKey":"f144292e-e3b2-4011-ac90-20e5c03fbce5","AsimovInstrumentationKey":"AIF-312cbd79-9dbb-4c48-a7da-3cc2a931cb70","AppId":1001,"UserId":"a8b38a81-e7fa-4be2-b507-3643586b22d7","Id":"3dcd9d77-cdc7-4ab5-8530-191810e0b2ec","ProcessStartTime":637181715992395788}"
/RdXmlPath:"C:\Program Files (x86)\Microsoft SDKs\UWPNuGetPackages\microsoft.net.native.compiler\2.2.7-rel-27913-00\tools\LibraryXML"
/RunOnlyPreDR

That file contains a lib saying "/Lib:" and ending in "Private". If I look in that directory, it contains "System.Private.CoreApp.dll".

So why I am getting this error message if the file was generated correctly? How can I fix the build?

0

There are 0 best solutions below