LYN-2537 AssetBundler updates (#426)

* LYN-2537 Updated the AssetBundler code to looks for the AssetSeedList
files within the Assets/Engine directory
Updated the MissingDependencyScanner GetXMLDependenciesFile functions to
use the Assets/Engine directory as well

Also fixed the MissingDependencyScanner to properly located dependency
xml files within gem directories

* Adding back input argument validation for the AssetBundler command options.

Also added an application_options settings registry file that contains the list of valid command options for the ComponentApplication

* Adding missing end of file newline for applications_options.setreg

* Fixed the AssetBundler help output for the bundleSeed command
This commit is contained in:
lumberyard-employee-dm
2021-05-03 20:09:37 -05:00
committed by GitHub
parent 15c2203e01
commit bcbe1bfef7
12 changed files with 127 additions and 95 deletions
+5 -13
View File
@@ -109,17 +109,15 @@ namespace AssetBundler
const char* AssetCatalogFilename = "assetcatalog.xml";
AZ::IO::FixedMaxPath g_cachedEngineRoot;
const char EngineDirectoryName[] = "Engine";
constexpr auto EngineDirectoryName = AZ::IO::FixedMaxPath("Assets") / "Engine";
const char RestrictedDirectoryName[] = "restricted";
const char PlatformsDirectoryName[] = "Platforms";
const char GemsDirectoryName[] = "Gems";
const char GemsAssetsDirectoryName[] = "Assets";
const char GemsSeedFileName[] = "seedList";
const char EngineSeedFileName[] = "SeedAssetList";
namespace Internal
{
@@ -131,7 +129,7 @@ namespace AssetBundler
AZStd::unordered_map<AZStd::string, AZStd::string>& defaultSeedLists,
AzFramework::PlatformFlags platformFlags)
{
AZ::IO::FixedMaxPath engineRoot(GetCachedEngineRoot());
AZ::IO::FixedMaxPath engineRoot(AZ::Utils::GetEnginePath());
AZ::IO::FixedMaxPath engineRestrictedRoot = engineRoot / RestrictedDirectoryName;
AZ::IO::FixedMaxPath engineLocalPath = AZ::IO::PathView(engineDirectory.LexicallyRelative(engineRoot));
@@ -204,12 +202,6 @@ namespace AssetBundler
}
}
AZ::IO::FixedMaxPath GetCachedEngineRoot()
{
AZ_Error(AppWindowName, !g_cachedEngineRoot.empty(), "Cached Engine Root has not been initialized by the Bundler.");
return g_cachedEngineRoot;
}
void AddPlatformIdentifier(AZStd::string& filePath, const AZStd::string& platformIdentifier)
{
AZStd::string fileName;
@@ -257,11 +249,11 @@ namespace AssetBundler
absoluteEngineSeedFilePath.ReplaceExtension(AzToolsFramework::AssetSeedManager::GetSeedFileExtension());
if (fileIO->Exists(absoluteEngineSeedFilePath.c_str()))
{
defaultSeedLists[absoluteEngineSeedFilePath.Native()] = EngineDirectoryName;
defaultSeedLists[absoluteEngineSeedFilePath.Native()] = EngineDirectoryName.String();
}
// Add Seed Lists from the Platforms directory
Internal::AddPlatformsDirectorySeeds(engineDirectory, EngineDirectoryName, defaultSeedLists, platformFlag);
Internal::AddPlatformsDirectorySeeds(engineDirectory, EngineDirectoryName.String(), defaultSeedLists, platformFlag);
auto absoluteProjectDefaultSeedFilePath = AZ::IO::Path(projectPath) / EngineSeedFileName;
absoluteProjectDefaultSeedFilePath.ReplaceExtension(AzToolsFramework::AssetSeedManager::GetSeedFileExtension());