OLD | NEW |
(Empty) | |
| 1 # Copyright 2013 Google Inc. 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 'conditions': [ |
| 7 ['OS=="linux"', { |
| 8 'target_defaults': { |
| 9 'cflags': ['-fPIC'], |
| 10 }, |
| 11 }], |
| 12 ], |
| 13 'targets': [ |
| 14 { |
| 15 'target_name': 'lib', |
| 16 'type': 'shared_library', |
| 17 'toolsets': [ |
| 18 'host' |
| 19 ], |
| 20 'defines': [ |
| 21 'LIB_IMPLEMENTATION', |
| 22 ], |
| 23 'sources': [ |
| 24 'lib.cc', |
| 25 'lib.h', |
| 26 ], |
| 27 }, |
| 28 { |
| 29 'target_name': 'tool', |
| 30 'type': 'executable', |
| 31 'toolsets': [ |
| 32 'host' |
| 33 ], |
| 34 'dependencies': [ |
| 35 'lib', |
| 36 ], |
| 37 'sources': [ |
| 38 'tool.cc', |
| 39 ], |
| 40 }, |
| 41 { |
| 42 'target_name': 'prog', |
| 43 'type': 'executable', |
| 44 'dependencies': [ |
| 45 'tool#host', |
| 46 ], |
| 47 'actions': [ |
| 48 { |
| 49 'action_name': 'gen', |
| 50 'inputs': [ |
| 51 '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)tool<(EXECUTABLE_SUFFIX)', |
| 52 ], |
| 53 'outputs': [ |
| 54 'prog.cc', |
| 55 ], |
| 56 'process_outputs_as_sources': 1, |
| 57 'action': [ |
| 58 '<@(_inputs)', |
| 59 '<@(_outputs)', |
| 60 ], |
| 61 }, |
| 62 ], |
| 63 }, |
| 64 ], |
| 65 } |
OLD | NEW |