build: remove dead symlink from MAS build (#24158)

* build: remove dead symlink from MAS build

* chore: new out cache

* build: fixup gn check

* Update node_main.cc

* chore: fix lint
This commit is contained in:
Samuel Attard 2020-06-16 14:19:57 -07:00 committed by GitHub
parent cf284991d8
commit 09c0ee8f87
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
9 changed files with 121 additions and 28 deletions

View file

@ -18,19 +18,15 @@
#include "base/strings/utf_string_conversions.h"
#include "base/task/thread_pool/thread_pool_instance.h"
#include "base/threading/thread_task_runner_handle.h"
#include "components/crash/core/app/crashpad.h"
#include "content/public/common/content_switches.h"
#include "electron/electron_version.h"
#include "gin/array_buffer.h"
#include "gin/public/isolate_holder.h"
#include "gin/v8_initializer.h"
#include "shell/app/electron_crash_reporter_client.h"
#include "shell/app/uv_task_runner.h"
#include "shell/browser/api/electron_api_crash_reporter.h"
#include "shell/browser/javascript_environment.h"
#include "shell/browser/node_debugger.h"
#include "shell/common/api/electron_bindings.h"
#include "shell/common/crash_keys.h"
#include "shell/common/gin_helper/dictionary.h"
#include "shell/common/node_bindings.h"
#include "shell/common/node_includes.h"
@ -43,6 +39,13 @@
#include "chrome/child/v8_crashpad_support_win.h"
#endif
#if !defined(MAS_BUILD)
#include "components/crash/core/app/crashpad.h" // nogncheck
#include "shell/app/electron_crash_reporter_client.h"
#include "shell/browser/api/electron_api_crash_reporter.h"
#include "shell/common/crash_keys.h"
#endif
namespace {
// Initialize Node.js cli options to pass to Node.js
@ -84,6 +87,11 @@ void SetNodeCliFlags() {
ProcessGlobalArgs(&args, nullptr, &errors, node::kDisallowedInEnvironment);
}
#if defined(MAS_BUILD)
void SetCrashKeyStub(const std::string& key, const std::string& value) {}
void ClearCrashKeyStub(const std::string& key) {}
#endif
} // namespace
namespace electron {
@ -217,10 +225,15 @@ int NodeMain(int argc, char* argv[]) {
#endif
reporter.SetMethod("getParameters", &GetParameters);
#if defined(MAS_BUILD)
reporter.SetMethod("addExtraParameter", &SetCrashKeyStub);
reporter.SetMethod("removeExtraParameter", &ClearCrashKeyStub);
#else
reporter.SetMethod("addExtraParameter",
&electron::crash_keys::SetCrashKey);
reporter.SetMethod("removeExtraParameter",
&electron::crash_keys::ClearCrashKey);
#endif
process.Set("crashReporter", reporter);