Closed 0xC0ncord closed 2 years ago
I've removed that patch as it is no longer needed.
Hmm. What then provides media/gpu/buildflags.h
? Maybe I'm missing a dependency?
Interesting. I'm building with vaapi
only right now and I see media/gpu/buildflags.h
in out/Release/gen…
and its contents is as follows:
// Generated by build/write_buildflag_header.py
// From "//media/gpu:buildflags"
#ifndef MEDIA_GPU_BUILDFLAGS_H_
#define MEDIA_GPU_BUILDFLAGS_H_
#include "build/buildflag.h"
#define BUILDFLAG_INTERNAL_USE_VAAPI() (1)
#define BUILDFLAG_INTERNAL_USE_VAAPI_IMAGE_CODECS() (0)
#define BUILDFLAG_INTERNAL_USE_V4L2_CODEC() (0)
#define BUILDFLAG_INTERNAL_USE_LIBV4L2() (0)
#define BUILDFLAG_INTERNAL_USE_VAAPI_X11() (1)
#endif // MEDIA_GPU_BUILDFLAGS_H_
Something prevents the generation of this file. Maybe wayland
?
Probbaly vdpau
patch needs to be further improved? No idea.
@gringus Did you build with vdpau
successfully?
Indeed I do not see that file in the build directory on my system. Let me see if I can find out if a USE flag like wayland
as you said is preventing it from being generated.
It looks like USE=wayland
is what may be causing this. I have disabled wayland
(and screencast
) and I now see the generated file.
Could be that Chromium does not support that under wayland…
Could be that Chromium does not support that under wayland…
Potentially, but I have my doubts. I am trying this out on a second machine and so far it looks like it is building... If the build succeeds, it should be done in another hour or two. We will see.
I built it with vaapi vdpau
flags but without wayland
(I also had to add the patch from https://bugs.gentoo.org/823857)
Could be that Chromium does not support that under wayland…
Potentially, but I have my doubts. I am trying this out on a second machine and so far it looks like it is building... If the build succeeds, it should be done in another hour or two. We will see.
Well this is really weird... On my secondary machine, I have USE="wayland vaapi vdpau"
and was able to emerge ungoogled-chromium without a problem. I did still apply the patch from https://bugs.gentoo.org/823857 though.
www-client/ungoogled-chromium-96.0.4664.45-r1::pf4public was built with the following:
USE="cfi clang convert-dict cups custom-cflags hangouts js-type-check official optimize-thinlto optimize-webui partition pgo proprietary-codecs pulseaudio screencast (selinux) suid tcmalloc thinlto vaapi vdpau wayland -debug -enable-driver -headless -kerberos -system-ffmpeg -system-harfbuzz -system-icu -system-jsoncpp -system-libevent -system-libvpx -system-openh264 -system-openjpeg -system-re2 -widevine" L10N="-am -ar -bg -bn -ca -cs -da -de -el -en-GB -es -es-419 -et -fa -fi -fil -fr -gu -he -hi -hr -hu -id -it -ja -kn -ko -lt -lv -ml -mr -ms -nb -nl -pl -pt-BR -pt-PT -ro -ru -sk -sl -sr -sv -sw -ta -te -th -tr -uk -vi -zh-CN -zh-TW"
CFLAGS="-march=znver2 -mtune=znver2 -O3 -pipe -fomit-frame-pointer -fPIE -fstack-protector-strong -D_FORTIFY_SOURCE=2 -fstack-clash-protection -flto=thin -fPIC -Wno-unknown-warning-option -Wno-builtin-macro-redefined"
CXXFLAGS="-march=znver2 -mtune=znver2 -O3 -pipe -fomit-frame-pointer -fPIE -fstack-protector-strong -D_FORTIFY_SOURCE=2 -fstack-clash-protection -flto=thin -stdlib=libc++ -fPIC -flax-vector-conversions=all -Wno-unknown-warning-option -Wno-builtin-macro-redefined"
LDFLAGS="-Wl,-O1 -Wl,--as-needed -Wl,-S -Wl,-z,now -Wl,-z,relro -fuse-ld=lld -Wl,-unwindlib=libunwind -lhardened_malloc -Wl,--thinlto-jobs=17"
On my secondary machine, I have
USE="wayland vaapi vdpau"
and was able to emerge ungoogled-chromium without a problem.
What differs them?
On my secondary machine, I have
USE="wayland vaapi vdpau"
and was able to emerge ungoogled-chromium without a problem.What differs them?
As far as the flags used to build Chromium, nothing.
Package versions?
@gringus Which packages do you mean? Assuming you mean ungoogled-chromium
itself, 96.0.4664.45-r1 for both. I am not using any of the system-*
USE flags.
I meant other dependent packages (eg. glibc
etc.) which could be on different version. Some could be buggy and cause issues.
So I managed to solve this somehow, but unfortunately I'm not sure what it was. I had 2 versions of LLVM installed simultaneously, and it seems that lld
was wanting to link to libraries belonging to a different LLVM version. After removing Clang/LLVM 12 and rebuilding the entire toolchain, the issue went away.
Very weird. Thanks for the support.
Trying to deal with #118 I hit this. This is what's failing for me:
[ebuild R ] www-client/ungoogled-chromium-96.0.4664.45-r1::pf4public USE="clang convert-dict cups hangouts js-type-check official optimize-thinlto optimize-webui partition proprietary-codecs pulseaudio screencast -system-ffmpeg system-harfbuzz system-icu thinlto vaapi wayland -cfi -custom-cflags -debug -enable-driver -headless -kerberos -pgo (-selinux) -suid -system-jsoncpp -system-libevent -system-libvpx -system-openh264 -system-openjpeg -system-re2 -tcmalloc -vdpau -widevine"
Can I do/test something to help with this too?
@logrusx Your issue is obviously different, please open a separate issue and provide full build log!
I'm pretty sure it's the same issue, as the error is the same. I'll provide the build log as soon as the current build finishes or breaks, I apologize for not doing that first place. It should be ready shortly.
I'm pretty sure it's the same issue, as the error is the same. I'll provide the build log as soon as the current build finishes or breaks, I apologize for not doing that first place. It should be ready shortly.
This is what I did to resolve my original issue:
I uninstalled all other versions of Clang, LLVM, and dependencies except for versions 13.0.0. That includes libcxx
, libcxxabi
, lld
, and also llvmgold
. I rebuilt my entire Clang/LLVM toolchain using gcc
and without LTO enabled and made sure that only versions 13.0.0 were being pulled in. After that, I rebuilt the entire toolchain again but this time using Clang and LTO. Finally, I emerged ungoogled-chromium
after this rebuild and did not have the problem anymore.
I also went as far as to mask all of these packages versions lower than 13.0.0 just to be sure.
Hopefully that helps.
@0xC0ncord thanks for your responce!
This is a new installation and it has had nothing older than clang 13 and gcc 11.2.
Is I mentioned above, I was trying to solve another issue by matching the use flags to original chromium and disabling the ones not present for it. This lead me to the current issue, but I was too quick to start eliminating use flag changes and didn't grab the build log. It seems it was -system-ffmpeg as I took the path of eliminating the changes I made to match the original source and when I turned back on the system ffmpeg, the build passed way over the place it broke before. The current build is almost finished and as soon as it finishes I'll disable system-ffmpeg again to extract build log.
In the mean time, could you please check if it's enabled for you? Regards
In the mean time, could you please check if it's enabled for you? Regards
I currently have all system-*
flags disabled for my builds.
@0xC0ncord what about ccache, did you use it?
@0xC0ncord what about ccache, did you use it?
No, I didn't.
It looks like ccache with either system ffmpeg or libevent is the culprit with my issue. Are you sure you couldn't have forgotten ccache enabled? I'm asking that, because recompiling your compiler would effectively invalidate the cache(if explicit measures to prevent it aren't taken) and the first pass would be cache building only.
I'm sure because I never enabled ccache in the first place. I think what caused the issue for you is definitely different from what caused it for me. Ultimately I think somehow when I had this issue my clang toolchain was actually completely broken, as some packages outright refused to compile about the same time as this, but I didn't think those issues were related at the time.
Ok, it was worth digging into it, because now at least somebody could find out that they might need to disable ccache, just by searching on the Internet and not needing to find it out the hard way. Thanks for your support! Regards
Interestingly I just had this exact same issue again but on a different machine. What seems to be the real fix is just to re-emerge mesa. After that the issue went away.
Reemerge mesa didn't help in my case. Here's the build log https://drive.google.com/file/d/1_nBnHqFu_HJ1sGz07lCF5viaevksosMG/view?usp=sharing
@0xC0ncord could you please share your mesa use flags?
I have:
media-libs/mesa-22.0.0_rc2::gentoo was built with the following:
USE="X gles2 llvm (selinux) vaapi vdpau vulkan wayland xvmc zstd -d3d9 -debug -gles1 -lm-sensors -opencl -osmesa -test -unwind -valgrind -vulkan-overlay -xa -zink" CPU_FLAGS_X86="sse2" VIDEO_CARDS="radeon radeonsi (-freedreno) -intel (-lima) -nouveau (-panfrost) -r300 -r600 (-v3d) (-vc4) -virgl (-vivante) -vmware"
@0xC0ncord very quickly, thanks! p.s. I see your VIDEO_CARDS only contain radeon and radeonsi, don't you get the following?
Running pre-merge checks for media-libs/mesa-21.3.5
- Ignoring USE=xvmc since VIDEO_CARDS does not contain r600 or nouveau
Yes, I just removed that USE flag in fact. :)
Disabling system ffmpeg seems to have bypassed the problematic code, I don't know why. But you still hit it with all system-* use flags disabled, if I remember correctly. So this is a complex issue.
Looks like the newest ebuild is failing to build for me.
I suspect this might be somehow related to #108