anchor.diff:        sed -i -e '/libpci_loader.*Load/s!"\(libpci\.so\)!"${pciutils}/lib/\1!' \
           gpu/config/gpu_info_collector_linux.cc
   
  -      sed -i -re 's/([^:])\<(isnan *\()/\1std::\2/g' \
  -        chrome/browser/ui/webui/engagement/site_engagement_ui.cc
  -
  -      sed -i -e '/#include/ {
  -        i #include <algorithm>
  -        :l; n; bl
  -      }' gpu/config/gpu_control_list.cc
  -
         # Allow to put extensions into the system-path.
         sed -i -e 's,/usr,/run/current-system/sw,' chrome/common/chrome_paths.cc
   
         patchShebangs .
         # use our own nodejs
         mkdir -p third_party/node/linux/node-linux-x64/bin
  -      ln -s $(which node) third_party/node/linux/node-linux-x64/bin/node
  -
  -      # remove unused third-party
  -      # in third_party/crashpad third_party/zlib contains just a header-adapter
  -      for lib in ${toString gnSystemLibraries}; do
  -        find -type f -path "*third_party/$lib/*"     \
  -            \! -path "*third_party/crashpad/crashpad/third_party/zlib/*"  \
  -            \! -path "*third_party/$lib/chromium/*"  \
  -            \! -path "*third_party/$lib/google/*"    \
  -            \! -path "*base/third_party/icu/*"       \
  -            \! -path "*base/third_party/libevent/*"  \
  -            \! -regex '.*\.\(gn\|gni\|isolate\|py\)' \
  -            -delete
  -      done
  +      ln -s "$(command -v node)" third_party/node/linux/node-linux-x64/bin/node
  +
  +      # Allow building against system libraries in official builds
  +      sed -i 's/OFFICIAL_BUILD/GOOGLE_CHROME_BUILD/' tools/generate_shim_headers/generate_shim_headers.py
  +
       '' + optionalString stdenv.isAarch64 ''
         substituteInPlace build/toolchain/linux/BUILD.gn \
           --replace 'toolprefix = "aarch64-linux-gnu-"' 'toolprefix = ""'
  -    '' + optionalString stdenv.cc.isClang ''
  -      mkdir -p third_party/llvm-build/Release+Asserts/bin
  -      ln -s ${stdenv.cc}/bin/clang              third_party/llvm-build/Release+Asserts/bin/clang
  -      ln -s ${stdenv.cc}/bin/clang++            third_party/llvm-build/Release+Asserts/bin/clang++
  -      ln -s ${llvmPackages.llvm}/bin/llvm-ar    third_party/llvm-build/Release+Asserts/bin/llvm-ar
       '';
   
       gnFlags = mkGnFlags ({
  -      use_lld = false;
  -      use_gold = stdenv.buildPlatform.is64bit;  # ld.gold outs-of-memory on i686
  -      gold_path = "${stdenv.cc}/bin";
  +      custom_toolchain = "//build/toolchain/linux/unbundle:default";
  +      host_toolchain = "//build/toolchain/linux/unbundle:default";
  +      is_official_build = true;
         is_debug = false;
   
         proprietary_codecs = false;
  
positive.code: 
  with stdenv.lib;
  
  # see http://www.linuxfromscratch.org/blfs/view/cvs/xsoft/chromium.html
  
  let
    jre = jre8; # TODO: remove override https://github.com/NixOS/nixpkgs/pull/89731
  
  
negative.code:     };
  
      nativeBuildInputs = [
        llvmPackages.lldClang.bintools
        ninja which python2Packages.python perl pkgconfig
        python2Packages.ply python2Packages.jinja2 nodejs
        gnutar python2Packages.setuptools
  