Compilation of qtwebengine-5.15.2_p20210824-r1 fails with In file included from gen/base/base_jumbo_3.cc:55: ./../../../../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/base/task/thread_pool.cc: At global scope: ./../../../../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/base/task/thread_pool.cc:18:7: error: redefinition of ‘class base::{anonymous}::PostTaskAndReplyWithTraitsTaskRunner’ 18 | class PostTaskAndReplyWithTraitsTaskRunner | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ In file included from gen/base/base_jumbo_3.cc:30: ./../../../../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/base/task/post_task.cc:20:7: note: previous definition of ‘class base::{anonymous}::PostTaskAndReplyWithTraitsTaskRunner’ 20 | class PostTaskAndReplyWithTraitsTaskRunner | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Maybe something related to jumbo-build. Reproducible: Always
Can you include the full build.log please and emerge --info?
Created attachment 740196 [details] build.log.gz
Created attachment 740199 [details] emerge-info.txt
Created attachment 740202 [details] emerge-pvq.txt
(In reply to Sam James from comment #1) > Can you include the full build.log please and emerge --info? Yes one moment a little patience :P
(In reply to Marco Genasci from comment #5) > (In reply to Sam James from comment #1) > > Can you include the full build.log please and emerge --info? > > Yes one moment a little patience :P Sorry, it's robotic at this point, because sometimes people never do. I did have a feeling you would come through though ;)
I confirm that disabling the jumbo-build use flag the build ends correctly.
Same issue. I will try without jumbo-build too.
(In reply to Sébastien P. from comment #8) > Same issue. I will try without jumbo-build too. (works too)
Disable jumbo-build did not helped me :-( # emerge -pqv '=dev-qt/qtwebengine-5.15.2_p20210824-r1::gentoo' [ebuild U ] dev-qt/qtwebengine-5.15.2_p20210824-r1 [5.15.2_p20210625] USE="alsa bindist pulseaudio system-ffmpeg system-icu widgets -debug -designer -geolocation -jumbo-build* -kerberos -test"
Created attachment 743850 [details] emerge-info.txt
Created attachment 743853 [details] build.log.gz
On my another system qtwebengine compiles fine even with jumbo-build enabled. I Didn't identified the difference yet. The duplicity: worker /var/tmp/notmpfs/portage/dev-qt/qtwebengine-5.15.2_p20210824-r1/work/qtwebengine-5.15.2_p20210824_build # grep -r PostTaskAndReplyWithTraitsTaskRunner ../ ../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/base/task/post_task.cc:class PostTaskAndReplyWithTraitsTaskRunner ../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/base/task/post_task.cc: explicit PostTaskAndReplyWithTraitsTaskRunner(const TaskTraits& traits) ../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/base/task/post_task.cc: return PostTaskAndReplyWithTraitsTaskRunner(traits).PostTaskAndReply( ../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/base/task/thread_pool.cc:class PostTaskAndReplyWithTraitsTaskRunner ../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/base/task/thread_pool.cc: explicit PostTaskAndReplyWithTraitsTaskRunner(const TaskTraits& traits) ../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/base/task/thread_pool.cc: return PostTaskAndReplyWithTraitsTaskRunner(traits).PostTaskAndReply(
I've finished merge manually. No other issues. After checking both systems, the only difference is that one system is pure alsa and second system is pulseaudio. But alsa USE flag is enabled as well. Maybe this is cause of the duplicity.
Created attachment 745047 [details, diff] fix_PostTaskAndReplyWithTraitsTaskRunner_duplicity.patch Patch that removes duplicity
This code is in /src/3rdparty/chromium/base/task/. I do not code in C but it looks like there is two identical definitions in thread_pool.cc and post_task.cc. Maybe it should be better to report it upstream?
Since this is used later on in thread_pool.cc, I suspect your patch is breaking build with USE=-jumbo-build. PostTaskAndReplyWithTraitsTaskRunner exists in post_task.cc since 2017: https://github.com/chromium/chromium/commit/2499aee158845e85799f9bbef03de427768bc043 thread_pool.cc was only introduced in 2020, duplicating PostTaskAndReplyWithTraitsTaskRunner: https://github.com/chromium/chromium/commit/43de5c41e258bd1a89adc84e4d9da3ec816c0224 The duplication still exists in chromium source today: https://github.com/chromium/chromium/search?q=PostTaskAndReplyWithTraitsTaskRunner Since chromium gave up on jumbo-build, afaik, I am not sure it even makes sense to contact chromium upstream about it; @sultan?
Usually the fix for these (Qt) upstream is, to my understanding, to either rename one of the offenders, or exclude them from jumbo build. I've still not had any luck in hitting this, so I haven't been able to experiment with it either. (The one who reported this bug here has already volunteered to test those ideas for me, but I haven't had the time to come up with any patches to try yet.)
(In reply to Andreas Sturmlechner from comment #17) > Since this is used later on in thread_pool.cc, I suspect your patch is > breaking build with USE=-jumbo-build. > > > PostTaskAndReplyWithTraitsTaskRunner exists in post_task.cc since 2017: > https://github.com/chromium/chromium/commit/ > 2499aee158845e85799f9bbef03de427768bc043 > > thread_pool.cc was only introduced in 2020, duplicating > PostTaskAndReplyWithTraitsTaskRunner: > https://github.com/chromium/chromium/commit/ > 43de5c41e258bd1a89adc84e4d9da3ec816c0224 > > The duplication still exists in chromium source today: > https://github.com/chromium/chromium/ > search?q=PostTaskAndReplyWithTraitsTaskRunner > > Since chromium gave up on jumbo-build, afaik, I am not sure it even makes > sense to contact chromium upstream about it; @sultan? The declaration is identical, but the content of the classes is different. You can rename one of them, because it is a declared in an anonymous namespace and therefore only used inside the C++ file. Should I write a patch? However, it is unlikely to get merged in Chromium.
Created attachment 747654 [details, diff] jumbo patch This should do it. I'm also unable to reproduce it. Maybe someone else can test.
Created attachment 747681 [details] build-with-patch.log.gz I tried patch but the compilation fails with another error.
Created attachment 747705 [details, diff] std::sort patch This should fix missing std::sort. I can upstream this one.
Created attachment 747729 [details] build.log.gz The latest error gone but new one appears.
(In reply to Marco Genasci from comment #23) > Created attachment 747729 [details] > build.log.gz > > The latest error gone but new one appears. Can you please show me the content of: gen/third_party/blink/renderer/core/html/html_jumbo_1.cc
Also please content of: gen/third_party/blink/renderer/core/animation/animation_jumbo_1.cc
Created attachment 747750 [details] animation_jumbo_1.cc As asked
Created attachment 747753 [details] html_jumbo_1.cc
Created attachment 747768 [details, diff] combined jumbo patch Thank you. I combined everything into a single patch. Please give it a try.
Created attachment 747789 [details] build.log.gz Similar to first error: In file included from gen/third_party/blink/renderer/core/layout/svg/svg_layout_jumbo_1.cc:35: ./../../../../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/third_party/blink/renderer/core/layout/svg/svg_layout_tree_as_text.cc:255:30: error: redefinition of ‘base::Optional<blink::Color> blink::ResolveColor(const blink::ComputedStyle&, const blink::SVGPaint&, const blink::SVGPaint&)’ 255 | static base::Optional<Color> ResolveColor(const ComputedStyle& style, | ^~~~~~~~~~~~ In file included from gen/third_party/blink/renderer/core/layout/svg/svg_layout_jumbo_1.cc:24: ./../../../../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/third_party/blink/renderer/core/layout/svg/layout_svg_resource_paint_server.cc:97:30: note: ‘base::Optional<blink::Color> blink::ResolveColor(const blink::ComputedStyle&, const blink::SVGPaint&, const blink::SVGPaint&)’ previously defined here 97 | static base::Optional<Color> ResolveColor(const ComputedStyle& style, | ^~~~~~~~~~~~ In file included from gen/third_party/blink/renderer/core/layout/svg/svg_layout_jumbo_1.cc:35: ./../../../../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/third_party/blink/renderer/core/layout/svg/svg_layout_tree_as_text.cc:255:30: warning: ‘base::Optional<blink::Color> blink::ResolveColor(const blink::ComputedStyle&, const blink::SVGPaint&, const blink::SVGPaint&)’ defined but not used [-Wunused-function] 255 | static base::Optional<Color> ResolveColor(const ComputedStyle& style, | ^~~~~~~~~~~~
Created attachment 747798 [details, diff] combined jumbo patch v2 Hopefully fixed with attached patch.
Created attachment 747807 [details, diff] combined jumbo patch v3 Finally I changed patch for these errors: ./../../../../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/third_party/blink/renderer/core/html/forms/picker_indicator_element.cc:63:17: error: ‘IsFormControlsRefreshEnabled’ is not a member of ‘blink::features’; did you mean ‘features::IsFormControlsRefreshEnabled’? 63 | if (features::IsFormControlsRefreshEnabled()) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ In file included from ./../../../../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/third_party/blink/renderer/core/html/forms/html_input_element.cc:86, from gen/third_party/blink/renderer/core/html/html_jumbo_2.cc:19: ../../../../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/ui/base/ui_base_features.h:86:41: note: ‘features::IsFormControlsRefreshEnabled’ declared here 86 | COMPONENT_EXPORT(UI_BASE_FEATURES) bool IsFormControlsRefreshEnabled(); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ In file included from gen/third_party/blink/renderer/core/html/html_jumbo_2.cc:49: ./../../../../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/third_party/blink/renderer/core/html/forms/slider_thumb_element.cc: In member function ‘void blink::SliderThumbElement::SetPositionFromValue()’: ./../../../../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/third_party/blink/renderer/core/html/forms/slider_thumb_element.cc:66:19: error: ‘IsFormControlsRefreshEnabled’ is not a member of ‘blink::features’; did you mean ‘features::IsFormControlsRefreshEnabled’? 66 | if (features::IsFormControlsRefreshEnabled()) { | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ In file included from ./../../../../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/third_party/blink/renderer/core/html/forms/html_input_element.cc:86, from gen/third_party/blink/renderer/core/html/html_jumbo_2.cc:19: ../../../../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/ui/base/ui_base_features.h:86:41: note: ‘features::IsFormControlsRefreshEnabled’ declared here 86 | COMPONENT_EXPORT(UI_BASE_FEATURES) bool IsFormControlsRefreshEnabled(); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ In file included from gen/third_party/blink/renderer/platform/platform_jumbo_7.cc:102: ./../../../../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/third_party/blink/renderer/platform/webrtc/peer_connection_remote_audio_source.cc:23:6: error: redefinition of ‘void blink::{anonymous}::SendLogMessage(const string&)’ 23 | void SendLogMessage(const std::string& message) { | ^~~~~~~~~~~~~~ In file included from gen/third_party/blink/renderer/platform/platform_jumbo_7.cc:5: ./../../../../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/third_party/blink/renderer/platform/mediastream/media_stream_source.cc:43:6: note: ‘void blink::{anonymous}::SendLogMessage(const string&)’ previously defined here 43 | void SendLogMessage(const std::string& message) { | ^~~~~~~~~~~~~~ In file included from gen/third_party/blink/renderer/platform/platform_jumbo_7.cc:102: ./../../../../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/third_party/blink/renderer/platform/webrtc/peer_connection_remote_audio_source.cc:23:6: warning: ‘void blink::{anonymous}::SendLogMessage(const string&)’ defined but not used [-Wunused-function] 23 | void SendLogMessage(const std::string& message) { | ^~~~~~~~~~~~~~ In file included from gen/third_party/blink/renderer/platform/platform_jumbo_7.cc:47: ./../../../../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/third_party/blink/renderer/platform/peerconnection/webrtc_audio_sink.cc:23:6: warning: ‘void {anonymous}::SendLogMessage(const string&)’ defined but not used [-Wunused-function] 23 | void SendLogMessage(const std::string& message) { | ^~~~~~~~~~~~~~ and now patch seems to works on my system.
I re-run again by beginning the emerge process to be sure that patch works.
I will try v3 too.
Created attachment 747861 [details, diff] combined jumbo patch v3 Sorry I missed to patch a file.
It's still compiling on my side: 18474/22934 But I will the v3v2 version^^.
I confirm the latest patch in my system works.
https://bugs.gentoo.org/attachment.cgi?id=747861 works too for me. It ended during the night. I have just these QAs: * QA Notice: Package triggers severe warnings which indicate that it * may exhibit random runtime failures. * ../../../../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/third_party/pdfium/core/fxcrt/retain_ptr.h:116:11: warning: ‘void operator delete(void*, std::size_t)’ called on pointer ‘<unknown>’ with nonzero offset 32 [-Wfree-nonheap-object] * ../../../../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/third_party/pdfium/core/fxcrt/retain_ptr.h:116:11: warning: ‘void operator delete(void*, std::size_t)’ called on pointer ‘<unknown>’ with nonzero offset 16 [-Wfree-nonheap-object] * ../../../../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/net/base/mime_util.cc:239:18: warning: offset ‘5’ outside bounds of constant string [-Warray-bounds] * ../../../../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/net/base/mime_util.cc:239:18: warning: offset ‘4’ outside bounds of constant string [-Warray-bounds] * ../../../../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/net/dns/host_resolver.cc:82:16: warning: returning reference to temporary [-Wreturn-local-addr] * ../../../../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/third_party/webrtc/api/function_view.h:79:17: warning: the compiler can assume that the address of ‘f’ will never be NULL [-Waddress Last month, without this patch and USE=-jubo, I had: QA Notice: Package triggers severe warnings which indicate that it may exhibit random runtime failures. ../../../../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/net/base/mime_util.cc:239:18: warning: offset ‘5’ outside bounds of constant string [-Warray-bounds] ../../../../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/net/base/mime_util.cc:239:18: warning: offset ‘4’ outside bounds of constant string [-Warray-bounds] ../../../../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/net/dns/host_resolver.cc:82:16: warning: returning reference to temporary [-Wreturn-local-addr] ../../../../qtwebengine-5.15.2_p20210824/src/3rdparty/chromium/third_party/webrtc/api/function_view.h:79:17: warning: the compiler can assume that the address of ‘f’ will never be NULL [-Waddress] Maybe there is a few things to improve? (do not have the time to check, go to work…)
(In reply to Stephan Hartmann from comment #19) > However, it is unlikely to get merged in Chromium. Yeah, qtwebengine-chromium would probably make more sense. :]
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=0aa1d9f9b6ba9c91712c6b2a5f3473e596f144d8 commit 0aa1d9f9b6ba9c91712c6b2a5f3473e596f144d8 Author: Stephan Hartmann <sultan@gentoo.org> AuthorDate: 2021-11-05 06:55:18 +0000 Commit: Sam James <sam@gentoo.org> CommitDate: 2021-11-05 07:01:23 +0000 dev-qt/qtwebengine: add jumbo-build patch Closes: https://bugs.gentoo.org/813957 Thanks-to: Marco Genasci <fedeliallalinea@gmail.com> (enhancing patch) Signed-off-by: Sam James <sam@gentoo.org> dev-qt/qtwebengine/Manifest | 1 + dev-qt/qtwebengine/qtwebengine-5.15.2_p20211019.ebuild | 2 ++ 2 files changed, 3 insertions(+)
I think the error was caused by my own configuration in package.env because also 5.15.2_p20211019 version has reproduced similar errors. Compiling without this configuration compiles fine. Sorry for the noise.
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/proj/qt.git/commit/?id=5a5e656f6ad20d963eaf5d6f47f4fcc78e220899 commit 5a5e656f6ad20d963eaf5d6f47f4fcc78e220899 Author: Stephan Hartmann <sultan@gentoo.org> AuthorDate: 2021-11-05 06:55:18 +0000 Commit: Andreas Sturmlechner <asturm@gentoo.org> CommitDate: 2021-12-24 23:39:15 +0000 dev-qt/qtwebengine: add jumbo-build patch * asturm 2021-12-25: Fix SRC_URI - always add patch, not just in release Bug: https://bugs.gentoo.org/813957 Thanks-to: Marco Genasci <fedeliallalinea@gmail.com> (enhancing patch) Signed-off-by: Sam James <sam@gentoo.org> Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org> dev-qt/qtwebengine/Manifest | 1 + dev-qt/qtwebengine/qtwebengine-5.15.2.9999.ebuild | 6 ++++-- 2 files changed, 5 insertions(+), 2 deletions(-)