You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
25 lines
801 B
Python
25 lines
801 B
Python
# -*- python -*-
|
|
|
|
def options(ctx):
|
|
ctx.system_opt('yaml-cpp', cross=True)
|
|
|
|
def configure(ctx):
|
|
def system_yaml(ctx):
|
|
ctx.check_cfg(package='yaml-cpp', args='--cflags --libs',
|
|
define_name='', add_to_env=False)
|
|
ctx.with_chk('yaml-cpp', {'system': system_yaml, 'bundle': None}, cross=True)
|
|
|
|
def build_yaml_cpp(ctx, pref):
|
|
if ctx.env.WITH_YAML_CPP != 'bundle': return
|
|
|
|
idx = 51700 + (len(pref)>0)
|
|
ctx.stlib(idx = idx,
|
|
source = ctx.path.ant_glob('yaml-cpp/src/*.cpp'),
|
|
includes = 'yaml-cpp/include',
|
|
export_includes = 'yaml-cpp/include',
|
|
target = pref+'yaml-cpp',
|
|
uselib = 'EXT')
|
|
|
|
def build(ctx):
|
|
ctx.both_host_env(build_yaml_cpp)
|