chromium: changes required for electron
This commit is contained in:
parent
ea1779a2ae
commit
b006049b42
|
@ -250,14 +250,20 @@ let
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|
||||||
# Required for patchShebangs (unsupported interpreter directive, basename: invalid option -- '*', etc.):
|
if [[ -e native_client/SConstruct ]]; then
|
||||||
substituteInPlace native_client/SConstruct --replace "#! -*- python -*-" ""
|
# Required for patchShebangs (unsupported interpreter directive, basename: invalid option -- '*', etc.):
|
||||||
|
substituteInPlace native_client/SConstruct --replace "#! -*- python -*-" ""
|
||||||
|
fi
|
||||||
if [ -e third_party/harfbuzz-ng/src/src/update-unicode-tables.make ]; then
|
if [ -e third_party/harfbuzz-ng/src/src/update-unicode-tables.make ]; then
|
||||||
substituteInPlace third_party/harfbuzz-ng/src/src/update-unicode-tables.make \
|
substituteInPlace third_party/harfbuzz-ng/src/src/update-unicode-tables.make \
|
||||||
--replace "/usr/bin/env -S make -f" "/usr/bin/make -f"
|
--replace "/usr/bin/env -S make -f" "/usr/bin/make -f"
|
||||||
fi
|
fi
|
||||||
chmod -x third_party/webgpu-cts/src/tools/run_deno
|
if [ -e third_party/webgpu-cts/src/tools/run_deno ]; then
|
||||||
chmod -x third_party/dawn/third_party/webgpu-cts/tools/run_deno
|
chmod -x third_party/webgpu-cts/src/tools/run_deno
|
||||||
|
fi
|
||||||
|
if [ -e third_party/dawn/third_party/webgpu-cts/tools/run_deno ]; then
|
||||||
|
chmod -x third_party/dawn/third_party/webgpu-cts/tools/run_deno
|
||||||
|
fi
|
||||||
|
|
||||||
# We want to be able to specify where the sandbox is via CHROME_DEVEL_SANDBOX
|
# We want to be able to specify where the sandbox is via CHROME_DEVEL_SANDBOX
|
||||||
substituteInPlace sandbox/linux/suid/client/setuid_sandbox_host.cc \
|
substituteInPlace sandbox/linux/suid/client/setuid_sandbox_host.cc \
|
||||||
|
|
|
@ -6,10 +6,12 @@
|
||||||
, libva, pipewire, wayland
|
, libva, pipewire, wayland
|
||||||
, gcc, nspr, nss, runCommand
|
, gcc, nspr, nss, runCommand
|
||||||
, lib, libkrb5
|
, lib, libkrb5
|
||||||
|
, electron-source # for warnObsoleteVersionConditional
|
||||||
|
|
||||||
# package customization
|
# package customization
|
||||||
# Note: enable* flags should not require full rebuilds (i.e. only affect the wrapper)
|
# Note: enable* flags should not require full rebuilds (i.e. only affect the wrapper)
|
||||||
, channel ? "stable"
|
, channel ? "stable"
|
||||||
|
, upstream-info ? (import ./upstream-info.nix).${channel}
|
||||||
, proprietaryCodecs ? true
|
, proprietaryCodecs ? true
|
||||||
, enableWideVine ? false
|
, enableWideVine ? false
|
||||||
, ungoogled ? false # Whether to build chromium or ungoogled-chromium
|
, ungoogled ? false # Whether to build chromium or ungoogled-chromium
|
||||||
|
@ -28,14 +30,12 @@ let
|
||||||
llvmPackages_attrName = "llvmPackages_16";
|
llvmPackages_attrName = "llvmPackages_16";
|
||||||
stdenv = pkgs.${llvmPackages_attrName}.stdenv;
|
stdenv = pkgs.${llvmPackages_attrName}.stdenv;
|
||||||
|
|
||||||
upstream-info = (import ./upstream-info.nix).${channel};
|
|
||||||
|
|
||||||
# Helper functions for changes that depend on specific versions:
|
# Helper functions for changes that depend on specific versions:
|
||||||
warnObsoleteVersionConditional = min-version: result:
|
warnObsoleteVersionConditional = min-version: result:
|
||||||
let ungoogled-version = (import ./upstream-info.nix).ungoogled-chromium.version;
|
let min-supported-version = (lib.head (lib.attrValues electron-source)).unwrapped.info.chromium.version;
|
||||||
in lib.warnIf
|
in lib.warnIf
|
||||||
(lib.versionAtLeast ungoogled-version min-version)
|
(lib.versionAtLeast min-supported-version min-version)
|
||||||
"chromium: ungoogled version ${ungoogled-version} is newer than a conditional bounded at ${min-version}. You can safely delete it."
|
"chromium: min-supported-version ${min-supported-version} is newer than a conditional bounded at ${min-version}. You can safely delete it."
|
||||||
result;
|
result;
|
||||||
chromiumVersionAtLeast = min-version:
|
chromiumVersionAtLeast = min-version:
|
||||||
let result = lib.versionAtLeast upstream-info.version min-version;
|
let result = lib.versionAtLeast upstream-info.version min-version;
|
||||||
|
|
Loading…
Reference in a new issue