示例#1
0
 def __init__(self, log: Log, generatorOriginalName: str, buildCommand: int,
              buildThreads: int) -> None:
     self.Log = log
     self.AdditionalBuildArguments = []  # type: List[str]
     PlatformBuildUtil.AddBuildThreads(log, self.AdditionalBuildArguments,
                                       generatorOriginalName, buildThreads)
     if buildCommand == CommandType.Clean:
         self.__HandleCleanBuilds(self.AdditionalBuildArguments,
                                  generatorOriginalName)
示例#2
0
    def __init__(self, generatorContext: GeneratorContext, buildThreads: int,
                 buildTypeInfo: PlatformBuildTypeInfo) -> None:
        super().__init__()
        self.Context = generatorContext
        self.BasicConfig = generatorContext.BasicConfig
        # Builders like ninja and make only contains a single configuration
        self.IsSingleConfiguration = False
#        #self.__ConfigureForPlatform(generatorContext)
        self.BuilderThreadArguments = [] # type: List[str]
        self.NumBuildThreads = PlatformBuildUtil.AddBuildThreads(generatorContext.Log, self.BuilderThreadArguments, generatorContext.PlatformName,
                                                                 buildThreads, buildTypeInfo, generatorContext.CMakeConfig, True)
 def __init__(self, log: Log, generatorOriginalName: str,
              isCMakeGenerator: bool, buildThreads: int) -> None:
     self.Log = log
     self.AdditionalBuildArguments = []  # type: List[str]
     # The CMake generator adds the necessary parameters automatically
     # A future pass on this code should move the AddBuildThreads arguments to the generators instead as its more appropriate.
     numBuildThreads = 1
     if not isCMakeGenerator:
         numBuildThreads = PlatformBuildUtil.AddBuildThreads(
             log, self.AdditionalBuildArguments, generatorOriginalName,
             buildThreads)
     else:
         numBuildThreads = PlatformBuildUtil.GetRecommendedBuildThreads(
             buildThreads)
     self.NumBuildThreads = numBuildThreads