| OLD | NEW |
| 1 # Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2011 The Chromium Authors. All rights reserved. |
| 2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
| 3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
| 4 | 4 |
| 5 # This is an gyp include to use YASM for compiling assembly files. | 5 # This is an gyp include to use YASM for compiling assembly files. |
| 6 # | 6 # |
| 7 # Files to be compiled with YASM should have an extension of .asm. | 7 # Files to be compiled with YASM should have an extension of .asm. |
| 8 # | 8 # |
| 9 # There are two variables for this include: | 9 # There are two variables for this include: |
| 10 # yasm_flags : Pass additional flags into YASM. | 10 # yasm_flags : Pass additional flags into YASM. |
| (...skipping 12 matching lines...) Expand all Loading... |
| 23 # 'includes': [ | 23 # 'includes': [ |
| 24 # 'third_party/yasm/yasm_compile.gypi' | 24 # 'third_party/yasm/yasm_compile.gypi' |
| 25 # ], | 25 # ], |
| 26 | 26 |
| 27 { | 27 { |
| 28 'variables': { | 28 'variables': { |
| 29 'yasm_flags': [], | 29 'yasm_flags': [], |
| 30 | 30 |
| 31 'conditions': [ | 31 'conditions': [ |
| 32 [ 'use_system_yasm==0', { | 32 [ 'use_system_yasm==0', { |
| 33 'yasm_path': '<(PRODUCT_DIR)/yasm', | 33 'yasm_path': '<(PRODUCT_DIR)/yasm<(EXECUTABLE_SUFFIX)', |
| 34 }, { | 34 }, { |
| 35 'yasm_path': '<!(which yasm)', | 35 'yasm_path': '<!(which yasm)', |
| 36 }], | 36 }], |
| 37 | 37 |
| 38 # Define yasm_flags that pass into YASM. | 38 # Define yasm_flags that pass into YASM. |
| 39 [ 'os_posix==1 and OS!="mac" and target_arch=="ia32"', { | 39 [ 'os_posix==1 and OS!="mac" and target_arch=="ia32"', { |
| 40 'yasm_flags': [ | 40 'yasm_flags': [ |
| 41 '-felf32', | 41 '-felf32', |
| 42 '-m', 'x86', | 42 '-m', 'x86', |
| 43 ], | 43 ], |
| (...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 90 'outputs': [ | 90 'outputs': [ |
| 91 '<(yasm_output_path)/<(RULE_INPUT_ROOT).<(asm_obj_extension)', | 91 '<(yasm_output_path)/<(RULE_INPUT_ROOT).<(asm_obj_extension)', |
| 92 ], | 92 ], |
| 93 'action': [ | 93 'action': [ |
| 94 '<(yasm_path)', | 94 '<(yasm_path)', |
| 95 '<@(yasm_flags)', | 95 '<@(yasm_flags)', |
| 96 '-o', '<(yasm_output_path)/<(RULE_INPUT_ROOT).<(asm_obj_extension)', | 96 '-o', '<(yasm_output_path)/<(RULE_INPUT_ROOT).<(asm_obj_extension)', |
| 97 '<(RULE_INPUT_PATH)', | 97 '<(RULE_INPUT_PATH)', |
| 98 ], | 98 ], |
| 99 'process_outputs_as_sources': 1, | 99 'process_outputs_as_sources': 1, |
| 100 'message': 'Compile assemly <(RULE_INPUT_PATH).', | 100 'message': 'Compile assembly <(RULE_INPUT_PATH).', |
| 101 }, | 101 }, |
| 102 ], # rules | 102 ], # rules |
| 103 } | 103 } |
| OLD | NEW |