def base_config(c): c.compile_py.default_targets = [] gyp_defs = c.gyp_env.GYP_DEFINES gyp_defs['fastbuild'] = 1 gyp_defs['OS'] = 'android' if c.HOST_PLATFORM != 'linux': raise recipe_config.BadConf('Can only build android on linux.')
def v8(c): targ_arch = c.gyp_env.GYP_DEFINES.get('target_arch') if not targ_arch: # pragma: no cover raise recipe_config.BadConf('v8 must have a valid target_arch.') c.gyp_env.GYP_DEFINES['v8_target_arch'] = targ_arch del c.gyp_env.GYP_DEFINES['component'] c.build_dir = Path('[CHECKOUT]', 'out') c.compile_py.build_tool = 'make' if c.HOST_PLATFORM == 'mac': c.compile_py.build_tool = 'xcode' elif c.HOST_PLATFORM == 'win': c.compile_py.build_tool = 'vs' c.build_dir = Path('[CHECKOUT]', 'build') if c.BUILD_CONFIG == 'Debug': c.gyp_env.GYP_DEFINES['v8_optimized_debug'] = 1 # Chromium adds '_x64' to the output folder, which is neither needed nor # understood when compiling v8 standalone. if c.HOST_PLATFORM == 'win' and c.TARGET_BITS == 64: c.build_config_fs = c.BUILD_CONFIG c.compile_py.pass_arch_flag = True
def mipsel_builder(c): if c.TARGET_ARCH != 'mipsel': raise recipe_config.BadConf('I dunno what to put in a mips builder!')
def x86_builder(c): if c.TARGET_ARCH != 'intel': raise recipe_config.BadConf( 'Cannot target x86 with TARGET_ARCH == %s' % c.TARGET_ARCH)
def main_builder(c): if c.TARGET_ARCH != 'arm': raise recipe_config.BadConf( 'Cannot target arm with TARGET_ARCH == %s' % c.TARGET_ARCH)
def x64_builder(c): if c.TARGET_ARCH != 'intel' or c.TARGET_BITS != 64: raise recipe_config.BadConf( 'Cannot target x64 with TARGET_ARCH == %s, TARGET_BITS == %d' % (c.TARGET_ARCH, c.TARGET_BITS))