summaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
authordarin@chromium.org <darin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-07-13 20:41:28 +0000
committerdarin@chromium.org <darin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-07-13 20:41:28 +0000
commit63e39a28e492e8f9a10d05cd970da2a1d539c0f3 (patch)
tree60271c1be8eceb87e0f8206d18f65a88b5a3d286 /net
parent8c01b7f619cb7a166c2b78269aed9f2333ad89c9 (diff)
downloadchromium_src-63e39a28e492e8f9a10d05cd970da2a1d539c0f3.zip
chromium_src-63e39a28e492e8f9a10d05cd970da2a1d539c0f3.tar.gz
chromium_src-63e39a28e492e8f9a10d05cd970da2a1d539c0f3.tar.bz2
Add COMPONENT_BUILD global define.
This avoids the need to define FOO_DLL macros for each project that we wish to optionally build as a DLL (when component=="shared_library"). This in turn means that we do not need direct_dependent_settings to define FOO_DLL, and that means that we don't need to update projects to convert transitive dependencies into explicit dependencies. This makes the component build more consistent with the static build. An alternative would be to use all_dependent_settings, but I feel that the global approach is simpler as it creates less repetition in each target definition for components. A side-effect of this change is that I needed to make base_nacl_win64 be a shared_library in the component build. R=rvargas,bradnelson,evan Review URL: http://codereview.chromium.org/7344022 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@92409 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net')
-rw-r--r--net/base/net_api.h4
-rw-r--r--net/base/ssl_false_start_blacklist.h4
-rw-r--r--net/net.gyp19
3 files changed, 4 insertions, 23 deletions
diff --git a/net/base/net_api.h b/net/base/net_api.h
index 610e974..4b017fd 100644
--- a/net/base/net_api.h
+++ b/net/base/net_api.h
@@ -10,7 +10,7 @@
// exported to consumers, and NET_TEST that allows unit tests to access features
// not intended to be used directly by real consumers.
-#if defined(NET_DLL)
+#if defined(COMPONENT_BUILD)
#if defined(WIN32)
#if defined(NET_IMPLEMENTATION)
@@ -26,7 +26,7 @@
#define NET_TEST __attribute__((visibility("default")))
#endif
-#else /// defined(NET_DLL)
+#else /// defined(COMPONENT_BUILD)
#define NET_API
#define NET_TEST
#endif
diff --git a/net/base/ssl_false_start_blacklist.h b/net/base/ssl_false_start_blacklist.h
index 5222822..1759630 100644
--- a/net/base/ssl_false_start_blacklist.h
+++ b/net/base/ssl_false_start_blacklist.h
@@ -14,11 +14,11 @@ namespace net {
// to TLS False Start. Because this set is several hundred long, it's
// precompiled by the code in ssl_false_start_blacklist_process.cc into a hash
// table for fast lookups.
-class NET_TEST SSLFalseStartBlacklist {
+class SSLFalseStartBlacklist {
public:
// IsMember returns true if the given host is in the blacklist.
// host: a DNS name in dotted form (i.e. "www.example.com")
- static bool IsMember(const char* host);
+ NET_TEST static bool IsMember(const char* host);
// Hash returns the modified djb2 hash of the given string.
static unsigned Hash(const char* str) {
diff --git a/net/net.gyp b/net/net.gyp
index 1eb0a8d..31afc17 100644
--- a/net/net.gyp
+++ b/net/net.gyp
@@ -822,27 +822,8 @@
],
[ 'component == "shared_library"', {
'defines': [
- 'NET_DLL',
'NET_IMPLEMENTATION',
],
- 'direct_dependent_settings': {
- 'defines': [
- 'NET_DLL',
- ],
- },
- 'conditions': [
- [ 'OS == "win"', {
- 'msvs_disabled_warnings': [
- # class 'std::xx' needs to have dll-interface.
- 4251,
- ],
- 'direct_dependent_settings': {
- 'msvs_disabled_warnings': [
- 4251,
- ],
- },
- }],
- ],
}],
[ 'OS == "mac"', {
'dependencies': [