1 # Copyright 2013 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.
5 # This file is meant to be included into an action to provide a rule that dexes
6 # compiled java files. If proguard_enabled == "true" and CONFIGURATION_NAME ==
7 # "Release", then it will dex the proguard_enabled_input_path instead of the
8 # normal dex_input_paths/dex_generated_input_paths.
10 # To use this, create a gyp target with the following form:
12 # 'action_name': 'some name for the action'
15 # 'dex_input_paths': [ 'files to dex (when proguard is not used) and add to input paths' ],
16 # 'dex_generated_input_dirs': [ 'dirs that contain generated files to dex' ],
18 # # For targets that use proguard:
19 # 'proguard_enabled': 'true',
20 # 'proguard_enabled_input_path': 'path to dex when using proguard',
22 # 'includes': [ 'relative/path/to/dex_action.gypi' ],
28 'message': 'Creating dex file: <(output_path)',
30 'dex_input_paths': [],
31 'dex_generated_input_dirs': [],
32 'proguard_enabled%': 'false',
33 'proguard_enabled_input_path%': '',
35 'dex_additional_options': [],
38 '<(DEPTH)/build/android/gyp/util/build_utils.py',
39 '<(DEPTH)/build/android/gyp/util/md5_check.py',
40 '<(DEPTH)/build/android/gyp/dex.py',
41 '>@(dex_input_paths)',
45 '<(output_path).inputs',
48 'python', '<(DEPTH)/build/android/gyp/dex.py',
49 '--dex-path=<(output_path)',
50 '--android-sdk-tools=<(android_sdk_tools)',
51 '--output-directory=<(PRODUCT_DIR)',
52 '--configuration-name=<(CONFIGURATION_NAME)',
53 '--proguard-enabled=>(proguard_enabled)',
54 '--proguard-enabled-input-path=<(proguard_enabled_input_path)',
55 '--no-locals=>(dex_no_locals)',
56 '>@(dex_additional_options)',
57 '>@(dex_input_paths)',
58 '>@(dex_generated_input_dirs)',