diff options
-rw-r--r-- | base/BUILD.gn | 20 | ||||
-rw-r--r-- | cc/BUILD.gn | 2 | ||||
-rw-r--r-- | components/policy/BUILD.gn | 14 | ||||
-rw-r--r-- | components/policy/core/common/BUILD.gn | 3 | ||||
-rw-r--r-- | content/common/BUILD.gn | 1 | ||||
-rw-r--r-- | device/bluetooth/BUILD.gn | 4 | ||||
-rw-r--r-- | gpu/BUILD.gn | 4 | ||||
-rw-r--r-- | gpu/command_buffer/client/BUILD.gn | 16 | ||||
-rw-r--r-- | gpu/command_buffer/command_buffer.gypi | 1 | ||||
-rw-r--r-- | ui/platform_window/BUILD.gn | 5 | ||||
-rw-r--r-- | ui/platform_window/platform_window.gyp | 4 | ||||
-rw-r--r-- | ui/platform_window/platform_window_export.h | 29 |
12 files changed, 40 insertions, 63 deletions
diff --git a/base/BUILD.gn b/base/BUILD.gn index e77b189..df06d24 100644 --- a/base/BUILD.gn +++ b/base/BUILD.gn @@ -13,6 +13,18 @@ config("base_implementation") { defines = [ "BASE_IMPLEMENTATION" ] } +if (is_win) { + # This is in a separate config so the flags can be applied to dependents. + # ldflags in GN aren't automatically inherited. + config("base_win_linker_flags") { + ldflags = [ + "/DELAYLOAD:cfgmgr32.dll", + "/DELAYLOAD:powrprof.dll", + "/DELAYLOAD:setupapi.dll", + ] + } +} + source_set("base_paths") { sources = [ "base_paths.cc", @@ -732,11 +744,7 @@ component("base") { "powrprof.lib", "setupapi.lib", ] - ldflags = [ - "/DELAYLOAD:cfgmgr32.dll", - "/DELAYLOAD:powrprof.dll", - "/DELAYLOAD:setupapi.dll", - ] + all_dependent_configs = [ ":base_win_linker_flags" ] } else if (!is_nacl) { # Non-Windows. deps += [ "//third_party/libevent" ] @@ -939,7 +947,7 @@ if (is_linux && !is_chromeos) { } } -source_set("prefs") { +component("prefs") { sources = [ "prefs/base_prefs_export.h", "prefs/default_pref_store.cc", diff --git a/cc/BUILD.gn b/cc/BUILD.gn index b0b2754..8c695e5 100644 --- a/cc/BUILD.gn +++ b/cc/BUILD.gn @@ -540,7 +540,6 @@ component("cc") { "//cc/surfaces:surface_id", "//gpu", "//gpu/command_buffer/client:gles2_interface", - "//gpu/command_buffer/client:gpu_memory_buffer_manager", "//media", "//ui/events:events_base", "//ui/gfx", @@ -706,7 +705,6 @@ source_set("test_support") { "//base/third_party/dynamic_annotations", "//gpu/command_buffer/client:gles2_c_lib", "//gpu/command_buffer/client:gles2_implementation", - "//gpu/command_buffer/client:gpu_memory_buffer_manager", "//gpu/command_buffer/client:gl_in_process_context", "//gpu/command_buffer/common:gles2_utils", "//gpu/skia_bindings", diff --git a/components/policy/BUILD.gn b/components/policy/BUILD.gn index f3b8257..a708c2a 100644 --- a/components/policy/BUILD.gn +++ b/components/policy/BUILD.gn @@ -161,6 +161,19 @@ if (enable_configuration_policy) { ] } + # The dependencies here are kind of messed up. + # + # //components/policy/core/browser and .../common depend on this target, + # and require it to be compiled with POLICY_COMPONENT_IMPLEMENTATION to + # export the necessary symbols in a component build. But other targets like + # //chrome/browser also depend on this target, which in component build + # ends up in another shared library, but with the IMPLEMENTATION flag set + # incorrectly. + # + # This only reason this works is that this target is a shared library and + # the compilation units that this depends on in policy/core/common happen to + # not be brought in in the "bad" case. This needs serious untangling, maybe + # these files can just be put into policy/core/common? static_library("policy") { sources = [ constants_header_path, @@ -182,6 +195,7 @@ if (enable_configuration_policy) { deps = [ ":chrome_settings_proto_generated_compile", ":policy", + "//components/policy/core/common", ] } diff --git a/components/policy/core/common/BUILD.gn b/components/policy/core/common/BUILD.gn index 40ed1da..27cfe1c 100644 --- a/components/policy/core/common/BUILD.gn +++ b/components/policy/core/common/BUILD.gn @@ -141,6 +141,9 @@ source_set("common") { "//url", ] + if (is_win) { + libs = [ "netapi32.lib" ] + } if (is_android) { sources += [ "cloud/component_cloud_policy_service_stub.cc" ] sources -= [ diff --git a/content/common/BUILD.gn b/content/common/BUILD.gn index 80e6c77..8e93d70 100644 --- a/content/common/BUILD.gn +++ b/content/common/BUILD.gn @@ -144,7 +144,6 @@ source_set("common") { "//build/util:webkit_version", "//components/tracing", "//gpu/command_buffer/client:gles2_interface", - "//gpu/command_buffer/client:gpu_memory_buffer_manager", "//net", "//skia", "//third_party/icu", diff --git a/device/bluetooth/BUILD.gn b/device/bluetooth/BUILD.gn index 48c8f82..3153255 100644 --- a/device/bluetooth/BUILD.gn +++ b/device/bluetooth/BUILD.gn @@ -118,7 +118,9 @@ component("bluetooth") { "//ui/base", ] - if (is_chromeos) { + if (is_win) { + libs = [ "setupapi.lib" ] + } else if (is_chromeos) { deps += [ "//chromeos", "//dbus", diff --git a/gpu/BUILD.gn b/gpu/BUILD.gn index c27cb8f..d8ac30f 100644 --- a/gpu/BUILD.gn +++ b/gpu/BUILD.gn @@ -27,9 +27,7 @@ # gpu.gyp:disk_cache_proto => //gpu/command_buffer/service:disk_cache_proto # # command_buffer/command_buffer.gyp:gles2_utils => -# //gpu/command_buffer/common -# (Merged in to here because the separate file exists in GYP only to break -# a .gyp file dependency cycle which GN doesn't have.) +# //gpu/command_buffer/common:gles2_utils # # gpu/skia_bindings/skia_bindings.gyp:gpu_skia_bindings => //gpu/skia_bindings diff --git a/gpu/command_buffer/client/BUILD.gn b/gpu/command_buffer/client/BUILD.gn index d86edd4..fabc82a 100644 --- a/gpu/command_buffer/client/BUILD.gn +++ b/gpu/command_buffer/client/BUILD.gn @@ -9,6 +9,8 @@ source_set("client") { "fenced_allocator.cc", "fenced_allocator.h", "gpu_control.h", + "gpu_memory_buffer_manager.cc", + "gpu_memory_buffer_manager.h", "mapped_memory.cc", "mapped_memory.h", "ring_buffer.cc", @@ -113,17 +115,6 @@ source_set("gles2_interface") { ] } -source_set("gpu_memory_buffer_manager") { - sources = [ - "gpu_memory_buffer_manager.cc", - "gpu_memory_buffer_manager.h", - ] - configs += [ "//gpu:gpu_implementation" ] - deps = [ - "//ui/gfx", - ] -} - # Library emulates GLES2 using command_buffers. component("gles2_implementation") { sources = gles2_implementation_source_files @@ -138,7 +129,7 @@ component("gles2_implementation") { ":gles2_cmd_helper", ":gles2_interface", "//base", - "//gpu/command_buffer/common", + "//gpu/command_buffer/common:gles2_utils", "//ui/gfx/geometry", ] } @@ -175,7 +166,6 @@ component("gl_in_process_context") { deps = [ ":gles2_implementation", - ":gpu_memory_buffer_manager", "//gpu", "//gpu/command_buffer/common:gles2_utils", "//base", diff --git a/gpu/command_buffer/command_buffer.gypi b/gpu/command_buffer/command_buffer.gypi index 473da92e..c355f2c 100644 --- a/gpu/command_buffer/command_buffer.gypi +++ b/gpu/command_buffer/command_buffer.gypi @@ -8,7 +8,6 @@ 'gles2_utils_target': 0, }, 'target_conditions': [ - # This part is shared between the targets defined below. ['gles2_utils_target==1', { 'defines': [ 'GLES2_UTILS_IMPLEMENTATION', diff --git a/ui/platform_window/BUILD.gn b/ui/platform_window/BUILD.gn index 835fc70..2d9680b 100644 --- a/ui/platform_window/BUILD.gn +++ b/ui/platform_window/BUILD.gn @@ -2,13 +2,10 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -component("platform_window") { - defines = [ "PLATFORM_WINDOW_IMPLEMENTATION" ] - +source_set("platform_window") { sources = [ "platform_window.h", "platform_window_delegate.h", - "platform_window_export.h", ] deps = [ diff --git a/ui/platform_window/platform_window.gyp b/ui/platform_window/platform_window.gyp index a01fb37..a006e75 100644 --- a/ui/platform_window/platform_window.gyp +++ b/ui/platform_window/platform_window.gyp @@ -9,12 +9,10 @@ 'targets': [{ # GN version: //ui/platform_window 'target_name': 'platform_window', - 'type': '<(component)', - 'defines': [ 'PLATFORM_WINDOW_IMPLEMENTATION' ], + 'type': 'none', 'sources': [ 'platform_window.h', 'platform_window_delegate.h', - 'platform_window_export.h', ], }], } diff --git a/ui/platform_window/platform_window_export.h b/ui/platform_window/platform_window_export.h deleted file mode 100644 index 45f434a..0000000 --- a/ui/platform_window/platform_window_export.h +++ /dev/null @@ -1,29 +0,0 @@ -// Copyright 2014 The Chromium Authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#ifndef UI_PLATFORM_WINDOW_PLATFORM_WINDOW_EXPORT_H_ -#define UI_PLATFORM_WINDOW_PLATFORM_WINDOW_EXPORT_H_ - -#if defined(COMPONENT_BUILD) -#if defined(WIN32) - -#if defined(PLATFORM_WINDOW_IMPLEMENTATION) -#define PLATFORM_WINDOW_EXPORT __declspec(dllexport) -#else -#define PLATFORM_WINDOW_EXPORT __declspec(dllimport) -#endif // defined(PLATFORM_WINDOW_IMPLEMENTATION) - -#else // defined(WIN32) -#if defined(PLATFORM_WINDOW_IMPLEMENTATION) -#define PLATFORM_WINDOW_EXPORT __attribute__((visibility("default"))) -#else -#define PLATFORM_WINDOW_EXPORT -#endif -#endif - -#else // defined(COMPONENT_BUILD) -#define PLATFORM_WINDOW_EXPORT -#endif - -#endif // UI_PLATFORM_WINDOW_PLATFORM_WINDOW_EXPORT_H_ |