New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chromium: Add option to enable ozone (for Wayland) #82919
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome, I cannot believe that this useOzone
flag was still missing :o
I found a few minor things that we can probably still improve, but overall it LGTM, thanks :)
cc @colemickens maybe you could have a look as well so that we don't miss anything (since you already provide Wayland builds https://github.com/colemickens/nixpkgs-chromium)? |
I had to add libglvnd to the wrapper to get it to start, but that was a long time ago, maybe things around GL init have changed? Otherwise it looks more complete than my attempt (which relies on @volth's chromium-git and even then I haven't properly rebased it since volth pushed their branch most recently). https://github.com/colemickens/nixpkgs-chromium/blob/master/pkgs/chromium-git/default.nix#L216 |
a0614c1
to
00bba2e
Compare
The build seems to be failing now as it is unable to find several GBM definitions, including GBM_BO_USE_TEXTURING. It looks like mesa includes a very old version of gbm that doesn't have these options. If I don't use the system gbm Chrome will not start as it is unable to find libgbm.so (which should be in mesa) |
@artemist thanks for the update and sorry about the additional circumstances :o I think the best solution would be to add At least for
In that case it should theoretically work if we add Update: I just found this blog post which suggests that the GBM backend works on GNU/Linux but it also seems to confirm that we're probably better of with |
'' + optionalString useOzone '' | ||
#substituteInPlace third_party/wayland/features.gni \ | ||
# --replace 'system_wayland_scanner_path = "/usr/bin/wayland-scanner"' \ | ||
# 'system_wayland_scanner_path = "${wayland}/bin/wayland-scanner"' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
And please don't forget to remove this, if system_wayland_scanner_path = "${wayland}/bin/wayland-scanner";
works as expected - thanks :)
66a27a2
to
3a8e024
Compare
3a8e024
to
b3e1a1b
Compare
oops, I had to do a little rebasing, but everything builds successfully with useOzone = true |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome, thanks again :)
Motivation for this change
Chromium includes support for Wayland through the Ozone interface, but this is not enabled by default. Using Wayland allows enchanced HiDPI support, especially with monitors of disparate DPIs
Things done
Add a
useOzone
option to chromium packages. This does not change the derevation of chromium whenuseOzone
is set to false, the default.sandbox
innix.conf
on non-NixOS linux)nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
./result/bin/
)nix path-info -S
before and after)