| # Copyright 2015 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. |
| |
| import("//build/module_args/mojo.gni") |
| import("$mojo_sdk_root/mojo/public/mojo_application.gni") |
| import("$mojo_sdk_root/mojo/public/mojo_sdk.gni") |
| |
| mojo_sdk_source_set("mojio") { |
| # TODO(vtl): This is needed because mojo_sdk.gni doesn't understand relative |
| # dependencies (so without this we can't depend on our interfaces!). |
| restrict_external_deps = false |
| |
| public_configs = [ "../../../public/build/config:mojo_services" ] |
| |
| sources = [ |
| "lib/directory_wrapper.cc", |
| "lib/directory_wrapper.h", |
| "lib/errno_impl.h", |
| "lib/fd_impl.h", |
| "lib/fd_table.cc", |
| "lib/fd_table.h", |
| "lib/file_fd_impl.cc", |
| "lib/file_fd_impl.h", |
| "lib/mojio_fcntl.cc", |
| "lib/mojio_sys_stat.cc", |
| "lib/mojio_unistd.cc", |
| "lib/real_errno_impl.cc", |
| "lib/real_errno_impl.h", |
| "lib/singletons.cc", |
| "lib/singletons.h", |
| "lib/template_util.h", |
| "lib/util.cc", |
| "lib/util.h", |
| "mojio_config.h", |
| "mojio_fcntl.h", |
| "mojio_stdio.h", |
| "mojio_sys_stat.h", |
| "mojio_sys_types.h", |
| "mojio_time.h", |
| "mojio_unistd.h", |
| ] |
| |
| deps = [ |
| "../interfaces", |
| ] |
| |
| mojo_sdk_deps = [ |
| "mojo/public/cpp/bindings", |
| "mojo/public/cpp/environment", |
| "mojo/public/cpp/system", |
| ] |
| } |
| |
| # NOTE(vtl): Some of the tests actually depend on a reasonable implementation of |
| # the files service (e.g., //services/files). |
| mojo_native_application("apptests") { |
| output_name = "mojio_apptests" |
| |
| testonly = true |
| |
| sources = [ |
| "tests/directory_wrapper_unittest.cc", |
| "tests/errno_impl_unittest.cc", |
| "tests/fd_table_unittest.cc", |
| "tests/file_fd_impl_unittest.cc", |
| "tests/mock_errno_impl.cc", |
| "tests/mock_errno_impl.h", |
| "tests/mojio_impl_test_base.cc", |
| "tests/mojio_impl_test_base.h", |
| "tests/mojio_sys_stat_unittest.cc", |
| "tests/mojio_test_base.cc", |
| "tests/mojio_test_base.h", |
| "tests/mojio_unistd_unittest.cc", |
| "tests/real_errno_impl_unittest.cc", |
| "tests/test_utils.cc", |
| "tests/test_utils.h", |
| "tests/test_utils_unittest.cc", |
| "tests/util_unittest.cc", |
| ] |
| |
| deps = [ |
| ":mojio", |
| "../interfaces", |
| "$mojo_sdk_root/mojo/public/cpp/application:standalone", |
| "$mojo_sdk_root/mojo/public/cpp/application:test_support_standalone", |
| "$mojo_sdk_root/mojo/public/cpp/bindings", |
| "$mojo_sdk_root/mojo/public/cpp/environment", |
| "$mojo_sdk_root/mojo/public/cpp/system", |
| "//testing/gtest", |
| ] |
| } |