OLD | NEW |
1 # -*- python -*- | 1 # -*- python -*- |
2 # Copyright 2010 The Native Client Authors. All rights reserved. | 2 # Copyright 2010 The Native Client Authors. All rights reserved. |
3 # Use of this source code is governed by a BSD-style license that can | 3 # Use of this source code is governed by a BSD-style license that can |
4 # be found in the LICENSE file. | 4 # be found in the LICENSE file. |
5 | 5 |
6 # The source files (.cc and .h) listed in this file are maintained by the | |
7 # script ./update-scons.py. Update $SOURCE_ROOT/ppapi and run the script | |
8 # ./update-scons.py to update all of the source files listed here. | |
9 | |
10 # update-scons.py reads the .scons files in this directory. It replaces all | |
11 # of the lines between the starting marker and the ending marker with the | |
12 # corresponding list of files from the given gyp file. | |
13 # | |
14 # The starting marker format is: | |
15 # # From GYP_FILE_NAME:TARGET:REGEXP | |
16 # The ending marker format is: | |
17 # # End GYP_FILE_NAME | |
18 # | |
19 # For example, if this exists in the .scons file: | |
20 # # From ppapi.gyp:ppapi_c:.*\.h | |
21 # ... | |
22 # # End ppapi.gyp | |
23 # | |
24 # then this script will remove all of the lines between the starting marker and | |
25 # the ending marker. It will then find the 'ppapi_c' target in the ppapi.gyp | |
26 # file. It will find all 'sources' for that target that match the regular | |
27 # expression '.*\.h' and will insert each of those source files in between the | |
28 # two markers. | |
29 | |
30 import os | 6 import os |
| 7 import gyp_extract |
31 | 8 |
32 Import('env') | 9 Import('env') |
33 | 10 |
34 # Underlay $SOURCE_ROOT/ppapi in this directory. | 11 # Underlay $SOURCE_ROOT/ppapi in this directory. |
35 Dir('.').addRepository(Dir('#/../ppapi')) | 12 Dir('.').addRepository(Dir('#/../ppapi')) |
36 | 13 |
37 cpp_sources = [ | |
38 # Updated automatically by update-scons.py. | |
39 # From ppapi_cpp.gypi:ppapi_cpp_objects:.*\.cc | |
40 'cpp/audio.cc', | |
41 'cpp/audio_config.cc', | |
42 'cpp/core.cc', | |
43 'cpp/graphics_2d.cc', | |
44 'cpp/image_data.cc', | |
45 'cpp/instance.cc', | |
46 'cpp/module.cc', | |
47 'cpp/paint_aggregator.cc', | |
48 'cpp/paint_manager.cc', | |
49 'cpp/rect.cc', | |
50 'cpp/resource.cc', | |
51 'cpp/url_loader.cc', | |
52 'cpp/url_request_info.cc', | |
53 'cpp/url_response_info.cc', | |
54 'cpp/var.cc', | |
55 'cpp/dev/buffer_dev.cc', | |
56 'cpp/dev/context_3d_dev.cc', | |
57 'cpp/dev/directory_entry_dev.cc', | |
58 'cpp/dev/directory_reader_dev.cc', | |
59 'cpp/dev/file_chooser_dev.cc', | |
60 'cpp/dev/file_io_dev.cc', | |
61 'cpp/dev/file_ref_dev.cc', | |
62 'cpp/dev/file_system_dev.cc', | |
63 'cpp/dev/find_dev.cc', | |
64 'cpp/dev/font_dev.cc', | |
65 'cpp/dev/fullscreen_dev.cc', | |
66 'cpp/dev/graphics_3d_client_dev.cc', | |
67 'cpp/dev/graphics_3d_dev.cc', | |
68 'cpp/dev/printing_dev.cc', | |
69 'cpp/dev/scrollbar_dev.cc', | |
70 'cpp/dev/selection_dev.cc', | |
71 'cpp/dev/surface_3d_dev.cc', | |
72 'cpp/dev/transport_dev.cc', | |
73 'cpp/dev/url_util_dev.cc', | |
74 'cpp/dev/video_decoder_dev.cc', | |
75 'cpp/dev/widget_client_dev.cc', | |
76 'cpp/dev/widget_dev.cc', | |
77 'cpp/dev/zoom_dev.cc', | |
78 'cpp/dev/scriptable_object_deprecated.cc', | |
79 # End ppapi_cpp.gypi | |
80 # Updated automatically by update-scons.py. | |
81 # From ppapi_cpp.gypi:ppapi_cpp:.*\.cc | |
82 'cpp/ppp_entrypoints.cc', | |
83 # End ppapi_cpp.gypi | |
84 ] | |
85 | 14 |
| 15 # Load ppapi_cpp.gypi |
| 16 ppapi_cpp_gypi = gyp_extract.LoadGypFile( |
| 17 env.File('#/../ppapi/ppapi_cpp.gypi').path) |
| 18 |
| 19 # From ppapi_cpp.gypi:ppapi_cpp_objects:.*\.cc |
| 20 # From ppapi_cpp.gypi:ppapi_cpp:.*\.cc |
| 21 cpp_sources = ( |
| 22 gyp_extract.GypTargetSources( |
| 23 ppapi_cpp_gypi, 'ppapi_cpp_objects', '.*\.cc') + |
| 24 gyp_extract.GypTargetSources( |
| 25 ppapi_cpp_gypi, 'ppapi_cpp', '.*\.cc') |
| 26 ) |
86 env.ComponentLibrary('ppapi_cpp', cpp_sources) | 27 env.ComponentLibrary('ppapi_cpp', cpp_sources) |
87 | 28 |
| 29 |
88 env.Append(CPPPATH=[ | 30 env.Append(CPPPATH=[ |
89 '$SOURCE_ROOT/ppapi/lib/gl/gles2']) | 31 '$SOURCE_ROOT/ppapi/lib/gl/gles2']) |
90 | 32 |
91 gles2_sources = [ | 33 # Load ppapi_gl.gypi |
92 # Updated automatically by update-scons.py. | 34 ppapi_gl_gypi = gyp_extract.LoadGypFile( |
93 # From ppapi_gl.gypi:ppapi_gles2:.*\.c | 35 env.File('#/../ppapi/ppapi_gl.gypi').path) |
94 'lib/gl/gles2/gl2ext_ppapi.c', | |
95 'lib/gl/gles2/gles2.c', | |
96 # End ppapi_gl.gypi | |
97 ] | |
98 | 36 |
| 37 # From ppapi_gl.gypi:ppapi_gles2:.*\.c |
| 38 gles2_sources = gyp_extract.GypTargetSources( |
| 39 ppapi_gl_gypi, 'ppapi_gles2', '.*\.c') |
99 env.ComponentLibrary('ppapi_gles2', gles2_sources) | 40 env.ComponentLibrary('ppapi_gles2', gles2_sources) |
100 | 41 |
101 c_headers = [ | |
102 # Updated automatically by update-scons.py. | |
103 # From ppapi_cpp.gypi:ppapi_c:c/[^/]*\.h | |
104 'c/pp_bool.h', | |
105 'c/pp_completion_callback.h', | |
106 'c/pp_errors.h', | |
107 'c/pp_input_event.h', | |
108 'c/pp_instance.h', | |
109 'c/pp_macros.h', | |
110 'c/pp_module.h', | |
111 'c/pp_point.h', | |
112 'c/pp_rect.h', | |
113 'c/pp_resource.h', | |
114 'c/pp_size.h', | |
115 'c/pp_stdint.h', | |
116 'c/pp_time.h', | |
117 'c/pp_var.h', | |
118 'c/ppb.h', | |
119 'c/ppb_audio.h', | |
120 'c/ppb_audio_config.h', | |
121 'c/ppb_core.h', | |
122 'c/ppb_class.h', | |
123 'c/ppb_graphics_2d.h', | |
124 'c/ppb_image_data.h', | |
125 'c/ppb_instance.h', | |
126 'c/ppb_url_loader.h', | |
127 'c/ppb_url_request_info.h', | |
128 'c/ppb_url_response_info.h', | |
129 'c/ppb_var.h', | |
130 'c/ppp.h', | |
131 'c/ppp_instance.h', | |
132 # End ppapi_cpp.gypi | |
133 ] | |
134 | 42 |
135 c_dev_headers = [ | 43 # From ppapi_cpp.gypi:ppapi_c:c/[^/]*\.h |
136 # Updated automatically by update-scons.py. | 44 c_headers = gyp_extract.GypTargetSources( |
137 # From ppapi_cpp.gypi:ppapi_c:c/dev/[^/]*\.h | 45 ppapi_cpp_gypi, 'ppapi_c', 'c/[^/]*\.h') |
138 'c/dev/pp_cursor_type_dev.h', | |
139 'c/dev/pp_file_info_dev.h', | |
140 'c/dev/pp_graphics_3d_dev.h', | |
141 'c/dev/pp_video_dev.h', | |
142 'c/dev/ppb_buffer_dev.h', | |
143 'c/dev/ppb_char_set_dev.h', | |
144 'c/dev/ppb_context_3d_dev.h', | |
145 'c/dev/ppb_context_3d_trusted_dev.h', | |
146 'c/dev/ppb_cursor_control_dev.h', | |
147 'c/dev/ppb_directory_reader_dev.h', | |
148 'c/dev/ppb_file_chooser_dev.h', | |
149 'c/dev/ppb_file_io_dev.h', | |
150 'c/dev/ppb_file_io_trusted_dev.h', | |
151 'c/dev/ppb_file_ref_dev.h', | |
152 'c/dev/ppb_file_system_dev.h', | |
153 'c/dev/ppb_find_dev.h', | |
154 'c/dev/ppb_font_dev.h', | |
155 'c/dev/ppb_fullscreen_dev.h', | |
156 'c/dev/ppb_graphics_3d_dev.h', | |
157 'c/dev/ppb_opengles_dev.h', | |
158 'c/dev/ppb_scrollbar_dev.h', | |
159 'c/dev/ppb_surface_3d_dev.h', | |
160 'c/dev/ppb_testing_dev.h', | |
161 'c/dev/ppb_transport_dev.h', | |
162 'c/dev/ppb_url_util_dev.h', | |
163 'c/dev/ppb_video_decoder_dev.h', | |
164 'c/dev/ppb_widget_dev.h', | |
165 'c/dev/ppb_zoom_dev.h', | |
166 'c/dev/ppp_cursor_control_dev.h', | |
167 'c/dev/ppp_find_dev.h', | |
168 'c/dev/ppp_graphics_3d_dev.h', | |
169 'c/dev/ppp_scrollbar_dev.h', | |
170 'c/dev/ppp_selection_dev.h', | |
171 'c/dev/ppp_printing_dev.h', | |
172 'c/dev/ppp_widget_dev.h', | |
173 'c/dev/ppp_zoom_dev.h', | |
174 'c/dev/deprecated_bool.h', | |
175 'c/dev/ppb_var_deprecated.h', | |
176 'c/dev/ppp_class_deprecated.h', | |
177 # End ppapi_cpp.gypi | |
178 ] | |
179 | 46 |
180 cpp_headers = [ | 47 # From ppapi_cpp.gypi:ppapi_c:c/dev/[^/]*\.h |
181 # Updated automatically by update-scons.py. | 48 c_dev_headers = gyp_extract.GypTargetSources( |
182 # From ppapi_cpp.gypi:ppapi_cpp_objects:cpp/[^/]*\.h | 49 ppapi_cpp_gypi, 'ppapi_c', 'c/dev/[^/]*\.h') |
183 'cpp/audio.h', | |
184 'cpp/audio_config.h', | |
185 'cpp/common.h', | |
186 'cpp/completion_callback.h', | |
187 'cpp/core.h', | |
188 'cpp/graphics_2d.h', | |
189 'cpp/image_data.h', | |
190 'cpp/instance.h', | |
191 'cpp/logging.h', | |
192 'cpp/module.h', | |
193 'cpp/module_impl.h', | |
194 'cpp/non_thread_safe_ref_count.h', | |
195 'cpp/paint_aggregator.h', | |
196 'cpp/paint_manager.h', | |
197 'cpp/point.h', | |
198 'cpp/rect.h', | |
199 'cpp/resource.h', | |
200 'cpp/size.h', | |
201 'cpp/url_loader.h', | |
202 'cpp/url_request_info.h', | |
203 'cpp/url_response_info.h', | |
204 'cpp/var.h', | |
205 # End ppapi_cpp.gypi | |
206 # Updated automatically by update-scons.py. | |
207 # From ppapi_cpp.gypi:ppapi_cpp:cpp/[^/]*\.h | |
208 'cpp/module_embedder.h', | |
209 # End ppapi_cpp.gypi | |
210 ] | |
211 | 50 |
212 cpp_dev_headers = [ | 51 # From ppapi_cpp.gypi:ppapi_cpp_objects:cpp/[^/]*\.h |
213 # Updated automatically by update-scons.py. | 52 # From ppapi_cpp.gypi:ppapi_cpp:cpp/[^/]*\.h |
214 # From ppapi_cpp.gypi:ppapi_cpp_objects:cpp/dev/[^/]*\.h | 53 cpp_headers = ( |
215 'cpp/dev/buffer_dev.h', | 54 gyp_extract.GypTargetSources( |
216 'cpp/dev/context_3d_dev.h', | 55 ppapi_cpp_gypi, 'ppapi_cpp_objects', 'cpp/[^/]*\.h') + |
217 'cpp/dev/directory_entry_dev.h', | 56 gyp_extract.GypTargetSources( |
218 'cpp/dev/directory_reader_dev.h', | 57 ppapi_cpp_gypi, 'ppapi_cpp', 'cpp/[^/]*\.h') |
219 'cpp/dev/file_chooser_dev.h', | 58 ) |
220 'cpp/dev/file_io_dev.h', | |
221 'cpp/dev/file_ref_dev.h', | |
222 'cpp/dev/file_system_dev.h', | |
223 'cpp/dev/find_dev.h', | |
224 'cpp/dev/font_dev.h', | |
225 'cpp/dev/fullscreen_dev.h', | |
226 'cpp/dev/graphics_3d_client_dev.h', | |
227 'cpp/dev/graphics_3d_dev.h', | |
228 'cpp/dev/printing_dev.h', | |
229 'cpp/dev/scrollbar_dev.h', | |
230 'cpp/dev/selection_dev.h', | |
231 'cpp/dev/surface_3d_dev.h', | |
232 'cpp/dev/transport_dev.h', | |
233 'cpp/dev/url_util_dev.h', | |
234 'cpp/dev/video_decoder_dev.h', | |
235 'cpp/dev/widget_client_dev.h', | |
236 'cpp/dev/widget_dev.h', | |
237 'cpp/dev/zoom_dev.h', | |
238 'cpp/dev/scriptable_object_deprecated.h', | |
239 # End ppapi_cpp.gypi | |
240 ] | |
241 | 59 |
242 gles2_headers = [ | 60 # From ppapi_cpp.gypi:ppapi_cpp_objects:cpp/dev/[^/]*\.h |
243 # Updated automatically by update-scons.py. | 61 cpp_dev_headers = gyp_extract.GypTargetSources( |
244 # From ppapi_gl.gypi:ppapi_gles2:.*\.h | 62 ppapi_cpp_gypi, 'ppapi_cpp_objects', 'cpp/dev/[^/]*\.h') |
245 'lib/gl/gles2/gl2ext_ppapi.h', | 63 |
246 # End ppapi_gl.gypi | 64 # From ppapi_gl.gypi:ppapi_gles2:.*\.h |
247 ] | 65 gles2_headers = gyp_extract.GypTargetSources( |
| 66 ppapi_gl_gypi, 'ppapi_gles2', '.*\.h') |
| 67 |
248 | 68 |
249 c_header_install = env.AddHeaderToSdk( | 69 c_header_install = env.AddHeaderToSdk( |
250 ['$SOURCE_ROOT/ppapi/' + h for h in c_headers], os.path.join('ppapi', 'c')) | 70 ['$SOURCE_ROOT/ppapi/' + h for h in c_headers], os.path.join('ppapi', 'c')) |
251 c_dev_header_install = env.AddHeaderToSdk( | 71 c_dev_header_install = env.AddHeaderToSdk( |
252 ['$SOURCE_ROOT/ppapi/' + h for h in c_dev_headers], | 72 ['$SOURCE_ROOT/ppapi/' + h for h in c_dev_headers], |
253 os.path.join('ppapi', 'c', 'dev')) | 73 os.path.join('ppapi', 'c', 'dev')) |
254 cpp_header_install = env.AddHeaderToSdk( | 74 cpp_header_install = env.AddHeaderToSdk( |
255 ['$SOURCE_ROOT/ppapi/' + h for h in cpp_headers], | 75 ['$SOURCE_ROOT/ppapi/' + h for h in cpp_headers], |
256 os.path.join('ppapi', 'cpp')) | 76 os.path.join('ppapi', 'cpp')) |
257 cpp_dev_header_install = env.AddHeaderToSdk( | 77 cpp_dev_header_install = env.AddHeaderToSdk( |
(...skipping 24 matching lines...) Expand all Loading... |
282 ['$SOURCE_ROOT/ppapi/' + h for h in gles2_headers], | 102 ['$SOURCE_ROOT/ppapi/' + h for h in gles2_headers], |
283 os.path.join('ppapi', 'gles2')) | 103 os.path.join('ppapi', 'gles2')) |
284 env.AddLibraryToSdk(['ppapi_gles2']) | 104 env.AddLibraryToSdk(['ppapi_gles2']) |
285 env.Requires('ppapi_gles2', [ | 105 env.Requires('ppapi_gles2', [ |
286 egl_header_install, | 106 egl_header_install, |
287 gles2_header_install, | 107 gles2_header_install, |
288 khr_header_install, | 108 khr_header_install, |
289 ppapi_gles2_header_install, | 109 ppapi_gles2_header_install, |
290 ]) | 110 ]) |
291 | 111 |
OLD | NEW |