Upstream version 5.34.104.0
[platform/framework/web/crosswalk.git] / src / third_party / angle / src / angle.gypi
1 # Copyright (c) 2012 The ANGLE Project 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     'variables':
7     {
8         'angle_code': 1,
9         'angle_post_build_script%': 0,
10         'angle_relative_src_path%': '',
11     },
12     'includes':
13     [
14         'compiler.gypi',
15         'libGLESv2.gypi',
16         'libEGL.gypi'
17     ],
18     'conditions':
19     [
20         [
21             'OS=="win"',
22             {
23                 'target_defaults':
24                 {
25                    'msvs_cygwin_shell': 0,
26                 },
27                 'targets':
28                 [
29                     {
30                         'target_name': 'commit_id',
31                         'type': 'none',
32                         'actions':
33                         [
34                             {
35                                 'action_name': 'Generate Commit ID Header',
36                                 'message': 'Generating commit ID header...',
37                                 'inputs': [ 'commit_id.bat' ],
38                                 'outputs': ['<(SHARED_INTERMEDIATE_DIR)/commit.h'],
39                                 'action': ['<(angle_relative_src_path)commit_id.bat', '<(SHARED_INTERMEDIATE_DIR)'],
40                             }
41                         ] #actions
42                     },
43                     {
44                         'target_name': 'copy_compiler_dll',
45                         'type': 'none',
46                         'sources': [ 'copy_compiler_dll.bat' ],
47                         'actions':
48                         [
49                             {
50                                 'msvs_cygwin_shell': 0,
51                                 'action_name': 'copy_dll',
52                                 'message': 'Copying D3D Compiler DLL...',
53                                 'inputs': [ 'copy_compiler_dll.bat' ],
54                                 'outputs': [ '<(PRODUCT_DIR)/D3DCompiler_46.dll' ],
55                                 'action': ["<(angle_relative_src_path)copy_compiler_dll.bat", "$(PlatformName)", "<(windows_sdk_path)", "<(PRODUCT_DIR)" ],
56                             }
57                         ] #actions
58                     },
59                 ] # targets
60             },
61         ],
62         [
63             'angle_post_build_script!=0 and OS=="win"',
64             {
65                 'target_defaults':
66                 {
67                    'msvs_cygwin_shell': 0,
68                 },
69                 'targets':
70                 [
71                     {
72                         'target_name': 'post_build',
73                         'type': 'none',
74                         'dependencies': [ 'libGLESv2', 'libEGL' ],
75                         'actions':
76                         [
77                             {
78                                 'action_name': 'ANGLE Post-Build Script',
79                                 'message': 'Running <(angle_post_build_script)...',
80                                 'inputs': [ '<(angle_post_build_script)', '<!@(["python", "<(angle_post_build_script)", "inputs", "<(CONFIGURATION_NAME)", "$(PlatformName)", "<(PRODUCT_DIR)"])' ],
81                                 'outputs': [ '<!@(python <(angle_post_build_script) outputs "<(CONFIGURATION_NAME)" "$(PlatformName)" "<(PRODUCT_DIR)")' ],
82                                 'action': ['python', '<(angle_post_build_script)', 'run', '<(CONFIGURATION_NAME)', '$(PlatformName)', '<(PRODUCT_DIR)'],
83                             }
84                         ] #actions
85                     }
86                 ] # targets
87             }
88         ],
89         [
90             'OS!="win"',
91             {
92                 'targets':
93                 [
94                     {
95                         'target_name': 'commit_id',
96                         'type': 'none',
97                         'actions':
98                         [
99                             {
100                                 'action_name': 'Generate Commit ID Header',
101                                 'message': 'Generating commit ID header...',
102                                 'inputs': [ 'commit_id.py' ],
103                                 'outputs': ['<(SHARED_INTERMEDIATE_DIR)/commit.h'],
104                                 'action': ['python', '<(angle_relative_src_path)commit_id.py', '<(SHARED_INTERMEDIATE_DIR)/commit.h'],
105                             }
106                         ] #actions
107                     },
108                 ]
109             }
110         ],
111     ] # conditions
112 }