summaryrefslogtreecommitdiffstats
path: root/components
diff options
context:
space:
mode:
authorblundell@chromium.org <blundell@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-05-06 14:34:55 +0000
committerblundell@chromium.org <blundell@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-05-06 14:34:55 +0000
commitfe003516294c35856c67cb5cb741e214baf1af9c (patch)
tree1748144484d27d893414c6439817d279ca83b750 /components
parent7126b6b9ca31d5bd81769dd11aef5640b268fb3b (diff)
downloadchromium_src-fe003516294c35856c67cb5cb741e214baf1af9c.zip
chromium_src-fe003516294c35856c67cb5cb741e214baf1af9c.tar.gz
chromium_src-fe003516294c35856c67cb5cb741e214baf1af9c.tar.bz2
Adjust the structure of DEPS within //components.
As the majority of components are now shared by iOS, it no longer makes sense to have a blanket allowance of IPC and //content/public/common in //components. Instead, individual components should have to add these dependencies explicitly, lessening the chance that bad dependencies creep in (e.g., a //content/public/common dependency in code that iOS shares). TBR=darin Review URL: https://codereview.chromium.org/266923008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268513 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'components')
-rw-r--r--components/DEPS15
-rw-r--r--components/README18
-rw-r--r--components/autofill/DEPS2
-rw-r--r--components/bookmarks/DEPS3
-rw-r--r--components/breakpad/app/DEPS1
-rw-r--r--components/data_reduction_proxy/DEPS2
-rw-r--r--components/dom_distiller/DEPS1
-rw-r--r--components/infobars/DEPS3
-rw-r--r--components/keyed_service/DEPS1
-rw-r--r--components/metrics/DEPS1
-rw-r--r--components/nacl/DEPS4
-rw-r--r--components/os_crypt/DEPS1
-rw-r--r--components/password_manager/DEPS3
-rw-r--r--components/precache/DEPS1
-rw-r--r--components/query_parser/DEPS5
-rw-r--r--components/search_provider_logos/DEPS5
-rw-r--r--components/signin/DEPS5
-rw-r--r--components/sync_driver/DEPS2
-rw-r--r--components/tracing/DEPS4
-rw-r--r--components/translate/DEPS1
-rw-r--r--components/translate/content/DEPS1
-rw-r--r--components/usb_service/DEPS1
-rw-r--r--components/variations/DEPS3
-rw-r--r--components/visitedlink/DEPS3
-rw-r--r--components/web_contents_delegate_android/DEPS1
-rw-r--r--components/webdata/DEPS2
26 files changed, 25 insertions, 64 deletions
diff --git a/components/DEPS b/components/DEPS
index 9a3d245..0505b37 100644
--- a/components/DEPS
+++ b/components/DEPS
@@ -6,16 +6,7 @@ include_rules = [
# components/ are not allowed.
"-components",
- # Components should only depend on the public Content API, and on
- # layers below the Content Module. They must not depend on the
- # implementation of the Content Module.
- #
- # Subdirectories of e.g. src/components/component_name should add
- # the additional parts of the Content API that they need,
- # e.g. components/component_name/browser/DEPS would add a
- # "+content/public/browser" rule.
- "+content/public/common",
-
- # Dependencies of variations component.
- "+third_party/mt19937ar",
+ # Components that wish to use the content API or IPC must explicitly declare
+ # these dependencies; see ./README.
+ "-ipc",
]
diff --git a/components/README b/components/README
index 7201320..8112f6e 100644
--- a/components/README
+++ b/components/README
@@ -1,19 +1,19 @@
This directory is for features that are intended for reuse across multiple
embedders (e.g., Android WebView and Chrome).
-By default, subdirectories have the Content Module as the uppermost layer they
-depend on, i.e., they may depend only on the Content API (content/public) and
-on lower layers (e.g. base/, net/, ipc/ etc.). Individual subdirectories may
-further restrict their dependencies, e.g., a component that is used by Chrome
-for iOS (which does not use the content API) will either disallow usage of
-content/public or be in the form of a layered component
+By default, components can depend only on the lower layers of the Chromium
+codebase(e.g. base/, net/, etc.). Individual components may additionally allow
+dependencies on the content API and IPC; however, if such a component is used
+by Chrome for iOS (which does not use the content API or IPC), the component
+will have to be in the form of a layered component
(http://www.chromium.org/developers/design-documents/layered-components-design).
Components that have bits of code that need to live in different
processes (e.g. some code in the browser process, some in the renderer
process, etc.) should separate the code into different subdirectories.
Hence for a component named 'foo' you might end up with a structure
-like the following:
+like the following (assuming that foo is not used by iOS and thus does not
+need to be a layered component):
components/foo - DEPS, OWNERS, foo.gypi
components/foo/browser - code that needs the browser process
@@ -36,6 +36,4 @@ components/foo/android/javatests/src/org/chromium/components/foo/browser/
Code in a component should be placed in a namespace corresponding to
the name of the component; e.g. for a component living in
//components/foo, code in that component should be in the foo::
-namespace. Note that it used to be the rule that all code under
-//components should be in the components:: namespace; this is being
-phased out.
+namespace.
diff --git a/components/autofill/DEPS b/components/autofill/DEPS
index 9c56889..3f87406 100644
--- a/components/autofill/DEPS
+++ b/components/autofill/DEPS
@@ -7,6 +7,4 @@ include_rules = [
# Autofill is a layered component; subdirectories must explicitly introduce
# the ability to use the content layer as appropriate.
"-components/autofill/content",
- "-content/public/common",
- "-ipc",
]
diff --git a/components/bookmarks/DEPS b/components/bookmarks/DEPS
index 7b35635..3dcea05 100644
--- a/components/bookmarks/DEPS
+++ b/components/bookmarks/DEPS
@@ -1,7 +1,4 @@
include_rules = [
- # Bookmarks is a component that is not allowed to uses content/ so that it
- # can be shared on iOS.
- "-content",
"+components/favicon_base",
"+components/query_parser",
"+components/startup_metric_utils",
diff --git a/components/breakpad/app/DEPS b/components/breakpad/app/DEPS
index 1a1417f..4080651 100644
--- a/components/breakpad/app/DEPS
+++ b/components/breakpad/app/DEPS
@@ -1,7 +1,6 @@
include_rules = [
"+sandbox",
- "-content/public/common",
"+content/public/common/content_descriptors.h",
"+content/public/common/result_codes.h",
"+third_party/lss/linux_syscall_support.h",
diff --git a/components/data_reduction_proxy/DEPS b/components/data_reduction_proxy/DEPS
index 400ee0c..bfc9d61 100644
--- a/components/data_reduction_proxy/DEPS
+++ b/components/data_reduction_proxy/DEPS
@@ -2,6 +2,4 @@ include_rules = [
"+components/user_prefs",
"+crypto",
"+net",
- # Data reduction proxy is used by iOS, which does not use content.
- "-content",
]
diff --git a/components/dom_distiller/DEPS b/components/dom_distiller/DEPS
index a69831c..a82b8ad 100644
--- a/components/dom_distiller/DEPS
+++ b/components/dom_distiller/DEPS
@@ -15,5 +15,4 @@ include_rules = [
# http://www.chromium.org/developers/design-documents/layered-components-design
"-components/dom_distiller",
"+components/dom_distiller/core",
- "-content/public",
]
diff --git a/components/infobars/DEPS b/components/infobars/DEPS
index 4f66f6c..b1b7165 100644
--- a/components/infobars/DEPS
+++ b/components/infobars/DEPS
@@ -1,8 +1,7 @@
include_rules = [
# Infobars is a layered component; subdirectories must explicitly introduce
# the ability to use the content layer as appropriate.
- "-content",
-
+
"+ui",
"+third_party/skia"
]
diff --git a/components/keyed_service/DEPS b/components/keyed_service/DEPS
index 6ca79ac2..f2396aa 100644
--- a/components/keyed_service/DEPS
+++ b/components/keyed_service/DEPS
@@ -2,5 +2,4 @@ include_rules = [
# KeyedService is a layered component; subdirectories must introduce
# allowances of //content dependencies as appropriate.
"-components/keyed_service/content",
- "-content",
]
diff --git a/components/metrics/DEPS b/components/metrics/DEPS
index ccaaef4..1fb5bf8 100644
--- a/components/metrics/DEPS
+++ b/components/metrics/DEPS
@@ -1,4 +1,3 @@
include_rules = [
- "-content",
"-net",
]
diff --git a/components/nacl/DEPS b/components/nacl/DEPS
new file mode 100644
index 0000000..c3505fa
--- /dev/null
+++ b/components/nacl/DEPS
@@ -0,0 +1,4 @@
+include_rules = [
+ "+content/public/common",
+ "+ipc",
+]
diff --git a/components/os_crypt/DEPS b/components/os_crypt/DEPS
index d175bda..60ae095 100644
--- a/components/os_crypt/DEPS
+++ b/components/os_crypt/DEPS
@@ -1,4 +1,3 @@
include_rules = [
- "-content",
"+crypto"
]
diff --git a/components/password_manager/DEPS b/components/password_manager/DEPS
index 60c4b7c..2e79291 100644
--- a/components/password_manager/DEPS
+++ b/components/password_manager/DEPS
@@ -9,6 +9,5 @@ include_rules = [
"+ui",
# PasswordManager is a layered component; subdirectories must explicitly
# introduce the ability to use the content layer as appropriate.
- "-content/public/common",
- "-ipc",
+ "-components/password_manager/content",
]
diff --git a/components/precache/DEPS b/components/precache/DEPS
index 0caaca9..36f628b 100644
--- a/components/precache/DEPS
+++ b/components/precache/DEPS
@@ -4,5 +4,4 @@ include_rules = [
# http://www.chromium.org/developers/design-documents/layered-components-design
"-components/precache",
"+components/precache/core",
- "-content/public",
]
diff --git a/components/query_parser/DEPS b/components/query_parser/DEPS
deleted file mode 100644
index 0faa0bf..0000000
--- a/components/query_parser/DEPS
+++ /dev/null
@@ -1,5 +0,0 @@
-include_rules = [
- # query_parser is a component that is not allowed to uses content/ so that it
- # can be shared on iOS.
- "-content",
-]
diff --git a/components/search_provider_logos/DEPS b/components/search_provider_logos/DEPS
index ba7b9c8..b580484 100644
--- a/components/search_provider_logos/DEPS
+++ b/components/search_provider_logos/DEPS
@@ -2,9 +2,4 @@ include_rules = [
"+net",
"+third_party/skia/include/core/SkBitmap.h",
"+ui/gfx/image",
-
- # search_provider_logos is shared by iOS and hence cannot depend on the
- # content layer. If //content dependencies need to be introduced, this will
- # have to become a layered component."
- "-content",
]
diff --git a/components/signin/DEPS b/components/signin/DEPS
index 6aef403..41be33e 100644
--- a/components/signin/DEPS
+++ b/components/signin/DEPS
@@ -7,9 +7,4 @@ include_rules = [
"+grit", # For generated headers
"+net",
"+sql",
- # Signin is a layered component; subdirectories must explicitly introduce
- # the ability to use the content layer as appropriate.
- "-components/signin/content",
- "-content/public/common",
- "-ipc",
]
diff --git a/components/sync_driver/DEPS b/components/sync_driver/DEPS
index 390e71b..1a20824 100644
--- a/components/sync_driver/DEPS
+++ b/components/sync_driver/DEPS
@@ -1,6 +1,4 @@
include_rules = [
- # SyncDriver is used by iOS, which does not use content.
- "-content",
"+components/os_crypt",
"+components/user_prefs/pref_registry_syncable.h",
"+sync",
diff --git a/components/tracing/DEPS b/components/tracing/DEPS
index bd05a3e..9634ba4 100644
--- a/components/tracing/DEPS
+++ b/components/tracing/DEPS
@@ -1,8 +1,4 @@
include_rules = [
"+base",
"+ipc",
-
- # This component will be compiled into NaCl, so it shouldn't depend on
- # anything in content.
- "-content",
]
diff --git a/components/translate/DEPS b/components/translate/DEPS
index e0eab64..df3f959 100644
--- a/components/translate/DEPS
+++ b/components/translate/DEPS
@@ -8,6 +8,5 @@ include_rules = [
# Translate is a layered component; subdirectories must explicitly introduce
# the ability to use the content layer as appropriate.
- "-content",
"-components/translate/content",
]
diff --git a/components/translate/content/DEPS b/components/translate/content/DEPS
index d5923ee..c3505fa 100644
--- a/components/translate/content/DEPS
+++ b/components/translate/content/DEPS
@@ -1,3 +1,4 @@
include_rules = [
"+content/public/common",
+ "+ipc",
]
diff --git a/components/usb_service/DEPS b/components/usb_service/DEPS
index 9013632..f416680 100644
--- a/components/usb_service/DEPS
+++ b/components/usb_service/DEPS
@@ -1,7 +1,6 @@
include_rules = [
"+chromeos",
- "-content",
"+content/public/browser",
"-net",
diff --git a/components/variations/DEPS b/components/variations/DEPS
new file mode 100644
index 0000000..6448868
--- /dev/null
+++ b/components/variations/DEPS
@@ -0,0 +1,3 @@
+include_rules = [
+ "+third_party/mt19937ar",
+]
diff --git a/components/visitedlink/DEPS b/components/visitedlink/DEPS
new file mode 100644
index 0000000..1c40d98
--- /dev/null
+++ b/components/visitedlink/DEPS
@@ -0,0 +1,3 @@
+include_rules = [
+ "+ipc",
+]
diff --git a/components/web_contents_delegate_android/DEPS b/components/web_contents_delegate_android/DEPS
index 647531f..e560a54 100644
--- a/components/web_contents_delegate_android/DEPS
+++ b/components/web_contents_delegate_android/DEPS
@@ -1,5 +1,6 @@
include_rules = [
"+content/public/browser",
+ "+content/public/common",
"+jni",
"+ui/base",
"+ui/gfx",
diff --git a/components/webdata/DEPS b/components/webdata/DEPS
index 2cd12ca..7ca0452 100644
--- a/components/webdata/DEPS
+++ b/components/webdata/DEPS
@@ -1,6 +1,4 @@
include_rules = [
- # WebData is used by iOS, which does not use content.
- "-content",
"+sql",
"+ui",
]