Fix 'chrome' build when use_ozone is true

As is, the 'chrome' target depends on libsecret, which
explicitly depends on glib.
In case of use_ozone=true builds, though, use_glib is
set to false.

CL fixes it by not building libsecret dependant files
when use_ozone is true.

Review-Url: https://codereview.chromium.org/2341773004
Cr-Commit-Position: refs/heads/master@{#418663}
diff --git a/chrome/browser/BUILD.gn b/chrome/browser/BUILD.gn
index 84342d1..6fee225 100644
--- a/chrome/browser/BUILD.gn
+++ b/chrome/browser/BUILD.gn
@@ -3432,7 +3432,7 @@
   }
 
   if (is_desktop_linux) {
-    # Desktop linux, doesn"t count ChromeOS.
+    # Desktop linux, doesn't count ChromeOS.
     sources += [
       "first_run/upgrade_util.cc",
       "first_run/upgrade_util_linux.cc",
@@ -3442,8 +3442,6 @@
       "media/webrtc/window_icon_util_x11.cc",
       "password_manager/native_backend_kwallet_x.cc",
       "password_manager/native_backend_kwallet_x.h",
-      "password_manager/native_backend_libsecret.cc",
-      "password_manager/native_backend_libsecret.h",
       "platform_util_linux.cc",
       "shell_integration_linux.cc",
       "shell_integration_linux.h",
@@ -3452,8 +3450,14 @@
       "themes/theme_service_aurax11.h",
       "web_applications/web_app_linux.cc",
     ]
-    defines += [ "USE_LIBSECRET" ]
-    deps += [ "//third_party/libsecret" ]
+    if (!use_ozone) {
+      sources += [
+        "password_manager/native_backend_libsecret.cc",
+        "password_manager/native_backend_libsecret.h",
+      ]
+      defines += [ "USE_LIBSECRET" ]
+      deps += [ "//third_party/libsecret" ]
+    }
   }
 
   if (enable_plugin_installation) {