| OLD | NEW |
| 1 # Copyright 2014 The Chromium Authors. All rights reserved. | 1 # Copyright 2014 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 import("../../mojo_sdk.gni") | 5 import("../../mojo_sdk.gni") |
| 6 import("../../mojo_application.gni") | 6 import("../../mojo_application.gni") |
| 7 | 7 |
| 8 mojo_sdk_source_set("system") { | 8 mojo_sdk_source_set("system_thunks") { |
| 9 sources = [ | 9 sources = [ |
| 10 "system_thunks.c", | 10 "system_thunks.c", |
| 11 "system_thunks.h", | 11 "system_thunks.h", |
| 12 ] | 12 ] |
| 13 mojo_sdk_public_deps = [ "mojo/public/c:system" ] | 13 mojo_sdk_public_deps = [ "mojo/public/c:system" ] |
| 14 | 14 |
| 15 # The GYP target analogous to this one builds this code into a | 15 # The GYP target analogous to this one builds this code into a |
| 16 # static library. When building for Android, both the GYP and GN | 16 # static library. When building for Android, both the GYP and GN |
| 17 # builds add --exclude-libs=ALL globally, which means that all | 17 # builds add --exclude-libs=ALL globally, which means that all |
| 18 # symbols in static libraries are excluded from export. That's a | 18 # symbols in static libraries are excluded from export. That's a |
| 19 # problem, as code outside this target needs to be able to call | 19 # problem, as code outside this target needs to be able to call |
| 20 # MojoSetSystemThunks(). Therefore, the GYP target needs to specifiy | 20 # MojoSetSystemThunks(). Therefore, the GYP target needs to specifiy |
| 21 # that all dependent targets remove that link flag. Since GN uses a | 21 # that all dependent targets remove that link flag. Since GN uses a |
| 22 # source_set here, this flag change is not needed. | 22 # source_set here, this flag change is not needed. |
| 23 } | 23 } |
| 24 | 24 |
| 25 mojo_sdk_source_set("gles2") { | 25 mojo_sdk_source_set("gles2_thunks") { |
| 26 sources = [ | 26 sources = [ |
| 27 "gles2_impl_chromium_bind_uniform_location_thunks.c", | 27 "gles2_impl_chromium_bind_uniform_location_thunks.c", |
| 28 "gles2_impl_chromium_bind_uniform_location_thunks.h", | 28 "gles2_impl_chromium_bind_uniform_location_thunks.h", |
| 29 "gles2_impl_chromium_map_sub_thunks.c", | 29 "gles2_impl_chromium_map_sub_thunks.c", |
| 30 "gles2_impl_chromium_map_sub_thunks.h", | 30 "gles2_impl_chromium_map_sub_thunks.h", |
| 31 "gles2_impl_chromium_miscellaneous_thunks.c", | 31 "gles2_impl_chromium_miscellaneous_thunks.c", |
| 32 "gles2_impl_chromium_miscellaneous_thunks.h", | 32 "gles2_impl_chromium_miscellaneous_thunks.h", |
| 33 "gles2_impl_chromium_resize_thunks.c", | 33 "gles2_impl_chromium_resize_thunks.c", |
| 34 "gles2_impl_chromium_resize_thunks.h", | 34 "gles2_impl_chromium_resize_thunks.h", |
| 35 "gles2_impl_chromium_sync_point_thunks.c", | 35 "gles2_impl_chromium_sync_point_thunks.c", |
| (...skipping 11 matching lines...) Expand all Loading... |
| 47 "gles2_impl_ext_texture_storage_thunks.c", | 47 "gles2_impl_ext_texture_storage_thunks.c", |
| 48 "gles2_impl_ext_texture_storage_thunks.h", | 48 "gles2_impl_ext_texture_storage_thunks.h", |
| 49 "gles2_impl_khr_blend_equation_advanced_thunks.c", | 49 "gles2_impl_khr_blend_equation_advanced_thunks.c", |
| 50 "gles2_impl_khr_blend_equation_advanced_thunks.h", | 50 "gles2_impl_khr_blend_equation_advanced_thunks.h", |
| 51 "gles2_impl_oes_vertex_array_object_thunks.c", | 51 "gles2_impl_oes_vertex_array_object_thunks.c", |
| 52 "gles2_impl_oes_vertex_array_object_thunks.h", | 52 "gles2_impl_oes_vertex_array_object_thunks.h", |
| 53 "gles2_impl_thunks.c", | 53 "gles2_impl_thunks.c", |
| 54 "gles2_impl_thunks.h", | 54 "gles2_impl_thunks.h", |
| 55 ] | 55 ] |
| 56 | 56 |
| 57 defines = [ "MOJO_GLES2_IMPLEMENTATION" ] | |
| 58 | |
| 59 configs = [ "../../c/gpu:gpu_configs" ] | |
| 60 | |
| 61 mojo_sdk_deps = [ | 57 mojo_sdk_deps = [ |
| 62 "mojo/public/c:environment", | 58 "mojo/public/c:environment", |
| 63 "mojo/public/c:system", | 59 "mojo/public/c:system", |
| 64 "mojo/public/c/gpu:GLES2", | |
| 65 ] | 60 ] |
| 66 } | |
| 67 | 61 |
| 68 mojo_sdk_source_set("gpu_thunks") { | 62 mojo_sdk_public_deps = [ "mojo/public/c:GLES2" ] |
| 69 sources = [] | |
| 70 } | 63 } |
| 71 | 64 |
| 72 mojo_sdk_source_set("mgl_thunks") { | 65 mojo_sdk_source_set("mgl_thunks") { |
| 73 sources = [ | 66 sources = [ |
| 74 "mgl_echo_thunks.c", | 67 "mgl_echo_thunks.c", |
| 75 "mgl_echo_thunks.h", | 68 "mgl_echo_thunks.h", |
| 76 "mgl_signal_sync_point_thunks.c", | 69 "mgl_signal_sync_point_thunks.c", |
| 77 "mgl_signal_sync_point_thunks.h", | 70 "mgl_signal_sync_point_thunks.h", |
| 78 "mgl_thunks.c", | 71 "mgl_thunks.c", |
| 79 "mgl_thunks.h", | 72 "mgl_thunks.h", |
| 80 ] | 73 ] |
| 81 | 74 |
| 82 mojo_sdk_deps = [ | 75 mojo_sdk_public_deps = [ |
| 83 "mojo/public/c/gpu:MGL", | 76 "mojo/public/c:MGL", |
| 84 "mojo/public/c/gpu:MGL_signal_sync_point", | 77 "mojo/public/c:MGL_signal_sync_point", |
| 85 "mojo/public/c/gpu:MGL_echo", | 78 "mojo/public/c:MGL_echo", |
| 86 ] | 79 ] |
| 87 } | 80 } |
| 88 | 81 |
| 89 mojo_sdk_source_set("mgl_onscreen_thunks") { | 82 mojo_sdk_source_set("mgl_onscreen_thunks") { |
| 90 sources = [ | 83 sources = [ |
| 91 "mgl_onscreen_thunks.c", | 84 "mgl_onscreen_thunks.c", |
| 92 "mgl_onscreen_thunks.h", | 85 "mgl_onscreen_thunks.h", |
| 93 ] | 86 ] |
| 94 | 87 |
| 95 mojo_sdk_deps = [ "mojo/public/c/gpu:MGL_onscreen" ] | 88 mojo_sdk_public_deps = [ "mojo/public/c:MGL_onscreen" ] |
| 96 } | 89 } |
| 97 | 90 |
| 98 mojo_sdk_source_set("platform_handle") { | 91 mojo_sdk_source_set("platform_handle") { |
| 99 sources = [ | 92 sources = [ |
| 100 "platform_handle_private_thunks.c", | 93 "platform_handle_private_thunks.c", |
| 101 "platform_handle_private_thunks.h", | 94 "platform_handle_private_thunks.h", |
| 102 ] | 95 ] |
| 103 | 96 |
| 104 mojo_sdk_deps = [ | 97 mojo_sdk_public_deps = [ "mojo/public/platform/native:platform_handle_api" ] |
| 105 "mojo/public/platform/native:platform_handle_api", | |
| 106 "mojo/public/c:system", | |
| 107 ] | |
| 108 } | 98 } |
| 109 | 99 |
| 110 # Only targets that are calling the thunks should depend upon this. | 100 # Only targets that are calling the thunks should depend upon this. |
| 111 mojo_sdk_source_set("platform_handle_api") { | 101 mojo_sdk_source_set("platform_handle_api") { |
| 112 sources = [ | 102 sources = [ |
| 113 "platform_handle_private.h", | 103 "platform_handle_private.h", |
| 114 ] | 104 ] |
| 105 |
| 115 mojo_sdk_public_deps = [ "mojo/public/c:system" ] | 106 mojo_sdk_public_deps = [ "mojo/public/c:system" ] |
| 116 } | 107 } |
| 117 | 108 |
| 118 mojo_native_application("platform_handle_private_apptest") { | 109 mojo_native_application("platform_handle_private_apptest") { |
| 119 output_name = "platform_handle_private_apptests" | 110 output_name = "platform_handle_private_apptests" |
| 120 | 111 |
| 121 testonly = true | 112 testonly = true |
| 122 | 113 |
| 123 sources = [ | 114 sources = [ |
| 124 "platform_handle_private_apptest.cc", | 115 "platform_handle_private_apptest.cc", |
| 125 ] | 116 ] |
| 126 | 117 |
| 127 deps = [ | 118 deps = [ |
| 128 ":platform_handle", | 119 ":platform_handle", |
| 129 ":platform_handle_api", | 120 ":platform_handle_api", |
| 130 "../../cpp/application:standalone", | 121 "../../cpp/application:standalone", |
| 131 "../../cpp/application:test_support_standalone", | 122 "../../cpp/application:test_support_standalone", |
| 132 "../../cpp/environment", | 123 "../../cpp/environment", |
| 133 "../../cpp/system", | 124 "../../cpp/system", |
| 134 ] | 125 ] |
| 135 } | 126 } |
| 136 | 127 |
| 137 group("tests") { | 128 group("tests") { |
| 138 testonly = true | 129 testonly = true |
| 139 | 130 |
| 140 deps = [ | 131 deps = [ |
| 141 ":platform_handle_private_apptest", | 132 ":platform_handle_private_apptest", |
| 142 ] | 133 ] |
| 143 } | 134 } |
| OLD | NEW |