Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix some missing dep issues with brave/extensions/api target that has… #25684

Merged
merged 2 commits into from
Sep 22, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
37 changes: 35 additions & 2 deletions browser/extensions/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
# You can obtain one at https://mozilla.org/MPL/2.0/.

import("//brave/browser/ethereum_remote_client/buildflags/buildflags.gni")
import("//brave/components/brave_vpn/common/buildflags/buildflags.gni")
import("//brave/components/brave_wayback_machine/buildflags/buildflags.gni")
import("//brave/components/brave_webtorrent/browser/buildflags/buildflags.gni")
import("//brave/components/speedreader/common/buildflags/buildflags.gni")
Expand Down Expand Up @@ -57,37 +58,58 @@ source_set("extensions") {
"//base",
"//brave/app:brave_generated_resources_grit",
"//brave/browser/brave_rewards:util",
"//brave/browser:browser_process",
"//brave/browser/component_updater",
"//brave/browser/extensions/api:generated_api_registration",
"//brave/browser/themes",
"//brave/browser/ui:brave_tab_prefs",
"//brave/common",
"//brave/common/extensions/api",
"//brave/components/ai_chat/core/browser",
"//brave/components/ai_chat/core/common",
"//brave/components/brave_adaptive_captcha",
"//brave/components/brave_ads/browser",
"//brave/components/brave_ads/core",
"//brave/components/brave_ads/core/public:headers",
"//brave/components/brave_component_updater/browser",
"//brave/components/brave_extension:static_resources",
"//brave/components/brave_news/common",
"//brave/components/brave_rewards/browser",
"//brave/components/brave_rewards/common",
"//brave/components/brave_rewards/core:headers",
"//brave/components/brave_shields/content/browser",
"//brave/components/brave_shields/core/common",
"//brave/components/brave_vpn/common/buildflags",
"//brave/components/brave_wallet/browser:pref_names",
"//brave/components/brave_wallet/browser:utils",
"//brave/components/brave_wallet/common",
"//brave/components/brave_wayback_machine/buildflags",
"//brave/components/brave_webtorrent:static_resources",
"//brave/components/ai_chat/core/common/buildflags",
"//brave/components/constants",
"//brave/components/de_amp/common",
"//brave/components/debounce/core/common",
"//brave/components/decentralized_dns/content",
"//brave/components/decentralized_dns/core",
"//brave/components/de_amp/common",
"//brave/components/greaselion/browser",
"//brave/components/l10n/common",
"//brave/components/ntp_background_images/common",
"//brave/components/ntp_widget_utils/browser",
"//brave/components/playlist/browser",
"//brave/components/playlist/common/buildflags",
"//brave/components/request_otr/common",
"//brave/components/sidebar/browser",
"//brave/components/tor/buildflags",
"//chrome/browser:browser_process",
"//chrome/browser/extensions",
"//chrome/common",
"//components/browsing_data/core",
"//components/gcm_driver:gcm_buildflags",
"//components/gcm_driver:gcm_driver",
"//components/omnibox/browser:browser",
"//components/prefs",
"//components/services/patch/content",
"//components/services/unzip/content",
"//components/update_client:network_impl",
"//components/update_client:patch_impl",
"//components/update_client:unzip_impl",
"//content/public/browser",
Expand All @@ -100,6 +122,17 @@ source_set("extensions") {

public_deps = [ "//brave/browser/ethereum_remote_client/buildflags" ]

if (enable_brave_vpn) {
deps += [ "//brave/components/brave_vpn/common" ]
}

if (enable_tor) {
deps += [
"//brave/components/tor",
"//brave/components/tor:pref_names"
]
}

if (enable_speedreader) {
deps += [ "//brave/components/speedreader" ]
}
Expand Down
3 changes: 0 additions & 3 deletions browser/extensions/api/brave_wallet_api.cc
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@

#include "brave/browser/extensions/api/brave_wallet_api.h"

#include <memory>
#include <optional>
#include <string>

Expand All @@ -25,14 +24,12 @@
#include "brave/components/l10n/common/localization_util.h"
#include "brave/grit/brave_generated_resources.h"
#include "chrome/browser/browser_process.h"
#include "chrome/browser/extensions/api/tabs/tabs_constants.h"
#include "chrome/browser/extensions/extension_tab_util.h"
#include "chrome/browser/profiles/profile.h"
#include "components/prefs/pref_service.h"
#include "content/public/browser/web_contents.h"
#include "extensions/browser/extension_prefs.h"
#include "extensions/browser/extension_util.h"
#include "extensions/common/constants.h"

namespace {

Expand Down
8 changes: 0 additions & 8 deletions browser/extensions/api/settings_private/brave_prefs_util.cc
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,8 @@

#include "brave/browser/extensions/api/settings_private/brave_prefs_util.h"

#include "base/feature_list.h"
#include "brave/browser/ethereum_remote_client/buildflags/buildflags.h"
#include "brave/browser/ui/tabs/brave_tab_prefs.h"
#include "brave/components/ai_chat/core/common/buildflags/buildflags.h"
#include "brave/components/brave_ads/core/public/prefs/pref_names.h"
#include "brave/components/brave_news/common/pref_names.h"
#include "brave/components/brave_rewards/common/pref_names.h"
#include "brave/components/brave_shields/content/browser/brave_shields_util.h"
Expand Down Expand Up @@ -46,12 +43,7 @@
#include "brave/components/brave_wayback_machine/pref_names.h"
#endif

#if BUILDFLAG(ETHEREUM_REMOTE_CLIENT_ENABLED)
#include "brave/browser/ethereum_remote_client/pref_names.h"
#endif

#if BUILDFLAG(ENABLE_AI_CHAT)
#include "brave/components/ai_chat/core/browser/model_service.h"
#include "brave/components/ai_chat/core/common/pref_names.h"
#endif

Expand Down
30 changes: 25 additions & 5 deletions browser/ui/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,10 @@ source_set("ui") {
"//brave/components/webcompat/core/common",
]

public_deps = []
public_deps = [
":brave_tab_prefs",
":brave_tab_features",
]
sources = [
"brave_ui_features.cc",
"brave_ui_features.h",
Expand Down Expand Up @@ -201,13 +204,9 @@ source_set("ui") {
"tabs/brave_tab_layout_constants.h",
"tabs/brave_tab_menu_model.cc",
"tabs/brave_tab_menu_model.h",
"tabs/brave_tab_prefs.cc",
"tabs/brave_tab_prefs.h",
"tabs/brave_tab_strip_model.cc",
"tabs/brave_tab_strip_model.h",
"tabs/brave_tab_style.h",
"tabs/features.cc",
"tabs/features.h",
"tabs/shared_pinned_tab_dummy_view.h",
"tabs/shared_pinned_tab_service.cc",
"tabs/shared_pinned_tab_service.h",
Expand Down Expand Up @@ -1352,6 +1351,27 @@ source_set("ui") {
}
}

source_set("brave_tab_prefs") {
sources = [
"tabs/brave_tab_prefs.cc",
"tabs/brave_tab_prefs.h",
]
deps =[
":brave_tab_features",
"//components/prefs",
]
}

source_set("brave_tab_features") {
sources = [
"tabs/features.cc",
"tabs/features.h",
]
deps =[
"//base",
]
}

source_set("unit_tests") {
if (!is_android) {
testonly = true
Expand Down
7 changes: 4 additions & 3 deletions components/brave_wallet/common/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,6 @@ static_library("common") {
":common_constants",
":generated_eth_requests",
":generated_json_rpc_requests",
":mojom",
":mojom__generator",
":pref_names",
"//brave/components/brave_wallet/rust:rust_lib",
"//brave/net/base:utils",
Expand All @@ -90,7 +88,10 @@ static_library("common") {
"//url",
]

public_deps = [ "//base" ]
public_deps = [
"//base",
":mojom",
]
}

source_set("common_constants") {
Expand Down
Loading