树洞中的狐狸
2022-03-12 16:51
采纳率: 100%
浏览 187
已结题

unity在导出项目时il2cpp报错

报错信息为

Failed running D:\unity\Builder\2020.1.2f1\Editor\Data\il2cpp/build/deploy/netcoreapp3.0/il2cpp.exe --convert-to-cpp --emit-null-checks --enable-array-bounds-check --dotnetprofile="unityaot" --compile-cpp --libil2cpp-static --platform="WindowsDesktop" --architecture="x64" --configuration="Release" --outputpath="D:\下载\RW-MonumentValley\RW-MonumentValley\MonumentValleyStart\Temp/StagingArea/Data\Native\GameAssembly.dll" --cachedirectory="D:\下载\RW-MonumentValley\RW-MonumentValley\MonumentValleyStart\Assets\..\Library/il2cpp_cache" --baselib-directory="D:/unity/Builder/2020.1.2f1/Editor/Data/PlaybackEngines/WindowsStandaloneSupport\Variations\win64_nondevelopment_il2cpp" --avoid-dynamic-library-copy --profiler-report --map-file-parser=D:/unity/Builder/2020.1.2f1/Editor/Data/Tools/MapFileParser/MapFileParser.exe --directory="D:/下载/RW-MonumentValley/RW-MonumentValley/MonumentValleyStart/Temp/StagingArea/Data/Managed" --generatedcppdir="D:/下载/RW-MonumentValley/RW-MonumentValley/MonumentValleyStart/Temp/StagingArea/Data/il2cppOutput" 

stdout:
Running il2cpp.exe in server GC mode.
Building GameAssembly.dll with MsvcDesktopToolChain
    Msvc Install Version: 15.0
    Msvc Install SDK Directory: C:\Program Files (x86)\Windows Kits\10
    Msvc Linker Path: D:\��������\vs\VC\Tools\MSVC\14.16.27023\bin\HostX64\x64\link.exe
    Msvc Compiler Path: D:\��������\vs\VC\Tools\MSVC\14.16.27023\bin\HostX64\x64\cl.exe

    Output directory: D:\����\RW-MonumentValley\RW-MonumentValley\MonumentValleyStart\Temp\StagingArea\Data\Native
    Cache directory: D:\����\RW-MonumentValley\RW-MonumentValley\MonumentValleyStart\Library\il2cpp_cache
il2cpp.exe didn't catch exception: Unity.IL2CPP.Building.BuilderFailedException: pch-c.c
D:\unity\Builder\2020.1.2f1\Editor\Data\il2cpp\libil2cpp\il2cpp-config.h(3): fatal error C1083: ????????????: ??string.h??: No such file or directory




