| OLD | NEW |
| 1 #!/usr/bin/python | 1 #!/usr/bin/python |
| 2 | 2 |
| 3 # Copyright 2014 Google Inc. | 3 # Copyright 2014 Google Inc. |
| 4 # | 4 # |
| 5 # Use of this source code is governed by a BSD-style license that can be | 5 # Use of this source code is governed by a BSD-style license that can be |
| 6 # found in the LICENSE file. | 6 # found in the LICENSE file. |
| 7 | 7 |
| 8 """ | 8 """ |
| 9 Script for generating the Android framework's version of Skia from gyp | 9 Script for generating the Android framework's version of Skia from gyp |
| 10 files. | 10 files. |
| (...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 138 require_sk_user_config=require_sk_user_config, target_dir=dst_dir, | 138 require_sk_user_config=require_sk_user_config, target_dir=dst_dir, |
| 139 defines=common.DEFINES) | 139 defines=common.DEFINES) |
| 140 | 140 |
| 141 tool_makefile_writer.generate_tool(gyp_dir=tmp_folder, | 141 tool_makefile_writer.generate_tool(gyp_dir=tmp_folder, |
| 142 target_file='bench.gyp', | 142 target_file='bench.gyp', |
| 143 skia_trunk=target_dir, | 143 skia_trunk=target_dir, |
| 144 dest_dir='bench', | 144 dest_dir='bench', |
| 145 skia_lib_var_dict=common, | 145 skia_lib_var_dict=common, |
| 146 local_module_name='skia_nanobench', | 146 local_module_name='skia_nanobench', |
| 147 local_module_tags=['tests'], | 147 local_module_tags=['tests'], |
| 148 desired_targets=['nanobench']) | 148 desired_targets=['nanobench'], |
| 149 gyp_source_dir=gyp_source_dir) |
| 149 | 150 |
| 150 tool_makefile_writer.generate_tool(gyp_dir=tmp_folder, | 151 tool_makefile_writer.generate_tool(gyp_dir=tmp_folder, |
| 151 target_file='gm.gyp', | 152 target_file='gm.gyp', |
| 152 skia_trunk=target_dir, | 153 skia_trunk=target_dir, |
| 153 dest_dir='gm', | 154 dest_dir='gm', |
| 154 skia_lib_var_dict=common, | 155 skia_lib_var_dict=common, |
| 155 local_module_name='skia_gm', | 156 local_module_name='skia_gm', |
| 156 local_module_tags=['tests'], | 157 local_module_tags=['tests'], |
| 157 desired_targets=['gm']) | 158 desired_targets=['gm'], |
| 159 gyp_source_dir=gyp_source_dir) |
| 158 | 160 |
| 159 tool_makefile_writer.generate_tool(gyp_dir=tmp_folder, | 161 tool_makefile_writer.generate_tool(gyp_dir=tmp_folder, |
| 160 target_file='dm.gyp', | 162 target_file='dm.gyp', |
| 161 skia_trunk=target_dir, | 163 skia_trunk=target_dir, |
| 162 dest_dir='dm', | 164 dest_dir='dm', |
| 163 skia_lib_var_dict=common, | 165 skia_lib_var_dict=common, |
| 164 local_module_name='skia_dm', | 166 local_module_name='skia_dm', |
| 165 local_module_tags=['tests'], | 167 local_module_tags=['tests'], |
| 166 desired_targets=['dm']) | 168 desired_targets=['dm'], |
| 169 gyp_source_dir=gyp_source_dir) |
| 167 | 170 |
| 168 # Now that the defines have been written to SkUserConfig and they've been | 171 # Now that the defines have been written to SkUserConfig and they've been |
| 169 # used to skip adding them to the tools makefiles, they are not needed in | 172 # used to skip adding them to the tools makefiles, they are not needed in |
| 170 # Android.mk. Reset DEFINES. | 173 # Android.mk. Reset DEFINES. |
| 171 common.DEFINES.reset() | 174 common.DEFINES.reset() |
| 172 | 175 |
| 173 # Further trim arm_neon_var_dict with arm_var_dict. After this call, | 176 # Further trim arm_neon_var_dict with arm_var_dict. After this call, |
| 174 # arm_var_dict (which will now be the intersection) includes all definitions | 177 # arm_var_dict (which will now be the intersection) includes all definitions |
| 175 # used by both arm and arm + neon, and arm_neon_var_dict will only contain | 178 # used by both arm and arm + neon, and arm_neon_var_dict will only contain |
| 176 # those specific to arm + neon. | 179 # those specific to arm + neon. |
| (...skipping 21 matching lines...) Expand all Loading... |
| 198 'arm64')) | 201 'arm64')) |
| 199 | 202 |
| 200 makefile_writer.write_android_mk(target_dir=target_dir, | 203 makefile_writer.write_android_mk(target_dir=target_dir, |
| 201 common=common, deviations_from_common=deviations_from_common) | 204 common=common, deviations_from_common=deviations_from_common) |
| 202 | 205 |
| 203 finally: | 206 finally: |
| 204 shutil.rmtree(tmp_folder) | 207 shutil.rmtree(tmp_folder) |
| 205 | 208 |
| 206 if __name__ == '__main__': | 209 if __name__ == '__main__': |
| 207 main() | 210 main() |
| OLD | NEW |