Ejemplo n.º 1
0
def parse_cmake(node, config, uri, repositories, default_repo):
    instance = CMakeModule.parse_from_xml(node, config, uri, repositories,
                                          default_repo)

    instance.dependencies += ['cmake', instance.get_makecmd(config)]

    instance.cmakeargs = collect_args(instance, node, 'cmakeargs')
    instance.makeargs = collect_args(instance, node, 'makeargs')

    if node.hasAttribute('skip-install'):
        skip_install = node.getAttribute('skip-install')
        if skip_install.lower() in ('true', 'yes'):
            instance.skip_install_phase = True
        else:
            instance.skip_install_phase = False
    if node.hasAttribute('supports-non-srcdir-builds'):
        instance.supports_non_srcdir_builds = \
                (node.getAttribute('supports-non-srcdir-builds') != 'no')
    if node.hasAttribute('force-non-srcdir-builds'):
        instance.force_non_srcdir_builds = \
                (node.getAttribute('force-non-srcdir-builds') != 'no')
    if node.hasAttribute('use-ninja'):
        use_ninja = node.getAttribute('use-ninja')
        if use_ninja.lower() in ('false', 'no'):
            instance.use_ninja = False
    return instance
Ejemplo n.º 2
0
def parse_cmake(node, config, uri, repositories, default_repo):
    instance = CMakeModule.parse_from_xml(node, config, uri, repositories, default_repo)

    instance.dependencies += ["cmake", instance.get_makecmd(config)]

    instance.cmakeargs = collect_args(instance, node, "cmakeargs")
    instance.makeargs = collect_args(instance, node, "makeargs")

    if node.hasAttribute("supports-non-srcdir-builds"):
        instance.supports_non_srcdir_builds = node.getAttribute("supports-non-srcdir-builds") != "no"
    if node.hasAttribute("force-non-srcdir-builds"):
        instance.force_non_srcdir_builds = node.getAttribute("force-non-srcdir-builds") != "no"
    return instance
Ejemplo n.º 3
0
def parse_cmake(node, config, uri, repositories, default_repo):
    instance = CMakeModule.parse_from_xml(node, config, uri, repositories,
                                          default_repo)

    instance.dependencies += [
        'cmake',
        instance.get_ninjacmd(config),
        instance.get_makecmd(config),
    ]

    instance.cmakeargs = collect_args(instance, node, 'cmakeargs')
    instance.makeargs = collect_args(instance, node, 'makeargs')
    instance.ninjaargs = collect_args(instance, node, 'ninjaargs')

    if node.hasAttribute('skip-install'):
        skip_install = node.getAttribute('skip-install')
        if skip_install.lower() in ('true', 'yes'):
            instance.skip_install_phase = True
        else:
            instance.skip_install_phase = False
    if node.hasAttribute('supports-non-srcdir-builds'):
        instance.supports_non_srcdir_builds = (
            node.getAttribute('supports-non-srcdir-builds') != 'no')
    if node.hasAttribute('force-non-srcdir-builds'):
        instance.force_non_srcdir_builds = \
                (node.getAttribute('force-non-srcdir-builds') != 'no')
    if node.hasAttribute('use-ninja'):
        use_ninja = node.getAttribute('use-ninja')
        if use_ninja.lower() in ('true', 'yes'):
            instance.use_ninja = True
    if node.hasAttribute('cmakedir'):
        instance.cmakedir = node.getAttribute('cmakedir')

    # ziyan: add option to support stripping debug symbols
    if node.hasAttribute('supports-stripping-debug-symbols'):
        instance.supports_stripping_debug_symbols = (
            node.getAttribute('supports-stripping-debug-symbols') != 'no')
    # liuhuan: override cmakeargs defined in xml if it is specified in .jhbuildrc
    if config.modulecmakeargs.has_key(instance.name):
        instance.cmakeargs = config.modulecmakeargs[instance.name]
    # woody: option to append to cmakeargs defined in .modulesets
    elif config.appendmodulecmakeargs.has_key(instance.name):
        instance.cmakeargs += " " + config.appendmodulecmakeargs[instance.name]
    elif node.hasAttribute('cmakeargs'):
        instance.cmakeargs = node.getAttribute('cmakeargs')
    if node.hasAttribute('makeargs'):
        instance.makeargs = node.getAttribute('makeargs')

    return instance
