Browse Source

build: [gn] move crashpad to mac-only

Jeremy Apthorp 6 years ago
parent
commit
62f62264da
1 changed files with 8 additions and 11 deletions
  1. 8 11
      BUILD.gn

+ 8 - 11
BUILD.gn

@@ -223,7 +223,6 @@ static_library("electron_lib") {
     "//skia",
     "//third_party/WebKit/public:blink",
     "//third_party/boringssl",
-    "//third_party/crashpad/crashpad/client",
     "//third_party/leveldatabase",
     "//third_party/libyuv",
     "//ui/events:dom_keycode_converter",
@@ -244,6 +243,13 @@ static_library("electron_lib") {
   if (is_mac) {
     deps += [
       "//ui/accelerated_widget_mac",
+      "//third_party/crashpad/crashpad/client",
+    ]
+    include_dirs += [
+      # NOTE(nornagon): other chromium files use the full path to include
+      # crashpad; this is just here for compatibility between GN and GYP, so that
+      # the #includes can be agnostic about where crashpad is vendored.
+      "//third_party/crashpad",
     ]
   }
   if (is_linux) {
@@ -251,7 +257,6 @@ static_library("electron_lib") {
       "//build/config/linux/gtk3",
       "//chrome/browser/ui/libgtkui",
       "//device/bluetooth",
-      "//third_party/breakpad:client",
       "//ui/events/devices/x11",
       "//ui/events/platform/x11",
       "//ui/native_theme",
@@ -260,11 +265,6 @@ static_library("electron_lib") {
     ]
     configs += [ ":gio_unix" ]
   }
-  if (is_win) {
-    deps += [
-      "//third_party/breakpad:client",
-    ]
-  }
   defines = [
     # Disable warnings for g_settings_list_schemas.
     "GLIB_DISABLE_DEPRECATION_WARNINGS",
@@ -281,12 +281,9 @@ static_library("electron_lib") {
     # TODO(nornagon): replace usage of SchemeRegistry by an actually exported
     # API of blink, then delete this include dir.
     "//third_party/WebKit/Source",
-    # NOTE(nornagon): other chromium files use the full path to include
-    # crashpad; this is just here for compatibility between GN and GYP, so that
-    # the #includes can be agnostic about where crashpad is vendored.
-    "//third_party/crashpad",
   ]
   if (is_linux || is_win) {
+    deps += [ "//third_party/breakpad:client" ]
     include_dirs += [
       "//third_party/breakpad",
     ]