summaryrefslogtreecommitdiffstats
path: root/components
diff options
context:
space:
mode:
authorcjhopman <cjhopman@chromium.org>2014-10-27 10:11:18 -0700
committerCommit bot <commit-bot@chromium.org>2014-10-27 17:11:34 +0000
commit09981a9eb8bff00e2644f3174e5651b5734eed9a (patch)
tree95f1e38463a94a67b65cb937e64add40bda228b2 /components
parent68c65a48b958c1a5e029cece19ef5eb01ab99fff (diff)
downloadchromium_src-09981a9eb8bff00e2644f3174e5651b5734eed9a.zip
chromium_src-09981a9eb8bff00e2644f3174e5651b5734eed9a.tar.gz
chromium_src-09981a9eb8bff00e2644f3174e5651b5734eed9a.tar.bz2
GN: Fix Android component build
This change makes all libraries in the Android component build link successfully (including fixing and enabling libchrome_shell). This also makes all the libraries link in a component build for Linux, but without bot coverage for that platform it'll surely regress. This is almost entirely just fixing some missing/incorrect dependencies and adding missing source files for Android. Some targets were depending on an internal source_set/static_library when they should have been (or already were) depending on the corresponding component. In these cases, I added some visibility restrictions to those internal targets to try to prevent those types of dependencies from coming back. BUG=359249 Review URL: https://codereview.chromium.org/666813002 Cr-Commit-Position: refs/heads/master@{#301386}
Diffstat (limited to 'components')
-rw-r--r--components/bookmarks.gypi3
-rw-r--r--components/bookmarks/common/BUILD.gn5
-rw-r--r--components/bookmarks/common/android/BUILD.gn12
-rw-r--r--components/cdm/renderer/BUILD.gn2
-rw-r--r--components/dom_distiller/core/BUILD.gn6
-rw-r--r--components/keyed_service/content/BUILD.gn1
-rw-r--r--components/sessions/BUILD.gn1
7 files changed, 28 insertions, 2 deletions
diff --git a/components/bookmarks.gypi b/components/bookmarks.gypi
index b9a7268..fdf382d 100644
--- a/components/bookmarks.gypi
+++ b/components/bookmarks.gypi
@@ -60,6 +60,9 @@
],
'conditions': [
['OS == "android"', {
+ # In GN, this android-specific stuff is its own target at
+ # //components/bookmarks/common/android
+ # TODO(cjhopman): This should be its own target in Gyp, too.
'dependencies': [
'bookmarks_jni_headers',
],
diff --git a/components/bookmarks/common/BUILD.gn b/components/bookmarks/common/BUILD.gn
index 283b85be..320d463 100644
--- a/components/bookmarks/common/BUILD.gn
+++ b/components/bookmarks/common/BUILD.gn
@@ -13,4 +13,9 @@ source_set("common") {
deps = [
"//base",
]
+ if (is_android) {
+ deps += [
+ "//components/bookmarks/common/android",
+ ]
+ }
}
diff --git a/components/bookmarks/common/android/BUILD.gn b/components/bookmarks/common/android/BUILD.gn
index bd8fee368..ffe2566 100644
--- a/components/bookmarks/common/android/BUILD.gn
+++ b/components/bookmarks/common/android/BUILD.gn
@@ -4,6 +4,18 @@
import("//build/config/android/rules.gni")
+# GYP: //components/bookmarks.gyp:bookmarks_browser (android part)
+source_set("android") {
+ sources = [
+ "bookmark_id.cc",
+ "bookmark_id.h",
+ "bookmark_type_list.h",
+ "component_jni_registrar.cc",
+ "component_jni_registrar.h",
+ ]
+ deps = [ ":bookmarks_jni_headers" ]
+}
+
# GYP: //components/bookmarks.gyp:bookmarks_java
android_library("bookmarks_java") {
deps = [
diff --git a/components/cdm/renderer/BUILD.gn b/components/cdm/renderer/BUILD.gn
index 9652a6c..ef4d03d 100644
--- a/components/cdm/renderer/BUILD.gn
+++ b/components/cdm/renderer/BUILD.gn
@@ -19,7 +19,7 @@ static_library("renderer") {
"//base",
"//components/cdm/common",
"//content/public/renderer",
- "//media/base",
+ "//media",
"//third_party/widevine/cdm:version_h",
]
}
diff --git a/components/dom_distiller/core/BUILD.gn b/components/dom_distiller/core/BUILD.gn
index e20a4ad..be5816e 100644
--- a/components/dom_distiller/core/BUILD.gn
+++ b/components/dom_distiller/core/BUILD.gn
@@ -3,7 +3,7 @@
# found in the LICENSE file.
# GYP version: components/dom_distiller.gypi:dom_distiller_core
-static_library("core") {
+source_set("core") {
sources = [
"../android/component_jni_registrar.cc",
"../android/component_jni_registrar.h",
@@ -63,6 +63,10 @@ static_library("core") {
]
if (is_android) {
+ sources += [
+ "dom_distiller_service_android.cc",
+ "dom_distiller_service_android.h",
+ ]
deps += [ ":jni_headers" ]
}
}
diff --git a/components/keyed_service/content/BUILD.gn b/components/keyed_service/content/BUILD.gn
index a445307..80f204e 100644
--- a/components/keyed_service/content/BUILD.gn
+++ b/components/keyed_service/content/BUILD.gn
@@ -28,6 +28,7 @@ component("content") {
"//base:prefs",
"//base/third_party/dynamic_annotations",
"//content/public/common",
+ "//components/keyed_service/core",
"//components/user_prefs",
]
}
diff --git a/components/sessions/BUILD.gn b/components/sessions/BUILD.gn
index 68b84d2..bf9182f 100644
--- a/components/sessions/BUILD.gn
+++ b/components/sessions/BUILD.gn
@@ -24,6 +24,7 @@ source_set("sessions_core") {
deps = [
"//base",
"//skia",
+ "//third_party/protobuf:protobuf_lite",
"//ui/base",
"//url",
]