本文主要是介绍UE4 BuildCookRun中的Archive的含义,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!
在UE4中,Archive、Cook、Stage、Package、Build的次序是怎么样的?
整体打包过程如下: Build -> Cook-> Stage -> Package -> Archive。其中,Archive 的含义是从Staged目录中拷贝文件到一个额外的目录即Archive目录。被称为“归档”。
调试方式
选择以上程序,并指定这些参数进行调试:
-ScriptsForProject=D:\我的项目.uproject
BuildCookRun
-nop4
-project=D:\我的项目.uproject
-cook
-stage
-archive
-archivedirectory=C:\Dustbin\MyArchive3
-package
-ue4exe=D:\我的项目\EngineSource/Engine/Binaries/Win64/UE4Editor-Cmd.exe
-compressed
-pak
-prereqs
-nodebuginfo
-manifests
-targetplatform=Win64
-build
-target={我的项目名}
-clientconfig=Development
-utf8output
-compile
DeploymentContext.ArchiveFiles
添加需要Archive的文件到 ArchivedFiles 中:
Project.CreateDeploymentContext
部署任务的上下文,在Stage、Package、Archive 的阶段,都会进入到这里,下面是其中的一些上下文信息:
实际的Archive拷贝动作
由 AutomationTool.Platform.GetFilesToArchive 触发 Project.Archive :
Project.Archivepublic static void Archive(ProjectParams Params){Params.ValidateAndLog();if (!Params.Archive){return;}LogInformation("********** ARCHIVE COMMAND STARTED **********");LogInformation("Archiving to {0}", Params.ArchiveDirectoryParam);if (!Params.NoClient){var DeployContextList = CreateDeploymentContext(Params, false, false);foreach ( var SC in DeployContextList ){CreateArchiveManifest(Params, SC);ApplyArchiveManifest(Params, SC);SC.StageTargetPlatform.ProcessArchivedProject(Params, SC);}}
通过向其中的拷贝动作加入日志,观察到Archive的实际操作过程如下:
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\我的项目.exe >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\我的项目.exe
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\Manifest_NonUFSFiles_Win64.txt >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\Manifest_NonUFSFiles_Win64.txt
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\我的项目\Binaries\Win64\我的项目.exe >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\我的项目\Binaries\Win64\我的项目.exe
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\我的项目\Binaries\Win64\D3D12\D3D12Core.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\我的项目\Binaries\Win64\D3D12\D3D12Core.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\我的项目\Binaries\Win64\D3D12\d3d12SDKLayers.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\我的项目\Binaries\Win64\D3D12\d3d12SDKLayers.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\我的项目\Content\Paks\pak-0-0-pakchunk0-WindowsNoEditor.pak >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\我的项目\Content\Paks\pak-0-0-pakchunk0-WindowsNoEditor.pak
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\我的项目\Plugins\Pandora\Gamelet\Binaries\Win64\openplatform.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\我的项目\Plugins\Pandora\Gamelet\Binaries\Win64\openplatform.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\avcodec-57.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\avcodec-57.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\avdevice-57.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\avdevice-57.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\avfilter-6.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\avfilter-6.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\avformat-57.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\avformat-57.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\avutil-55.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\avutil-55.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\libwinpthread-1.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\libwinpthread-1.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\pfbs.exe >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\pfbs.exe
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\pixuiCurl.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\pixuiCurl.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\PixUI_PXPlugin.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\PixUI_PXPlugin.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\PixVideo.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\PixVideo.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\pthreadVC2.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\pthreadVC2.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\PxExtFFi.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\PxExtFFi.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\quickjs.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\quickjs.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\swresample-2.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\swresample-2.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\swscale-4.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\swscale-4.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\xaudio2_9redist.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\我的项目\Plugins\Pandora\PixUI\Binaries\Win64\xaudio2_9redist.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\Engine\Binaries\ThirdParty\DbgHelp\dbghelp.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\Engine\Binaries\ThirdParty\DbgHelp\dbghelp.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\Engine\Binaries\ThirdParty\libsndfile\Win64\libsndfile-1.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\Engine\Binaries\ThirdParty\libsndfile\Win64\libsndfile-1.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\Engine\Binaries\ThirdParty\NVIDIA\NVaftermath\Win64\GFSDK_Aftermath_Lib.x64.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\Engine\Binaries\ThirdParty\NVIDIA\NVaftermath\Win64\GFSDK_Aftermath_Lib.x64.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\Engine\Binaries\ThirdParty\Oculus\OVRPlugin\OVRPlugin\Win64\OVRPlugin.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\Engine\Binaries\ThirdParty\Oculus\OVRPlugin\OVRPlugin\Win64\OVRPlugin.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\Engine\Binaries\ThirdParty\Ogg\Win64\VS2015\libogg_64.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\Engine\Binaries\ThirdParty\Ogg\Win64\VS2015\libogg_64.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\Engine\Binaries\ThirdParty\OpenVR\OpenVRv1_5_17\Win64\openvr_api.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\Engine\Binaries\ThirdParty\OpenVR\OpenVRv1_5_17\Win64\openvr_api.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\Engine\Binaries\ThirdParty\PhysX3\Win64\VS2015\ApexFrameworkPROFILE_x64.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\Engine\Binaries\ThirdParty\PhysX3\Win64\VS2015\ApexFrameworkPROFILE_x64.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\Engine\Binaries\ThirdParty\PhysX3\Win64\VS2015\APEX_ClothingPROFILE_x64.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\Engine\Binaries\ThirdParty\PhysX3\Win64\VS2015\APEX_ClothingPROFILE_x64.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\Engine\Binaries\ThirdParty\PhysX3\Win64\VS2015\APEX_LegacyPROFILE_x64.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\Engine\Binaries\ThirdParty\PhysX3\Win64\VS2015\APEX_LegacyPROFILE_x64.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\Engine\Binaries\ThirdParty\PhysX3\Win64\VS2015\NvClothPROFILE_x64.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\Engine\Binaries\ThirdParty\PhysX3\Win64\VS2015\NvClothPROFILE_x64.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\Engine\Binaries\ThirdParty\PhysX3\Win64\VS2015\PhysX3CommonPROFILE_x64.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\Engine\Binaries\ThirdParty\PhysX3\Win64\VS2015\PhysX3CommonPROFILE_x64.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\Engine\Binaries\ThirdParty\PhysX3\Win64\VS2015\PhysX3CookingPROFILE_x64.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\Engine\Binaries\ThirdParty\PhysX3\Win64\VS2015\PhysX3CookingPROFILE_x64.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\Engine\Binaries\ThirdParty\PhysX3\Win64\VS2015\PhysX3PROFILE_x64.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\Engine\Binaries\ThirdParty\PhysX3\Win64\VS2015\PhysX3PROFILE_x64.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\Engine\Binaries\ThirdParty\PhysX3\Win64\VS2015\PxFoundationPROFILE_x64.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\Engine\Binaries\ThirdParty\PhysX3\Win64\VS2015\PxFoundationPROFILE_x64.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\Engine\Binaries\ThirdParty\PhysX3\Win64\VS2015\PxPvdSDKPROFILE_x64.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\Engine\Binaries\ThirdParty\PhysX3\Win64\VS2015\PxPvdSDKPROFILE_x64.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\Engine\Binaries\ThirdParty\Vorbis\Win64\VS2015\libvorbisfile_64.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\Engine\Binaries\ThirdParty\Vorbis\Win64\VS2015\libvorbisfile_64.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\Engine\Binaries\ThirdParty\Vorbis\Win64\VS2015\libvorbis_64.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\Engine\Binaries\ThirdParty\Vorbis\Win64\VS2015\libvorbis_64.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\Engine\Binaries\ThirdParty\Windows\DirectX\x64\WinPixEventRuntime.dll >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\Engine\Binaries\ThirdParty\Windows\DirectX\x64\WinPixEventRuntime.dll
D:\我的项目\Saved\StagedBuilds\WindowsNoEditor\Engine\Extras\Redist\en-us\UE4PrereqSetup_x64.exe >-> C:\我的归档目录\MyArchive3\WindowsNoEditor\Engine\Extras\Redist\en-us\UE4PrereqSetup_x64.exe
********** ARCHIVE COMMAND COMPLETED **********
这篇关于UE4 BuildCookRun中的Archive的含义的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!