dart-sdk/runtime/platform/BUILD.gn
Filip Filmar 595cd384d3 Add dart::ComponentContext() for Fuchsia
This allows the program to get at the singleton component context
for the currently running component.  The component context can
be meaningfully instantiated only once; and since dart doesn't
have a predefined way to wire platform-specific values into
platform-specific code, we instantiate a singleton here, so all
code that is interested can use it.

The users of this functionality will be the dart and flutter
fuchsia runners.  See issue
https://github.com/dart-lang/sdk/issues/41523 for details.

Tested:
  manual compile for fuchsia, check behavior.

Change-Id: Ib4e15af376ecb932c2d2b28d6f099383d53ccc84
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/136524
Commit-Queue: Filip Filmar <fmil@google.com>
Reviewed-by: Martin Kustermann <kustermann@google.com>
2020-04-21 19:09:25 +00:00

27 lines
700 B
Plaintext

# Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file
# for details. All rights reserved. Use of this source code is governed by a
# BSD-style license that can be found in the LICENSE file.
import("../configs.gni")
import("platform_sources.gni")
if (is_fuchsia) {
import("//build/fuchsia/sdk.gni")
}
library_for_all_configs("libdart_platform") {
target_type = "source_set"
public_configs = [ "../vm:libdart_vm_config" ]
sources = platform_sources
include_dirs = [ ".." ]
extra_deps = []
if (is_fuchsia) {
if (using_fuchsia_sdk) {
extra_deps += [ "$fuchsia_sdk_root/pkg:sys_cpp" ]
} else {
extra_deps += [ "//sdk/lib/sys/cpp" ]
}
}
}