git.iko.soy/typeable/nixpkgs
on master help sign in
chromium: Fix and enable our ANGLE support

This will additionally install the following files: libEGL.so libGLESv2.so libVkICD_mock_icd.so libvk_swiftshader.so libvulkan.so libEGL.so and libGLESv2.so are required to fix our ANGLE support. The rest should help with the Vulkan support (currently an experimental feature that is disabled by default).

commit757bbdd948234710f6eabd58c80af1e7cd9bac14 authorTredwellGit <tredwell@tutanota.com> dateThu 1 Oct 2020, 23:22 (6 years ago) parentf79703e
3 files changed+1−28
pkgs/applications/networking/browsers/chromium/browser.nix+1−1 pkgs/applications/networking/browsers/chromium/common.nix−1 pkgs/applications/networking/browsers/chromium/patches/dont-use-ANGLE-by-default.patch−26
pkgs/applications/networking/browsers/chromium/browser.nix+1−1
@@ -13,7 +13,7 @@ mkChromiumDerivation (base: rec {
1313
1414 installPhase = ''
1515 mkdir -p "$libExecPath"
16− cp -v "$buildPath/"*.pak "$buildPath/"*.bin "$libExecPath/"
16+ cp -v "$buildPath/"*.so "$buildPath/"*.pak "$buildPath/"*.bin "$libExecPath/"
1717 cp -v "$buildPath/icudtl.dat" "$libExecPath/"
1818 cp -vLR "$buildPath/locales" "$buildPath/resources" "$libExecPath/"
1919 cp -v "$buildPath/chrome" "$libExecPath/$packageName"
pkgs/applications/networking/browsers/chromium/common.nix−1
@@ -152,7 +152,6 @@ let
152152 ./patches/remove-webp-include-69.patch
153153 ./patches/no-build-timestamps.patch
154154 ./patches/widevine-79.patch
155− ./patches/dont-use-ANGLE-by-default.patch
156155 # Unfortunately, chromium regularly breaks on major updates and
157156 # then needs various patches backported in order to be compiled with GCC.
158157 # Good sources for such patches and other hints:
pkgs/applications/networking/browsers/chromium/patches/dont-use-ANGLE-by-default.patchdeleted−26
@@ -1,26 +0,0 @@
1−A field trial currently enables the passthrough command decoder, which causes
2−gl_factory.cc to try kGLImplementationEGLANGLE first, which causes Chromium to fail
3−to load libGLESv2.so on NixOS. It somehow does not try kGLImplementationDesktopGL,
4−and so there is no GL support at all.
5−
6−Revert to using the validating command decoder, which prevents gl_factory.cc
7−from touching allowed_impls, allowing it to successfully use kGLImplementationDesktopGL.
8−
9−diff --git a/ui/gl/gl_utils.cc b/ui/gl/gl_utils.cc
10−index 697cbed5fe2d..8419bdb21a2f 100644
11−--- a/ui/gl/gl_utils.cc
12−+++ b/ui/gl/gl_utils.cc
13−@@ -71,9 +71,10 @@ bool UsePassthroughCommandDecoder(const base::CommandLine* command_line) {
14− } else if (switch_value == kCmdDecoderValidatingName) {
15− return false;
16− } else {
17−- // Unrecognized or missing switch, use the default.
18−- return base::FeatureList::IsEnabled(
19−- features::kDefaultPassthroughCommandDecoder);
20−+ // Ignore the field trial that enables it; disable it until
21−+ // gl_factory.cc kGLImplementationEGLANGLE issues are sorted
22−+ // out on NixOS.
23−+ return false;
24− }
25− }
26− }