compiler_d

Try to detect a D compiler from the list of supported compilers:

def options(opt):
        opt.load('compiler_d')
def configure(cnf):
        cnf.load('compiler_d')
def build(bld):
        bld.program(source='main.d', target='app')

Only three D compilers are really present at the moment:

  • gdc

  • dmd, the ldc compiler having a very similar command-line interface

  • ldc2

waflib.Tools.compiler_d.d_compiler = {'default': ['gdc', 'dmd', 'ldc2']}

Dict mapping the platform names to lists of names of D compilers to try, in order of preference:

from waflib.Tools.compiler_d import d_compiler
d_compiler['default'] = ['gdc', 'dmd', 'ldc2']
waflib.Tools.compiler_d.configure(conf)[source]

Detects a suitable D compiler

Raises

waflib.Errors.ConfigurationError when no suitable compiler is found

waflib.Tools.compiler_d.options(opt)[source]

This is how to provide compiler preferences on the command-line:

$ waf configure --check-d-compiler=dmd