Invocation was: Executable: "D:\��������\vs\VC\Tools\MSVC\14.16.27023\bin\HostX64\x64\cl.exe"
Arguments: "D:\unity\Builder\2020.1.2f1\Editor\Data\il2cpp\libil2cpp\pch\pch-c.c" /nologo /c /bigobj /W3 /Z7 /EHs /GR- /Gy /utf-8 /wd4102 /wd4800 /wd4056 /wd4190 /wd4723 /wd4467 /wd4503 /wd4996 /wd4200 /wd4834 /Ox /Oi /Oy- /GS- /Gw /GF /Zo /MT /D_WIN32 /DWIN32 /DWIN32_THREADS /D_WINDOWS /DWINDOWS /D_UNICODE /DUNICODE /D_CRT_SECURE_NO_WARNINGS /D_SCL_SECURE_NO_WARNINGS /D_WINSOCK_DEPRECATED_NO_WARNINGS /DNOMINMAX /D_NDEBUG /DNDEBUG /DWINDOWS_SDK_BUILD_VERSION=17763 /DWINAPI_FAMILY=WINAPI_FAMILY_DESKTOP_APP /DNET_4_0 /DUNITY_AOT /DIL2CPP_MONO_DEBUGGER_DISABLED /DGC_NOT_DLL /DRUNTIME_IL2CPP /DBASELIB_INLINE_NAMESPACE=il2cpp_baselib /I"D:\��������\vs\VC\Tools\MSVC\14.16.27023\include" /I"C:\Program Files (x86)\Windows Kits\10\Include\10.0.17763.0\shared" /I"C:\Program Files (x86)\Windows Kits\10\Include\10.0.17763.0\um" /I"C:\Program Files (x86)\Windows Kits\10\Include\10.0.17763.0\winrt" /I"C:\Program Files (x86)\Windows Kits\10\Include\10.0.17763.0\ucrt" /I"D:\unity\Builder\2020.1.2f1\Editor\Data\il2cpp\libil2cpp" /I"D:\unity\Builder\2020.1.2f1\Editor\Data\il2cpp\libil2cpp" /I"D:\unity\Builder\2020.1.2f1\Editor\Data\il2cpp\external\bdwgc\include" /I"D:\unity\Builder\2020.1.2f1\Editor\Data\il2cpp\external\xxHash" /I"D:\unity\Builder\2020.1.2f1\Editor\Data\il2cpp\external\baselib\Include" /I"D:\unity\Builder\2020.1.2f1\Editor\Data\il2cpp\external\baselib\Platforms\Windows\Include" /I"D:\unity\Builder\2020.1.2f1\Editor\Data\il2cpp\libil2cpp\pch" /I"D:\����\RW-MonumentValley\RW-MonumentValley\MonumentValleyStart\Temp\StagingArea\Data\il2cppOutput" /Ycpch-c.h /Fp"D:\����\RW-MonumentValley\RW-MonumentValley\MonumentValleyStart\Library\il2cpp_cache\12AA232D28E117E578524EB1EB31657A.pch" /Fo"D:\����\RW-MonumentValley\RW-MonumentValley\MonumentValleyStart\Library\il2cpp_cache\12AA232D28E117E578524EB1EB31657A.obj" /Fd"D:\����\RW-MonumentValley\RW-MonumentValley\MonumentValleyStart\Library\il2cpp_cache\12AA232D28E117E578524EB1EB31657A.pdb"
EnvArg key: PATH value: C:\Program Files (x86)\Windows Kits\10\bin\x64;C:\Program Files (x86)\Windows Kits\10\bin\x86;D:\��������\vs\VC\Tools\MSVC\14.16.27023\bin\HostX64\x64

   at Unity.IL2CPP.Building.ToolChains.MsvcToolChain.InvokePchCompilation(IL2CPPOutputBuildDescription programBuildDescription, NPath workingDirectory, Boolean forceRebuild, Boolean verbose, Boolean includeFileNamesInHashes, NPath sourceFile)
   at Unity.IL2CPP.Building.ToolChains.MsvcToolChain.CompilePch(ProgramBuildDescription programBuildDescription, NPath workingDirectory, Boolean forceRebuild, Boolean verbose, Boolean includeFileNamesInHashes)
   at Unity.IL2CPP.Building.ToolChains.MsvcToolChain.OnBeforeCompile(ProgramBuildDescription programBuildDescription, CppToolChainContext toolChainContext, NPath workingDirectory, Boolean forceRebuild, Boolean verbose, Boolean includeFileNamesInHashes)
   at Unity.IL2CPP.Building.CppProgramBuilder.Build(IBuildStatistics& statistics)
   at il2cpp.Compilation.CompilationDriver.Run(RuntimePlatform platform, BuildingOptions buildingOptions)
   at il2cpp.Program.DoRun(String[] args, RuntimePlatform platform, BuildingOptions buildingOptions)
   at il2cpp.Program.Run(String[] args, Boolean setInvariantCulture)
   at il2cpp.Program.Main(String[] args)
stderr:
Unhandled exception. Unity.IL2CPP.Building.BuilderFailedException: pch-c.c
D:\unity\Builder\2020.1.2f1\Editor\Data\il2cpp\libil2cpp\il2cpp-config.h(3): fatal error C1083: ????????????: ??string.h??: No such file or directory




