1# Copyright (c) 2009 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 'includes': ['cross_compile.gypi'], 7 'target_defaults': { 8 'variables': { 9 'nix_lame%': 0, 10 }, 11 'target_conditions': [ 12 ['nix_lame==1', { 13 'sources/': [ 14 ['exclude', 'lame'], 15 ], 16 }], 17 ], 18 }, 19 'targets': [ 20 { 21 'target_name': 'program', 22 'type': 'executable', 23 'dependencies': [ 24 'program_inc', 25 ], 26 'include_dirs': [ 27 '<(SHARED_INTERMEDIATE_DIR)', 28 ], 29 'sources': [ 30 'program.cc', 31 ], 32 }, 33 { 34 'target_name': 'program_inc', 35 'type': 'none', 36 'dependencies': ['cross_program'], 37 'actions': [ 38 { 39 'action_name': 'program_inc', 40 'inputs': ['<(SHARED_INTERMEDIATE_DIR)/cross_program.fake'], 41 'outputs': ['<(SHARED_INTERMEDIATE_DIR)/cross_program.h'], 42 'action': ['python', 'tochar.py', '<@(_inputs)', '<@(_outputs)'], 43 }, 44 ], 45 # Allows the test to run without hermetic cygwin on windows. 46 'msvs_cygwin_shell': 0, 47 }, 48 { 49 'target_name': 'cross_program', 50 'type': 'none', 51 'variables': { 52 'cross': 1, 53 'nix_lame': 1, 54 }, 55 'dependencies': ['cross_lib'], 56 'sources': [ 57 'test1.cc', 58 'test2.c', 59 'very_lame.cc', 60 '<(SHARED_INTERMEDIATE_DIR)/cross_lib.fake', 61 ], 62 }, 63 { 64 'target_name': 'cross_lib', 65 'type': 'none', 66 'variables': { 67 'cross': 1, 68 'nix_lame': 1, 69 }, 70 'sources': [ 71 'test3.cc', 72 'test4.c', 73 'bogus1.cc', 74 'bogus2.c', 75 'sort_of_lame.cc', 76 ], 77 'sources!': [ 78 'bogus1.cc', 79 'bogus2.c', 80 ], 81 }, 82 ], 83} 84