dest_dir='tests',
skia_lib_var_dict=common,
local_module_name='skia_test',
- local_module_tags=['tests'])
+ local_module_tags=['tests'],
+ desired_targets=['tests'])
tool_makefile_writer.generate_tool(gyp_dir=tmp_folder,
target_file='bench.gyp',
skia_lib_var_dict=common,
local_module_name='skia_bench',
local_module_tags=['tests'],
+ desired_targets=['bench'],
place_in_local_tmp=True)
tool_makefile_writer.generate_tool(gyp_dir=tmp_folder,
dest_dir='gm',
skia_lib_var_dict=common,
local_module_name='skia_gm',
- local_module_tags=['tests'])
+ local_module_tags=['tests'],
+ desired_targets=['gm'])
tool_makefile_writer.generate_tool(gyp_dir=tmp_folder,
target_file='dm.gyp',
dest_dir='dm',
skia_lib_var_dict=common,
local_module_name='skia_dm',
- local_module_tags=['tests'])
+ local_module_tags=['tests'],
+ desired_targets=['dm'])
# Now that the defines have been written to SkUserConfig and they've been
# used to skip adding them to the tools makefiles, they are not needed in
def generate_tool(gyp_dir, target_file, skia_trunk, dest_dir,
skia_lib_var_dict, local_module_name, local_module_tags,
+ desired_targets,
place_in_local_tmp=False):
"""Common steps for building one of the skia tools.
ensure we do not duplicate anything in this Android.mk.
local_module_name: Name for this tool, to set as LOCAL_MODULE.
local_module_tags: Tags to pass to LOCAL_MODULE_TAG.
+ desired_targets: List of targets to parse.
place_in_local_tmp: If True, the executable will be synced to
/data/local/tmp.
"""
# Add known targets from skia_lib, so we do not reparse them.
var_dict.KNOWN_TARGETS.set(skia_lib_var_dict.KNOWN_TARGETS)
- gypd_parser.parse_gypd(var_dict, result_file, dest_dir)
+ gypd_parser.parse_gypd(var_dict, result_file, dest_dir, desired_targets)
android_framework_gyp.clean_gypd_files(gyp_dir)