Invocation was: Executable: "D:\��������\vs\VC\Tools\MSVC\14.16.27023\bin\HostX64\x64\cl.exe"
Arguments: "D:\unity\Builder\2020.1.2f1\Editor\Data\il2cpp\libil2cpp\pch\pch-c.c" /nologo /c /bigobj /W3 /Z7 /EHs /GR- /Gy /utf-8 /wd4102 /wd4800 /wd4056 /wd4190 /wd4723 /wd4467 /wd4503 /wd4996 /wd4200 /wd4834 /Ox /Oi /Oy- /GS- /Gw /GF /Zo /MT /D_WIN32 /DWIN32 /DWIN32_THREADS /D_WINDOWS /DWINDOWS /D_UNICODE /DUNICODE /D_CRT_SECURE_NO_WARNINGS /D_SCL_SECURE_NO_WARNINGS /D_WINSOCK_DEPRECATED_NO_WARNINGS /DNOMINMAX /D_NDEBUG /DNDEBUG /DWINDOWS_SDK_BUILD_VERSION=17763 /DWINAPI_FAMILY=WINAPI_FAMILY_DESKTOP_APP /DNET_4_0 /DUNITY_AOT /DIL2CPP_MONO_DEBUGGER_DISABLED /DGC_NOT_DLL /DRUNTIME_IL2CPP /DBASELIB_INLINE_NAMESPACE=il2cpp_baselib /I"D:\��������\vs\VC\Tools\MSVC\14.16.27023\include" /I"C:\Program Files (x86)\Windows Kits\10\Include\10.0.17763.0\shared" /I"C:\Program Files (x86)\Windows Kits\10\Include\10.0.17763.0\um" /I"C:\Program Files (x86)\Windows Kits\10\Include\10.0.17763.0\winrt" /I"C:\Program Files (x86)\Windows Kits\10\Include\10.0.17763.0\ucrt" /I"D:\unity\Builder\2020.1.2f1\Editor\Data\il2cpp\libil2cpp" /I"D:\unity\Builder\2020.1.2f1\Editor\Data\il2cpp\libil2cpp" /I"D:\unity\Builder\2020.1.2f1\Editor\Data\il2cpp\external\bdwgc\include" /I"D:\unity\Builder\2020.1.2f1\Editor\Data\il2cpp\external\xxHash" /I"D:\unity\Builder\2020.1.2f1\Editor\Data\il2cpp\external\baselib\Include" /I"D:\unity\Builder\2020.1.2f1\Editor\Data\il2cpp\external\baselib\Platforms\Windows\Include" /I"D:\unity\Builder\2020.1.2f1\Editor\Data\il2cpp\libil2cpp\pch" /I"D:\����\RW-MonumentValley\RW-MonumentValley\MonumentValleyStart\Temp\StagingArea\Data\il2cppOutput" /Ycpch-c.h /Fp"D:\����\RW-MonumentValley\RW-MonumentValley\MonumentValleyStart\Library\il2cpp_cache\12AA232D28E117E578524EB1EB31657A.pch" /Fo"D:\����\RW-MonumentValley\RW-MonumentValley\MonumentValleyStart\Library\il2cpp_cache\12AA232D28E117E578524EB1EB31657A.obj" /Fd"D:\����\RW-MonumentValley\RW-MonumentValley\MonumentValleyStart\Library\il2cpp_cache\12AA232D28E117E578524EB1EB31657A.pdb"
EnvArg key: PATH value: C:\Program Files (x86)\Windows Kits\10\bin\x64;C:\Program Files (x86)\Windows Kits\10\bin\x86;D:\��������\vs\VC\Tools\MSVC\14.16.27023\bin\HostX64\x64

   at Unity.IL2CPP.Building.ToolChains.MsvcToolChain.InvokePchCompilation(IL2CPPOutputBuildDescription programBuildDescription, NPath workingDirectory, Boolean forceRebuild, Boolean verbose, Boolean includeFileNamesInHashes, NPath sourceFile)
   at Unity.IL2CPP.Building.ToolChains.MsvcToolChain.CompilePch(ProgramBuildDescription programBuildDescription, NPath workingDirectory, Boolean forceRebuild, Boolean verbose, Boolean includeFileNamesInHashes)
   at Unity.IL2CPP.Building.ToolChains.MsvcToolChain.OnBeforeCompile(ProgramBuildDescription programBuildDescription, CppToolChainContext toolChainContext, NPath workingDirectory, Boolean forceRebuild, Boolean verbose, Boolean includeFileNamesInHashes)
   at Unity.IL2CPP.Building.CppProgramBuilder.Build(IBuildStatistics& statistics)
   at il2cpp.Compilation.CompilationDriver.Run(RuntimePlatform platform, BuildingOptions buildingOptions)
   at il2cpp.Program.DoRun(String[] args, RuntimePlatform platform, BuildingOptions buildingOptions)
   at il2cpp.Program.Run(String[] args, Boolean setInvariantCulture)
   at il2cpp.Program.Main(String[] args)

UnityEngine.Debug:LogError(Object)
UnityEditorInternal.Runner:RunProgram(Program, String, String, String, CompilerOutputParserBase)
UnityEditorInternal.Runner:RunNetCoreProgram(String, String, String, CompilerOutputParserBase, Action`1)
UnityEditorInternal.IL2CPPBuilder:RunIl2CppWithArguments(List`1, Action`1, String)
UnityEditorInternal.IL2CPPBuilder:ConvertPlayerDlltoCpp(Il2CppBuildPipelineData, String, String, Boolean)
UnityEditorInternal.IL2CPPBuilder:Run()
UnityEditorInternal.IL2CPPUtils:RunIl2Cpp(String, IIl2CppPlatformProvider, Action`1, RuntimeClassRegistry)
DesktopStandalonePostProcessor:SetupStagingArea(BuildPostProcessArgs, HashSet`1)
DesktopStandalonePostProcessor:PostProcess(BuildPostProcessArgs)
UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr, Boolean&)


看报错信息应该是某个文件没有找到,但是文件的提示全是“?”,不知道是什么文件

相关推荐 更多相似问题