Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE
chromium.9812
chromium-gcc.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File chromium-gcc.patch of Package chromium.9812
From 2c3b57cafbbb38c13a519c9d2fda8b65691d9564 Mon Sep 17 00:00:00 2001 From: Raphael Kubo da Costa <raphael.kubo.da.costa@intel.com> Date: Thu, 7 Feb 2019 22:55:37 +0000 Subject: [PATCH] allocator shim: Swap ALIGN_LINKAGE and SHIM_ALWAYS_EXPORT's positions MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This fixes the GCC build. GCC seems to be stricter with the position of the linkage specification, so just swap the terms to prevent an error that looks like: In file included from ../../base/allocator/allocator_shim.cc:333: ../../base/allocator/allocator_shim_override_cpp_symbols.h:39:30: error: expected unqualified-id before string constant #define ALIGN_LINKAGE extern "C" ^~~ ../../base/allocator/allocator_shim_override_cpp_symbols.h:99:20: note: in expansion of macro ‘ALIGN_LINKAGE’ SHIM_ALWAYS_EXPORT ALIGN_LINKAGE void* ALIGN_NEW(std::size_t size, ^~~~~~~~~~~~~ Bug: 819294 Change-Id: I0aa16ea88cead42e83796a1c86afad8b447ddc50 Reviewed-on: https://chromium-review.googlesource.com/c/1458256 Auto-Submit: Raphael Kubo da Costa <raphael.kubo.da.costa@intel.com> Reviewed-by: Thomas Anderson <thomasanderson@chromium.org> Reviewed-by: Primiano Tucci <primiano@chromium.org> Commit-Queue: Raphael Kubo da Costa <raphael.kubo.da.costa@intel.com> Cr-Commit-Position: refs/heads/master@{#630084} --- .../allocator_shim_override_cpp_symbols.h | 20 +++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) Index: chromium-73.0.3683.75/base/allocator/allocator_shim_override_cpp_symbols.h =================================================================== --- chromium-73.0.3683.75.orig/base/allocator/allocator_shim_override_cpp_symbols.h +++ chromium-73.0.3683.75/base/allocator/allocator_shim_override_cpp_symbols.h @@ -96,57 +96,57 @@ SHIM_ALWAYS_EXPORT void operator delete[ ShimCppDelete(p); } -SHIM_ALWAYS_EXPORT ALIGN_LINKAGE void* ALIGN_NEW(std::size_t size, +ALIGN_LINKAGE SHIM_ALWAYS_EXPORT void* ALIGN_NEW(std::size_t size, ALIGN_VAL_T alignment) { return ShimCppAlignedNew(size, static_cast<size_t>(alignment)); } -SHIM_ALWAYS_EXPORT ALIGN_LINKAGE void* ALIGN_NEW_NOTHROW( +ALIGN_LINKAGE SHIM_ALWAYS_EXPORT void* ALIGN_NEW_NOTHROW( std::size_t size, ALIGN_VAL_T alignment, const std::nothrow_t&) __THROW { return ShimCppAlignedNew(size, static_cast<size_t>(alignment)); } -SHIM_ALWAYS_EXPORT ALIGN_LINKAGE void ALIGN_DEL(void* p, ALIGN_VAL_T) __THROW { +ALIGN_LINKAGE SHIM_ALWAYS_EXPORT void ALIGN_DEL(void* p, ALIGN_VAL_T) __THROW { ShimCppDelete(p); } -SHIM_ALWAYS_EXPORT ALIGN_LINKAGE void ALIGN_DEL_SIZED(void* p, +ALIGN_LINKAGE SHIM_ALWAYS_EXPORT void ALIGN_DEL_SIZED(void* p, std::size_t size, ALIGN_VAL_T) __THROW { ShimCppDelete(p); } -SHIM_ALWAYS_EXPORT ALIGN_LINKAGE void +ALIGN_LINKAGE SHIM_ALWAYS_EXPORT void ALIGN_DEL_NOTHROW(void* p, ALIGN_VAL_T, const std::nothrow_t&) __THROW { ShimCppDelete(p); } -SHIM_ALWAYS_EXPORT ALIGN_LINKAGE void* ALIGN_NEW_ARR(std::size_t size, +ALIGN_LINKAGE SHIM_ALWAYS_EXPORT void* ALIGN_NEW_ARR(std::size_t size, ALIGN_VAL_T alignment) { return ShimCppAlignedNew(size, static_cast<size_t>(alignment)); } -SHIM_ALWAYS_EXPORT ALIGN_LINKAGE void* ALIGN_NEW_ARR_NOTHROW( +ALIGN_LINKAGE SHIM_ALWAYS_EXPORT void* ALIGN_NEW_ARR_NOTHROW( std::size_t size, ALIGN_VAL_T alignment, const std::nothrow_t&) __THROW { return ShimCppAlignedNew(size, static_cast<size_t>(alignment)); } -SHIM_ALWAYS_EXPORT ALIGN_LINKAGE void ALIGN_DEL_ARR(void* p, +ALIGN_LINKAGE SHIM_ALWAYS_EXPORT void ALIGN_DEL_ARR(void* p, ALIGN_VAL_T) __THROW { ShimCppDelete(p); } -SHIM_ALWAYS_EXPORT ALIGN_LINKAGE void ALIGN_DEL_ARR_SIZED(void* p, +ALIGN_LINKAGE SHIM_ALWAYS_EXPORT void ALIGN_DEL_ARR_SIZED(void* p, std::size_t size, ALIGN_VAL_T) __THROW { ShimCppDelete(p); } -SHIM_ALWAYS_EXPORT ALIGN_LINKAGE void +ALIGN_LINKAGE SHIM_ALWAYS_EXPORT void ALIGN_DEL_ARR_NOTHROW(void* p, ALIGN_VAL_T, const std::nothrow_t&) __THROW { ShimCppDelete(p); } Index: chromium-73.0.3683.75/media/learning/common/labelled_example.cc =================================================================== --- chromium-73.0.3683.75.orig/media/learning/common/labelled_example.cc +++ chromium-73.0.3683.75/media/learning/common/labelled_example.cc @@ -59,7 +59,8 @@ bool LabelledExample::operator<(const La LabelledExample& LabelledExample::operator=(const LabelledExample& rhs) = default; -LabelledExample& LabelledExample::operator=(LabelledExample&& rhs) = default; +LabelledExample& LabelledExample::operator=(LabelledExample&& rhs) noexcept = + default; TrainingData::TrainingData() = default; Index: chromium-73.0.3683.75/media/learning/common/labelled_example.h =================================================================== --- chromium-73.0.3683.75.orig/media/learning/common/labelled_example.h +++ chromium-73.0.3683.75/media/learning/common/labelled_example.h @@ -40,7 +40,7 @@ struct COMPONENT_EXPORT(LEARNING_COMMON) bool operator<(const LabelledExample& rhs) const; LabelledExample& operator=(const LabelledExample& rhs); - LabelledExample& operator=(LabelledExample&& rhs); + LabelledExample& operator=(LabelledExample&& rhs) noexcept; // Observed feature values. // Note that to interpret these values, you probably need to have the Index: chromium-73.0.3683.75/media/learning/common/value.cc =================================================================== --- chromium-73.0.3683.75.orig/media/learning/common/value.cc +++ chromium-73.0.3683.75/media/learning/common/value.cc @@ -23,6 +23,12 @@ Value::Value(const std::string& x) : val Value::Value(const Value& other) : value_(other.value_) {} +Value::Value(Value&& rhs) noexcept = default; + +Value& Value::operator=(const Value& rhs) = default; + +Value& Value::operator=(Value&& rhs) noexcept = default; + bool Value::operator==(const Value& rhs) const { return value_ == rhs.value_; } Index: chromium-73.0.3683.75/media/learning/common/value.h =================================================================== --- chromium-73.0.3683.75.orig/media/learning/common/value.h +++ chromium-73.0.3683.75/media/learning/common/value.h @@ -38,6 +38,10 @@ class COMPONENT_EXPORT(LEARNING_COMMON) explicit Value(const std::string& x); Value(const Value& other); + Value(Value&&) noexcept; + + Value& operator=(const Value&); + Value& operator=(Value&&) noexcept; bool operator==(const Value& rhs) const; bool operator!=(const Value& rhs) const; Index: chromium-73.0.3683.75/ui/gfx/color_utils.cc =================================================================== --- chromium-73.0.3683.75.orig/ui/gfx/color_utils.cc +++ chromium-73.0.3683.75/ui/gfx/color_utils.cc @@ -431,7 +431,7 @@ SkColor SetDarkestColorForTesting(SkColo // GetContrastRatio(kWhiteLuminance, g_luminance_midpoint). The formula below // can be verified by plugging it into how GetContrastRatio() operates. g_luminance_midpoint = - std::sqrtf((dark_luminance + 0.05f) * (kWhiteLuminance + 0.05f)) - 0.05f; + std::sqrt((dark_luminance + 0.05f) * (kWhiteLuminance + 0.05f)) - 0.05f; return previous_darkest_color; } Index: chromium-73.0.3683.75/net/third_party/quic/platform/impl/quic_flags_impl.cc =================================================================== --- chromium-73.0.3683.75.orig/net/third_party/quic/platform/impl/quic_flags_impl.cc +++ chromium-73.0.3683.75/net/third_party/quic/platform/impl/quic_flags_impl.cc @@ -5,6 +5,7 @@ #include "net/third_party/quic/platform/impl/quic_flags_impl.h" #include <algorithm> +#include <initializer_list> #include <iostream> #include <set> @@ -153,9 +154,9 @@ std::string QuicFlagRegistry::GetHelp() template <> bool TypedQuicFlagHelper<bool>::SetFlag(const std::string& s) const { static const base::NoDestructor<std::set<std::string>> kTrueValues( - {"", "1", "t", "true", "y", "yes"}); + std::initializer_list<std::string>({"", "1", "t", "true", "y", "yes"})); static const base::NoDestructor<std::set<std::string>> kFalseValues( - {"0", "f", "false", "n", "no"}); + std::initializer_list<std::string>({"0", "f", "false", "n", "no"})); if (kTrueValues->find(base::ToLowerASCII(s)) != kTrueValues->end()) { *flag_ = true; return true; Index: chromium-73.0.3683.75/third_party/blink/renderer/modules/canvas/canvas2d/base_rendering_context_2d.cc =================================================================== --- chromium-73.0.3683.75.orig/third_party/blink/renderer/modules/canvas/canvas2d/base_rendering_context_2d.cc +++ chromium-73.0.3683.75/third_party/blink/renderer/modules/canvas/canvas2d/base_rendering_context_2d.cc @@ -1769,12 +1769,12 @@ void BaseRenderingContext2D::putImageDat CanvasColorParams(ColorParams().ColorSpace(), PixelFormat(), kNonOpaque); if (data_color_params.NeedsColorConversion(context_color_params) || PixelFormat() == kF16CanvasPixelFormat) { - base::CheckedNumeric<size_t> data_length = data->Size().Area(); - data_length *= context_color_params.BytesPerPixel(); - if (!data_length.IsValid()) + size_t data_length; + if (!base::CheckMul(data->Size().Area(), + context_color_params.BytesPerPixel()) + .AssignIfValid(&data_length)) return; - std::unique_ptr<uint8_t[]> converted_pixels( - new uint8_t[data_length.ValueOrDie()]); + std::unique_ptr<uint8_t[]> converted_pixels(new uint8_t[data_length]); if (data->ImageDataInCanvasColorSettings( ColorParams().ColorSpace(), PixelFormat(), converted_pixels.get(), kRGBAColorType)) { Index: chromium-73.0.3683.75/chrome/browser/media/router/providers/cast/cast_activity_manager.cc =================================================================== --- chromium-73.0.3683.75.orig/chrome/browser/media/router/providers/cast/cast_activity_manager.cc +++ chromium-73.0.3683.75/chrome/browser/media/router/providers/cast/cast_activity_manager.cc @@ -803,7 +803,7 @@ CastActivityManager::DoLaunchSessionPara callback(std::move(callback)) {} CastActivityManager::DoLaunchSessionParams::DoLaunchSessionParams( - DoLaunchSessionParams&& other) noexcept = default; + DoLaunchSessionParams&& other) = default; CastActivityManager::DoLaunchSessionParams::~DoLaunchSessionParams() = default; Index: chromium-73.0.3683.75/chrome/browser/media/router/providers/cast/cast_activity_manager.h =================================================================== --- chromium-73.0.3683.75.orig/chrome/browser/media/router/providers/cast/cast_activity_manager.h +++ chromium-73.0.3683.75/chrome/browser/media/router/providers/cast/cast_activity_manager.h @@ -295,7 +295,7 @@ class CastActivityManager : public cast_ const url::Origin& origin, int tab_id, mojom::MediaRouteProvider::CreateRouteCallback callback); - DoLaunchSessionParams(DoLaunchSessionParams&& other) noexcept; + DoLaunchSessionParams(DoLaunchSessionParams&& other); ~DoLaunchSessionParams(); DoLaunchSessionParams& operator=(DoLaunchSessionParams&&) = delete; Index: chromium-73.0.3683.75/chrome/browser/ui/views/extensions/extension_popup.cc =================================================================== --- chromium-73.0.3683.75.orig/chrome/browser/ui/views/extensions/extension_popup.cc +++ chromium-73.0.3683.75/chrome/browser/ui/views/extensions/extension_popup.cc @@ -8,7 +8,6 @@ #include "chrome/browser/devtools/devtools_window.h" #include "chrome/browser/extensions/extension_view_host.h" #include "chrome/browser/ui/browser.h" -#include "chrome/browser/ui/tabs/tab_strip_model.h" #include "content/public/browser/devtools_agent_host.h" #include "content/public/browser/notification_details.h" #include "content/public/browser/notification_source.h" Index: chromium-73.0.3683.75/chrome/browser/ui/views/extensions/extension_popup.h =================================================================== --- chromium-73.0.3683.75.orig/chrome/browser/ui/views/extensions/extension_popup.h +++ chromium-73.0.3683.75/chrome/browser/ui/views/extensions/extension_popup.h @@ -9,6 +9,7 @@ #include "base/compiler_specific.h" #include "base/macros.h" #include "base/scoped_observer.h" +#include "chrome/browser/ui/tabs/tab_strip_model.h" #include "chrome/browser/ui/tabs/tab_strip_model_observer.h" #include "chrome/browser/ui/views/extensions/extension_view_views.h" #include "content/public/browser/devtools_agent_host_observer.h" Index: chromium-73.0.3683.75/chrome/browser/ui/views/toolbar/extension_toolbar_menu_view.h =================================================================== --- chromium-73.0.3683.75.orig/chrome/browser/ui/views/toolbar/extension_toolbar_menu_view.h +++ chromium-73.0.3683.75/chrome/browser/ui/views/toolbar/extension_toolbar_menu_view.h @@ -8,6 +8,7 @@ #include "base/macros.h" #include "base/memory/weak_ptr.h" #include "base/scoped_observer.h" +#include "chrome/browser/ui/toolbar/toolbar_actions_bar.h" #include "chrome/browser/ui/toolbar/toolbar_actions_bar_observer.h" #include "chrome/browser/ui/views/toolbar/app_menu_observer.h" #include "ui/views/controls/scroll_view.h" @@ -15,7 +16,6 @@ class AppMenu; class Browser; class BrowserActionsContainer; -class ToolbarActionsBar; namespace views { class MenuItemView; Index: chromium-73.0.3683.75/content/public/browser/desktop_media_id.h =================================================================== --- chromium-73.0.3683.75.orig/content/public/browser/desktop_media_id.h +++ chromium-73.0.3683.75/content/public/browser/desktop_media_id.h @@ -41,16 +41,16 @@ struct CONTENT_EXPORT DesktopMediaID { static aura::Window* GetAuraWindowById(const DesktopMediaID& id); #endif // defined(USE_AURA) - constexpr DesktopMediaID() = default; + DesktopMediaID() = default; - constexpr DesktopMediaID(Type type, Id id) : type(type), id(id) {} + DesktopMediaID(Type type, Id id) : type(type), id(id) {} - constexpr DesktopMediaID(Type type, + DesktopMediaID(Type type, Id id, WebContentsMediaCaptureId web_contents_id) : type(type), id(id), web_contents_id(web_contents_id) {} - constexpr DesktopMediaID(Type type, Id id, bool audio_share) + DesktopMediaID(Type type, Id id, bool audio_share) : type(type), id(id), audio_share(audio_share) {} // Operators so that DesktopMediaID can be used with STL containers. Index: chromium-73.0.3683.75/extensions/browser/api/declarative_webrequest/webrequest_action.cc =================================================================== --- chromium-73.0.3683.75.orig/extensions/browser/api/declarative_webrequest/webrequest_action.cc +++ chromium-73.0.3683.75/extensions/browser/api/declarative_webrequest/webrequest_action.cc @@ -578,7 +578,7 @@ base::Optional<EventResponseDelta> WebRe CHECK(request_data.stage & stages()); EventResponseDelta result(extension_id, extension_install_time); result.cancel = true; - return result; + return base::make_optional(std::move(result)); } // @@ -613,7 +613,7 @@ base::Optional<EventResponseDelta> WebRe return base::nullopt; EventResponseDelta result(extension_id, extension_install_time); result.new_url = redirect_url_; - return result; + return base::make_optional(std::move(result)); } // @@ -642,7 +642,7 @@ WebRequestRedirectToTransparentImageActi CHECK(request_data.stage & stages()); EventResponseDelta result(extension_id, extension_install_time); result.new_url = GURL(kTransparentImageUrl); - return result; + return base::make_optional(std::move(result)); } // @@ -671,7 +671,7 @@ WebRequestRedirectToEmptyDocumentAction: CHECK(request_data.stage & stages()); EventResponseDelta result(extension_id, extension_install_time); result.new_url = GURL(kEmptyDocumentUrl); - return result; + return base::make_optional(std::move(result)); } // @@ -773,7 +773,7 @@ base::Optional<EventResponseDelta> WebRe EventResponseDelta result(extension_id, extension_install_time); result.new_url = GURL(new_url); - return result; + return base::make_optional(std::move(result)); } // @@ -813,7 +813,7 @@ WebRequestSetRequestHeaderAction::Create CHECK(request_data.stage & stages()); EventResponseDelta result(extension_id, extension_install_time); result.modified_request_headers.SetHeader(name_, value_); - return result; + return base::make_optional(std::move(result)); } // @@ -851,7 +851,7 @@ WebRequestRemoveRequestHeaderAction::Cre CHECK(request_data.stage & stages()); EventResponseDelta result(extension_id, extension_install_time); result.deleted_request_headers.push_back(name_); - return result; + return base::make_optional(std::move(result)); } // @@ -900,7 +900,7 @@ WebRequestAddResponseHeaderAction::Creat EventResponseDelta result(extension_id, extension_install_time); result.added_response_headers.push_back(make_pair(name_, value_)); - return result; + return base::make_optional(std::move(result)); } // @@ -954,7 +954,7 @@ WebRequestRemoveResponseHeaderAction::Cr continue; result.deleted_response_headers.push_back(make_pair(name_, current_value)); } - return result; + return base::make_optional(std::move(result)); } // @@ -1039,7 +1039,7 @@ base::Optional<EventResponseDelta> WebRe EventResponseDelta result(extension_id, extension_install_time); result.request_cookie_modifications.push_back( request_cookie_modification_.Clone()); - return result; + return base::make_optional(std::move(result)); } // @@ -1087,7 +1087,7 @@ base::Optional<EventResponseDelta> WebRe EventResponseDelta result(extension_id, extension_install_time); result.response_cookie_modifications.push_back( response_cookie_modification_.Clone()); - return result; + return base::make_optional(std::move(result)); } // @@ -1127,7 +1127,7 @@ WebRequestSendMessageToExtensionAction:: CHECK(request_data.stage & stages()); EventResponseDelta result(extension_id, extension_install_time); result.messages_to_extension.insert(message_); - return result; + return base::make_optional(std::move(result)); } } // namespace extensions
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor