buildtest.cli.compilers

Module Contents

Classes

BuildtestCompilers

Functions

compiler_cmd(args, configuration)

compiler_find(args, configuration)

This method implements buildtest config compilers find which detects

class buildtest.cli.compilers.BuildtestCompilers(configuration, settings_file=None, debug=False)
compiler_table
_update_compiler_section(self)

This method will update the compiler section by adding new compilers if found

Returns

Updated compiler section for buildtest configuration

Return type

dict

_validate_modules(self, module_dict)

This method will validate modules by running module load test for all discovered modules specified in parameter discovered_modules. This method returns a list of modules that were valid, if all tests pass we return the same list. A module test pass if we get a returncode 0.

find_compilers(self)

This method returns compiler modules discovered depending on your module system. If you have Lmod system we use spider utility to detect modules, this is leveraging Lmodule API. If you have environment-modules we parse output of module av -t.

Returns

return a list of compiler modules detected based on module key name.

Return type

dict

list(self)

Return all compilers defined in buildtest configuration

print_compilers(self)

This method implements buildtest config compilers which prints all compilers from buildtest configuration

print_json(self)

Prints compiler section in JSON, this implements buildtest config compilers --json

print_yaml(self)

Prints compiler section in YAML, this implements buildtest config compilers --yaml

buildtest.cli.compilers.compiler_cmd(args, configuration)
buildtest.cli.compilers.compiler_find(args, configuration)

This method implements buildtest config compilers find which detects new compilers based on module names defined in configuration. If system has Lmod we use Lmodule API to detect the compilers. For environment-modules we search for all modules in current $MODULEPATH.