Home | History | Annotate | Download | only in md5sum
      1 # Copyright (c) 2012 The Chromium Authors. All rights reserved.
      2 # Use of this source code is governed by a BSD-style license that can be
      3 # found in the LICENSE file.
      4 
      5 {
      6   'targets': [
      7     {
      8       # GN: //tools/android/md5sum:md5sum
      9       'target_name': 'md5sum',
     10       'type': 'none',
     11       'dependencies': [
     12         'md5sum_stripped_device_bin',
     13         'md5sum_bin_host#host',
     14       ],
     15       # For the component build, ensure dependent shared libraries are stripped
     16       # and put alongside md5sum to simplify pushing to the device.
     17       'variables': {
     18          'output_dir': '<(PRODUCT_DIR)/md5sum_dist/',
     19          'native_binary': '<(PRODUCT_DIR)/md5sum_bin',
     20       },
     21       'includes': ['../../../build/android/native_app_dependencies.gypi'],
     22     },
     23     {
     24       # GN: //tools/android/md5sum:md5sum_bin($default_toolchain)
     25       'target_name': 'md5sum_device_bin',
     26       'type': 'executable',
     27       'dependencies': [
     28         '../../../base/base.gyp:base',
     29       ],
     30       'include_dirs': [
     31         '../../..',
     32       ],
     33       'sources': [
     34         'md5sum.cc',
     35       ],
     36       'conditions': [
     37         [ 'order_profiling!=0 and OS=="android"', {
     38             'dependencies': [ '../../../tools/cygprofile/cygprofile.gyp:cygprofile', ],
     39         }],
     40       ],
     41     },
     42     {
     43       # GN: //tools/android/md5sum:md5sum_prepare_dist
     44       'target_name': 'md5sum_stripped_device_bin',
     45       'type': 'none',
     46       'dependencies': [
     47         'md5sum_device_bin',
     48       ],
     49       'actions': [
     50         {
     51           'action_name': 'strip_md5sum_device_bin',
     52           'inputs': ['<(PRODUCT_DIR)/md5sum_device_bin'],
     53           'outputs': ['<(PRODUCT_DIR)/md5sum_bin'],
     54           'action': [
     55             '<(android_strip)',
     56             '--strip-unneeded',
     57             '<@(_inputs)',
     58             '-o',
     59             '<@(_outputs)',
     60           ],
     61         },
     62       ],
     63     },
     64     # Same binary but for the host rather than the device.
     65     {
     66       # GN: //tools/android/md5sum:md5sum_copy_host($default_toolchain)
     67       'target_name': 'md5sum_bin_host',
     68       'toolsets': ['host'],
     69       'type': 'executable',
     70       'dependencies': [
     71         '../../../base/base.gyp:base',
     72       ],
     73       'include_dirs': [
     74         '../../..',
     75       ],
     76       'sources': [
     77         'md5sum.cc',
     78       ],
     79     },
     80   ],
     81 }
     82