Example #1
0
    def __init__( self, env, verbose_build, verbose_config, toolset_name ):
        self._verbose_build = verbose_build
        self._verbose_config = verbose_config
        self._toolset_filter = toolset_name + '.'

        self._minimal_output = not self._verbose_build
        ignore_duplicates = not self._verbose_build
        self._toolchain_processor = ToolchainProcessor( env['toolchain'], self._minimal_output, ignore_duplicates )
Example #2
0
class BjamOutputProcessor(object):

    def __init__( self, env, verbose_build, verbose_config, toolset_name ):
        self._verbose_build = verbose_build
        self._verbose_config = verbose_config
        self._toolset_filter = toolset_name + '.'

        self._colouriser = env['colouriser']
        self._minimal_output = not self._verbose_build
        ignore_duplicates = not self._verbose_build
        self._toolchain_processor = ToolchainProcessor( self._colouriser, env['toolchain'], self._minimal_output, ignore_duplicates )


    def __call__( self, line ):
        if line.startswith( self._toolset_filter ):
            return line
        elif not self._verbose_config:
            if(     line.startswith( "Performing configuration" )
                or  line.startswith( "Component configuration" )
                or  line.startswith( "    - " ) ):
                return None
        return self._toolchain_processor( line )


    def summary( self, returncode ):
        summary = self._toolchain_processor.summary( returncode )
        if returncode and not self._verbose_build:
            summary += "\nTry running with {} for more details".format( self._colouriser.emphasise( '--boost-verbose-build' ) )
        return summary
Example #3
0
class BjamOutputProcessor(object):
    def __init__(self, env, verbose_build, verbose_config, toolset_name):
        self._verbose_build = verbose_build
        self._verbose_config = verbose_config
        self._toolset_filter = toolset_name + '.'

        self._minimal_output = not self._verbose_build
        ignore_duplicates = not self._verbose_build
        self._toolchain_processor = ToolchainProcessor(env['toolchain'],
                                                       self._minimal_output,
                                                       ignore_duplicates)

    def __call__(self, line):
        if line.startswith(self._toolset_filter):
            return line
        elif not self._verbose_config:
            if (line.startswith("Performing configuration")
                    or line.startswith("Component configuration")
                    or line.startswith("    - ")):
                return None
        return self._toolchain_processor(line)

    def summary(self, returncode):
        summary = self._toolchain_processor.summary(returncode)
        if returncode and not self._verbose_build:
            summary += "\nTry running with {} for more details".format(
                as_emphasised('--boost-verbose-build'))
        return summary
Example #4
0
class BjamOutputProcessor(object):
    @classmethod
    def _toolset_name_from_toolchain(cls, toolchain):
        toolset_name = toolchain.toolset_name()
        if cuppa.build_platform.name() == "Darwin":
            if toolset_name == "gcc":
                toolset_name = "darwin"
            elif toolset_name == "clang":
                toolset_name = "clang-darwin"
        elif cuppa.build_platform.name() == "Linux":
            if toolset_name == "clang":
                toolset_name = "clang-linux"
        return toolset_name

    def __init__(self, env, verbose_build, verbose_config, toolchain):

        toolset_name = self._toolset_name_from_toolchain(toolchain)
        self._toolset_filter = toolset_name + '.'

        self._verbose_build = verbose_build
        self._verbose_config = verbose_config

        self._minimal_output = not self._verbose_build
        ignore_duplicates = not self._verbose_build
        self._toolchain_processor = ToolchainProcessor(env['toolchain'],
                                                       self._minimal_output,
                                                       ignore_duplicates)

    def __call__(self, line):
        if line.startswith(self._toolset_filter):
            return line
        elif not self._verbose_config:
            if (line.startswith("Performing configuration")
                    or line.startswith("Component configuration")
                    or line.startswith("    - ")):
                return None
        return self._toolchain_processor(line)

    def summary(self, returncode):
        summary = self._toolchain_processor.summary(returncode)
        if returncode and not self._verbose_build:
            summary += "\nTry running with {} for more details".format(
                as_emphasised('--boost-verbose-build'))
        return summary