from bento.commands import hooks

@hooks.pre_build
def pre_build(context):
    conf = context.waf_context
    conf.check_cc(function_name='open_memstream', header_name="stdio.h")
    conf.write_config_header('trlib_misc_config.h')

    context.tweak_extension("_trlib",
                            features="c fc pyext bento cshlib",
                            use = "LAPACK CLIB",
                            includes=["trlib", "."])
