| # Copyright 2017 The Chromium Authors. All rights reserved. |
| # Use of this source code is governed by a BSD-style license that can be |
| # found in the LICENSE file. |
| |
| component("cpp") { |
| output_name = "service_manager_cpp" |
| |
| sources = [ |
| "binder_registry.h", |
| "connect.h", |
| "connector.cc", |
| "connector.h", |
| "constants.cc", |
| "constants.h", |
| "embedded_instance_manager.cc", |
| "embedded_instance_manager.h", |
| "embedded_service_info.cc", |
| "embedded_service_info.h", |
| "embedded_service_runner.cc", |
| "embedded_service_runner.h", |
| "export.h", |
| "interface_binder.h", |
| "interface_provider.cc", |
| "interface_provider.h", |
| "local_interface_provider.h", |
| "service.cc", |
| "service.h", |
| "service_binding.cc", |
| "service_binding.h", |
| "service_context.cc", |
| "service_context.h", |
| "service_context_ref.cc", |
| "service_context_ref.h", |
| "service_keepalive.cc", |
| "service_keepalive.h", |
| "service_runner.cc", |
| "service_runner.h", |
| ] |
| |
| configs += [ "//build/config/compiler:wexit_time_destructors" ] |
| |
| public_deps = [ |
| ":cpp_types", |
| "//base", |
| "//mojo/public/cpp/bindings", |
| "//mojo/public/cpp/system", |
| "//services/service_manager/public/mojom", |
| "//services/service_manager/public/mojom:constants", |
| "//url", |
| ] |
| |
| defines = [ |
| "IS_SERVICE_MANAGER_CPP_IMPL", |
| |
| # TODO: Use COMPONENT_EXPORT everywhere here and remove this. |
| "SERVICE_MANAGER_PUBLIC_CPP_IMPL", |
| ] |
| } |
| |
| # A component for types which the public interfaces depend on for typemapping. |
| # Unlike ":cpp" above, this cannot itself depend on the main public interfaces |
| # target. |
| component("cpp_types") { |
| output_name = "service_manager_cpp_types" |
| |
| sources = [ |
| "bind_source_info.cc", |
| "bind_source_info.h", |
| "identity.cc", |
| "identity.h", |
| "interface_provider_spec.cc", |
| "interface_provider_spec.h", |
| "service_filter.cc", |
| "service_filter.h", |
| "types_export.h", |
| ] |
| |
| configs += [ "//build/config/compiler:wexit_time_destructors" ] |
| |
| deps = [ |
| "//services/service_manager/public/mojom:constants", |
| ] |
| |
| defines = [ |
| "IS_SERVICE_MANAGER_CPP_TYPES_IMPL", |
| |
| # TODO: Use COMPONENT_EXPORT everywhere and remove this. |
| "SERVICE_MANAGER_PUBLIC_CPP_TYPES_IMPL", |
| ] |
| } |
| |
| component("mojom_traits") { |
| output_name = "service_manager_mojom_traits" |
| sources = [ |
| "service_filter_mojom_traits.cc", |
| "service_filter_mojom_traits.h", |
| ] |
| |
| public_deps = [ |
| ":cpp_types", |
| "//mojo/public/cpp/base:shared_typemap_traits", |
| "//services/service_manager/public/mojom:mojom_shared", |
| ] |
| |
| defines = [ "IS_SERVICE_MANAGER_MOJOM_TRAITS_IMPL" ] |
| } |
| |
| static_library("service_test_support") { |
| testonly = true |
| sources = [ |
| "service_test.cc", |
| "service_test.h", |
| ] |
| |
| public_deps = [ |
| ":cpp", |
| "//testing/gtest", |
| ] |
| |
| deps = [ |
| "//base", |
| "//base/test:test_support", |
| "//mojo/core/embedder", |
| "//mojo/public/cpp/bindings", |
| "//mojo/public/cpp/system", |
| "//services/service_manager/background:lib", |
| "//services/service_manager/public/mojom", |
| ] |
| |
| data_deps = [] |
| } |
| |
| source_set("tests") { |
| testonly = true |
| sources = [ |
| "embedded_instance_manager_unittest.cc", |
| ] |
| deps = [ |
| ":cpp", |
| "//base", |
| "//base/test:test_support", |
| "//testing/gtest", |
| ] |
| } |