mirror of
https://github.com/dart-lang/sdk
synced 2024-10-14 11:42:11 +00:00
(Strip out platform dill files and the kernel service dill file from a product build) After fixing the issue of using 'is_product' which is not present in the flutter build environment. Change-Id: I49dd68e63b1f6d7ac0981b28bf2b08618551ae2e Reviewed-on: https://dart-review.googlesource.com/44024 Reviewed-by: Siva Annamalai <asiva@google.com> Commit-Queue: Siva Annamalai <asiva@google.com>
This commit is contained in:
parent
b766ec170c
commit
1aaebedd70
|
@ -752,23 +752,30 @@ source_set("dart_snapshot_cc") {
|
|||
deps = [
|
||||
":isolate_snapshot_data_assembly",
|
||||
":isolate_snapshot_instructions_assembly",
|
||||
":kernel_service_dill_cc",
|
||||
":platform_dill_cc",
|
||||
":platform_strong_dill_cc",
|
||||
":vm_snapshot_data_assembly",
|
||||
":vm_snapshot_instructions_assembly",
|
||||
]
|
||||
sources = [
|
||||
"$root_gen_dir/kernel_service.dill.cc",
|
||||
"$target_gen_dir/isolate_snapshot_data.S",
|
||||
"$target_gen_dir/isolate_snapshot_instructions.S",
|
||||
"$target_gen_dir/vm_platform.dill.cc",
|
||||
"$target_gen_dir/vm_platform_strong.dill.cc",
|
||||
"$target_gen_dir/vm_snapshot_data.S",
|
||||
"$target_gen_dir/vm_snapshot_instructions.S",
|
||||
]
|
||||
}
|
||||
|
||||
source_set("dart_kernel_platform_cc") {
|
||||
deps = [
|
||||
":kernel_service_dill_cc",
|
||||
":platform_dill_cc",
|
||||
":platform_strong_dill_cc",
|
||||
]
|
||||
sources = [
|
||||
"$root_gen_dir/kernel_service.dill.cc",
|
||||
"$target_gen_dir/vm_platform.dill.cc",
|
||||
"$target_gen_dir/vm_platform_strong.dill.cc",
|
||||
]
|
||||
}
|
||||
|
||||
template("dart_executable") {
|
||||
extra_configs = []
|
||||
if (defined(invoker.extra_configs)) {
|
||||
|
@ -873,6 +880,9 @@ dart_executable("dart") {
|
|||
if (dart_runtime_mode != "release") {
|
||||
extra_deps += [ "../observatory:standalone_observatory_archive" ]
|
||||
}
|
||||
if (dart_runtime_mode != "release") {
|
||||
extra_deps += [ ":dart_kernel_platform_cc" ]
|
||||
}
|
||||
extra_sources = [
|
||||
"builtin_nolib.cc",
|
||||
"dfe.cc",
|
||||
|
@ -932,6 +942,9 @@ dart_executable("dart_bootstrap") {
|
|||
":generate_web_sql_cc_file",
|
||||
"..:libdart_nosnapshot_with_precompiler",
|
||||
]
|
||||
if (dart_runtime_mode != "release") {
|
||||
extra_deps += [ ":dart_kernel_platform_cc" ]
|
||||
}
|
||||
extra_defines = [ "NO_OBSERVATORY" ]
|
||||
extra_sources = [
|
||||
"builtin.cc",
|
||||
|
@ -1109,6 +1122,7 @@ executable("run_vm_tests") {
|
|||
}
|
||||
|
||||
deps = [
|
||||
":dart_kernel_platform_cc",
|
||||
":dart_snapshot_cc",
|
||||
":generate_snapshot_test_dat_file",
|
||||
":libdart_builtin",
|
||||
|
|
|
@ -13,12 +13,21 @@
|
|||
#include "vm/kernel.h"
|
||||
|
||||
extern "C" {
|
||||
#if !defined(EXCLUDE_CFE_AND_KERNEL_PLATFORM)
|
||||
extern const uint8_t kKernelServiceDill[];
|
||||
extern intptr_t kKernelServiceDillSize;
|
||||
extern const uint8_t kPlatformDill[];
|
||||
extern intptr_t kPlatformDillSize;
|
||||
extern const uint8_t kPlatformStrongDill[];
|
||||
extern intptr_t kPlatformStrongDillSize;
|
||||
#else
|
||||
const uint8_t* kKernelServiceDill = NULL;
|
||||
intptr_t kKernelServiceDillSize = 0;
|
||||
const uint8_t* kPlatformDill = NULL;
|
||||
intptr_t kPlatformDillSize = 0;
|
||||
const uint8_t* kPlatformStrongDill = NULL;
|
||||
intptr_t kPlatformStrongDillSize = 0;
|
||||
#endif // !defined(EXCLUDE_CFE_AND_KERNEL_PLATFORM)
|
||||
}
|
||||
|
||||
namespace dart {
|
||||
|
|
|
@ -323,7 +323,7 @@ static Dart_Isolate IsolateSetupHelper(Dart_Isolate isolate,
|
|||
return isolate;
|
||||
}
|
||||
|
||||
#if !defined(DART_PRECOMPILED_RUNTIME)
|
||||
#if !defined(EXCLUDE_CFE_AND_KERNEL_PLATFORM)
|
||||
// Returns newly created Kernel Isolate on success, NULL on failure.
|
||||
// For now we only support the kernel isolate coming up from an
|
||||
// application snapshot or from a .dill file.
|
||||
|
@ -382,7 +382,7 @@ static Dart_Isolate CreateAndSetupKernelIsolate(const char* script_uri,
|
|||
return IsolateSetupHelper(isolate, false, uri, package_root, packages_config,
|
||||
true, isolate_run_app_snapshot, error, exit_code);
|
||||
}
|
||||
#endif // !defined(DART_PRECOMPILED_RUNTIME)
|
||||
#endif // !defined(EXCLUDE_CFE_AND_KERNEL_PLATFORM)
|
||||
|
||||
// Returns newly created Service Isolate on success, NULL on failure.
|
||||
// For now we only support the service isolate coming up from sources
|
||||
|
@ -609,13 +609,13 @@ static Dart_Isolate CreateIsolateAndSetup(const char* script_uri,
|
|||
}
|
||||
|
||||
int exit_code = 0;
|
||||
#if !defined(DART_PRECOMPILED_RUNTIME)
|
||||
#if !defined(EXCLUDE_CFE_AND_KERNEL_PLATFORM)
|
||||
if (strcmp(script_uri, DART_KERNEL_ISOLATE_NAME) == 0) {
|
||||
return CreateAndSetupKernelIsolate(script_uri, main, package_root,
|
||||
package_config, flags, error,
|
||||
&exit_code);
|
||||
}
|
||||
#endif // !defined(DART_PRECOMPILED_RUNTIME)
|
||||
#endif // !defined(EXCLUDE_CFE_AND_KERNEL_PLATFORM)
|
||||
if (strcmp(script_uri, DART_VM_SERVICE_ISOLATE_NAME) == 0) {
|
||||
return CreateAndSetupServiceIsolate(script_uri, main, package_root,
|
||||
package_config, flags, error,
|
||||
|
|
|
@ -146,6 +146,10 @@
|
|||
#define NOT_IN_PRECOMPILED(code) code
|
||||
#endif // defined(DART_PRECOMPILED_RUNTIME)
|
||||
|
||||
#if defined(DART_PRECOMPILED_RUNTIME) || defined(PRODUCT)
|
||||
#define EXCLUDE_CFE_AND_KERNEL_PLATFORM 1
|
||||
#endif // defined(DART_PRECOMPILED_RUNTIME)
|
||||
|
||||
namespace dart {
|
||||
|
||||
struct simd128_value_t {
|
||||
|
|
Loading…
Reference in a new issue