Ejemplo n.º 4
0
def parse_meson(node, config, uri, repositories, default_repo):
    instance = MesonModule.parse_from_xml(node, config, uri, repositories, default_repo)

    instance.dependencies += ['meson', instance.get_makecmd(config)]

    instance.mesonargs = collect_args(instance, node, 'mesonargs')
    instance.makeargs = collect_args(instance, node, 'makeargs')

    if node.hasAttribute('skip-install'):
        skip_install = node.getAttribute('skip-install')
        if skip_install.lower() in ('true', 'yes'):
            instance.skip_install_phase = True
        else:
            instance.skip_install_phase = False

    return instance
Ejemplo n.º 5
0
def parse_meson(node, config, uri, repositories, default_repo):
    instance = MesonModule.parse_from_xml(node, config, uri, repositories, default_repo)

    instance.dependencies += ['meson', instance.get_makecmd(config)]

    instance.mesonargs = collect_args(instance, node, 'mesonargs')
    instance.makeargs = collect_args(instance, node, 'makeargs')

    if node.hasAttribute('skip-install'):
        skip_install = node.getAttribute('skip-install')
        if skip_install.lower() in ('true', 'yes'):
            instance.skip_install_phase = True
        else:
            instance.skip_install_phase = False

    return instance
Ejemplo n.º 6
0
def parse_cmake(node, config, uri, repositories, default_repo):
    instance = CMakeModule.parse_from_xml(node, config, uri, repositories, default_repo)

    instance.dependencies += [
        'cmake',
        instance.get_ninjacmd(config),
        instance.get_makecmd(config),
    ]

    instance.cmakeargs = collect_args(instance, node, 'cmakeargs')
    instance.makeargs = collect_args(instance, node, 'makeargs')
    instance.ninjaargs = collect_args(instance, node, 'ninjaargs')

    if node.hasAttribute('skip-install'):
        skip_install = node.getAttribute('skip-install')
        if skip_install.lower() in ('true', 'yes'):
            instance.skip_install_phase = True
        else:
            instance.skip_install_phase = False
    if node.hasAttribute('supports-non-srcdir-builds'):
        instance.supports_non_srcdir_builds = (node.getAttribute('supports-non-srcdir-builds') != 'no')
    if node.hasAttribute('force-non-srcdir-builds'):
        instance.force_non_srcdir_builds = \
                (node.getAttribute('force-non-srcdir-builds') != 'no')
    if node.hasAttribute('use-ninja'):
        use_ninja = node.getAttribute('use-ninja')
        if use_ninja.lower() in ('true', 'yes'):
            instance.use_ninja = True
    if node.hasAttribute('cmakedir'):
        instance.cmakedir = node.getAttribute('cmakedir')

    # ziyan: add option to support stripping debug symbols
    if node.hasAttribute('supports-stripping-debug-symbols'):
        instance.supports_stripping_debug_symbols = (node.getAttribute('supports-stripping-debug-symbols') != 'no')
    # liuhuan: override cmakeargs defined in xml if it is specified in .jhbuildrc
    if config.modulecmakeargs.has_key(instance.name):
        instance.cmakeargs = config.modulecmakeargs[instance.name]
    # woody: option to append to cmakeargs defined in .modulesets
    elif config.appendmodulecmakeargs.has_key(instance.name):
        instance.cmakeargs += " " + config.appendmodulecmakeargs[instance.name]
    elif node.hasAttribute('cmakeargs'):
        instance.cmakeargs = node.getAttribute('cmakeargs')
    if node.hasAttribute('makeargs'):
        instance.makeargs = node.getAttribute('makeargs')

    return instance
Ejemplo n.º 7
0
def parse_cmake(node, config, uri, repositories, default_repo):
    instance = CMakeModule.parse_from_xml(node, config, uri, repositories, default_repo)

    instance.dependencies += ['cmake', instance.get_makecmd(config)]

    instance.cmakeargs = collect_args(instance, node, 'cmakeargs')
    instance.makeargs = collect_args(instance, node, 'makeargs')

    if node.hasAttribute('skip-install'):
        skip_install = node.getAttribute('skip-install')
        if skip_install.lower() in ('true', 'yes'):
            instance.skip_install_phase = True
        else:
            instance.skip_install_phase = False
    if node.hasAttribute('supports-non-srcdir-builds'):
        instance.supports_non_srcdir_builds = \
                (node.getAttribute('supports-non-srcdir-builds') != 'no')
    if node.hasAttribute('force-non-srcdir-builds'):
        instance.force_non_srcdir_builds = \
                (node.getAttribute('force-non-srcdir-builds') != 'no')
    return instance