Declare a special compiler generator. The only thing it does is changing the type used to represent 'action' in the constructed dependency graph to 'CompileAction'. That class in turn adds additional include paths to handle a case when a source file includes headers
| 548 | return prop_set.add_raw (s.implicit_includes ('include', 'H')) |
| 549 | |
| 550 | class CCompilingGenerator (generators.Generator): |
| 551 | """ Declare a special compiler generator. |
| 552 | The only thing it does is changing the type used to represent |
| 553 | 'action' in the constructed dependency graph to 'CompileAction'. |
| 554 | That class in turn adds additional include paths to handle a case |
| 555 | when a source file includes headers which are generated themselfs. |
| 556 | """ |
| 557 | def __init__ (self, id, composing, source_types, target_types_and_names, requirements): |
| 558 | # TODO: (PF) What to do with optional_properties? It seemed that, in the bjam version, the arguments are wrong. |
| 559 | generators.Generator.__init__ (self, id, composing, source_types, target_types_and_names, requirements) |
| 560 | |
| 561 | def action_class (self): |
| 562 | return CompileAction |
| 563 | |
| 564 | def register_c_compiler (id, source_types, target_types, requirements, optional_properties = []): |
| 565 | g = CCompilingGenerator (id, False, source_types, target_types, requirements + optional_properties) |
no outgoing calls
no test coverage detected