diff options
-rw-r--r-- | build/common.gypi | 8 | ||||
-rw-r--r-- | content/browser/geolocation/empty_wifi_data_provider.cc | 3 | ||||
-rw-r--r-- | content/content_browser.gypi | 26 | ||||
-rw-r--r-- | content/content_tests.gypi | 5 |
4 files changed, 34 insertions, 8 deletions
diff --git a/build/common.gypi b/build/common.gypi index 7ef7c64..d0f9f22 100644 --- a/build/common.gypi +++ b/build/common.gypi @@ -503,6 +503,13 @@ 'use_pango%': 1, }], + # DBus usage. + ['OS=="linux"', { + 'use_dbus%': 1, + }, { + 'use_dbus%': 0, + }], + # We always use skia text rendering in Aura on Windows, since GDI # doesn't agree with our BackingStore. # TODO(beng): remove once skia text rendering is on by default. @@ -813,6 +820,7 @@ 'use_nss%': '<(use_nss)', 'os_bsd%': '<(os_bsd)', 'os_posix%': '<(os_posix)', + 'use_dbus%': '<(use_dbus)', 'use_glib%': '<(use_glib)', 'use_pango%': '<(use_pango)', 'use_ozone%': '<(use_ozone)', diff --git a/content/browser/geolocation/empty_wifi_data_provider.cc b/content/browser/geolocation/empty_wifi_data_provider.cc index 7255f46..d2421315 100644 --- a/content/browser/geolocation/empty_wifi_data_provider.cc +++ b/content/browser/geolocation/empty_wifi_data_provider.cc @@ -18,12 +18,9 @@ bool EmptyWifiDataProvider::GetData(WifiData* data) { return true; } -// Only define for platforms that lack a real wifi data provider. -#if !defined(OS_WIN) && !defined(OS_MACOSX) && !defined(OS_LINUX) // static WifiDataProviderImplBase* WifiDataProvider::DefaultFactoryFunction() { return new EmptyWifiDataProvider(); } -#endif } // namespace content diff --git a/content/content_browser.gypi b/content/content_browser.gypi index 0c73475..78d811f 100644 --- a/content/content_browser.gypi +++ b/content/content_browser.gypi @@ -1399,13 +1399,11 @@ }], ['toolkit_uses_gtk == 1', { 'dependencies': [ - '../build/linux/system.gyp:dbus', # For FcLangSetAdd call in render_sandbox_host_linux.cc '../build/linux/system.gyp:fontconfig', '../build/linux/system.gyp:gtk', # For XShm* in backing_store_x.cc '../build/linux/system.gyp:x11', - '../dbus/dbus.gyp:dbus', ], }], ['OS=="linux"', { @@ -1416,9 +1414,7 @@ }], ['OS=="linux" and use_aura==1', { 'dependencies': [ - '../build/linux/system.gyp:dbus', '../build/linux/system.gyp:fontconfig', - '../dbus/dbus.gyp:dbus', ], }], ['use_x11==1', { @@ -1484,6 +1480,9 @@ 'sources/': [ ['exclude', '^browser/device_orientation/data_fetcher_shared_memory_default.cc$'], ], + 'sources!': [ + 'browser/geolocation/empty_wifi_data_provider.cc', + ], 'dependencies': [ '../third_party/sudden_motion_sensor/sudden_motion_sensor.gyp:sudden_motion_sensor', ], @@ -1508,7 +1507,6 @@ ['os_bsd==1', { 'sources/': [ ['exclude', '^browser/gamepad/gamepad_platform_data_fetcher_linux\\.cc$'], - ['exclude', '^browser/geolocation/wifi_data_provider_linux\\.cc$'], ], }], ['use_aura!=1 and OS!="win"', { @@ -1594,5 +1592,23 @@ '../third_party/speex/speex.gyp:libspeex', ], }], + ['OS == "win"', { + 'sources!': [ + 'browser/geolocation/empty_wifi_data_provider.cc', + ], + }], + ['OS == "linux" and use_dbus==1', { + 'sources!': [ + 'browser/geolocation/empty_wifi_data_provider.cc', + ], + 'dependencies': [ + '../build/linux/system.gyp:dbus', + '../dbus/dbus.gyp:dbus', + ], + }, { # OS != "linux" or use_dbus==0 + 'sources!': [ + 'browser/geolocation/wifi_data_provider_linux.cc', + ], + }], ], } diff --git a/content/content_tests.gypi b/content/content_tests.gypi index d219bd0..79f2289 100644 --- a/content/content_tests.gypi +++ b/content/content_tests.gypi @@ -793,6 +793,11 @@ 'renderer/media/rtc_video_decoder_factory_tv_unittest.cc', ], }], + ['use_dbus==0', { + 'sources!': [ + 'browser/geolocation/wifi_data_provider_linux_unittest.cc', + ], + }], ], }, ], |