yambs.translation package#
Module contents#
A module with interfaces for describing how sources are translated into outputs.
- class yambs.translation.SourceTranslator(rule: str = 'cc', output_extension: str = '.o', dest: Path = PosixPath('$build_dir'))[source]#
Bases:
NamedTuple
A structure for keeping track of how source files become different types of output files.
- dest: Path#
Alias for field number 2
- property generated_header: bool#
Determine if this translation produces a header file.
- property gets_linked: bool#
Determine if this source’s output gets linked into a final image or executable.
- output_extension: str#
Alias for field number 1
- rule: str#
Alias for field number 0
- yambs.translation.get_translator(path: Path) SourceTranslator [source]#
Get the source translator for a given source.
- yambs.translation.is_source(path: Path) SourceTranslator | None [source]#
Determine if a file is a source file.