本文整理汇总了C#中UnrealBuildTool.UEBuildTarget.GetTargetInfo方法的典型用法代码示例。如果您正苦于以下问题:C# UEBuildTarget.GetTargetInfo方法的具体用法?C# UEBuildTarget.GetTargetInfo怎么用?C# UEBuildTarget.GetTargetInfo使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类UnrealBuildTool.UEBuildTarget
的用法示例。
在下文中一共展示了UEBuildTarget.GetTargetInfo方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: IsActionOutdated
//.........这里部分代码省略.........
bool bFindCPPIncludePrerequisites = false;
if( RootAction.ActionType == ActionType.Compile )
{
// Outdated targets don't need their headers scanned yet, because presumably they would already be out of dated based on already-cached
// includes before getting this far. However, if we find them to be outdated after processing includes, we'll do a deep scan later
// on and cache all of the includes so that we have them for a quick outdatedness check the next run.
if( !bIsOutdated &&
BuildConfiguration.bUseExperimentalFastBuildIteration &&
UnrealBuildTool.IsAssemblingBuild &&
RootAction.ActionType == ActionType.Compile )
{
bFindCPPIncludePrerequisites = true;
}
// Were we asked to force an update of our cached includes BEFORE we try to build? This may be needed if our cache can no longer
// be trusted and we need to fill it with perfectly valid data (even if we're in assembler only mode)
if( BuildConfiguration.bUseExperimentalFastDependencyScan &&
UnrealBuildTool.bNeedsFullCPPIncludeRescan )
{
bFindCPPIncludePrerequisites = true;
}
}
if( bFindCPPIncludePrerequisites )
{
// Scan this file for included headers that may be out of date. Note that it's OK if we break out early because we found
// the action to be outdated. For outdated actions, we kick off a separate include scan in a background thread later on to
// catch all of the other includes and form an exhaustive set.
foreach (FileItem PrerequisiteItem in RootAction.PrerequisiteItems)
{
// @todo ubtmake: Make sure we are catching RC files here too. Anything that the toolchain would have tried it on. Logic should match the CACHING stuff below
if( PrerequisiteItem.CachedCPPIncludeInfo != null )
{
var BuildPlatform = UEBuildPlatform.GetBuildPlatform( Target.GetTargetInfo().Platform );
var IncludedFileList = CPPEnvironment.FindAndCacheAllIncludedFiles( Target, PrerequisiteItem, BuildPlatform, PrerequisiteItem.CachedCPPIncludeInfo, bOnlyCachedDependencies:BuildConfiguration.bUseExperimentalFastDependencyScan );
foreach( var IncludedFile in IncludedFileList ) // @todo fastubt: @todo ubtmake: Optimization: This is "retesting" a lot of the same files over and over in a single run (common indirect includes)
{
if( IncludedFile.bExists )
{
// allow a 1 second slop for network copies
TimeSpan TimeDifference = IncludedFile.LastWriteTime - LastExecutionTime;
bool bPrerequisiteItemIsNewerThanLastExecution = TimeDifference.TotalSeconds > 1;
if (bPrerequisiteItemIsNewerThanLastExecution)
{
Log.TraceVerbose(
"{0}: Included file {1} is newer than the last execution of the action: {2} vs {3}",
RootAction.StatusDescription,
Path.GetFileName(IncludedFile.AbsolutePath),
IncludedFile.LastWriteTime.LocalDateTime,
LastExecutionTime.LocalDateTime
);
bIsOutdated = true;
// Don't bother checking every single include if we've found one that is out of date
break;
}
}
}
}
if( bIsOutdated )
{
break;
}
}
}