Skip to content

Commit 062eb42

Browse files
committed
chromium: prepare for M134
1 parent 5a441b7 commit 062eb42

File tree

3 files changed

+33
-3
lines changed

3 files changed

+33
-3
lines changed

pkgs/applications/networking/browsers/chromium/common.nix

Lines changed: 19 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -216,6 +216,7 @@ let
216216

217217
isElectron = packageName == "electron";
218218
needsCompgen = chromiumVersionAtLeast "133";
219+
rustcVersion = buildPackages.rustc.version;
219220

220221
chromiumDeps = lib.mapAttrs (
221222
path: args:
@@ -522,6 +523,9 @@ let
522523
revert = true;
523524
hash = "sha256-PuinMLhJ2W4KPXI5K0ujw85ENTB1wG7Hv785SZ55xnY=";
524525
})
526+
]
527+
++ lib.optionals (chromiumVersionAtLeast "134" && lib.versionOlder rustcVersion "1.86") [
528+
./patches/chromium-134-rust-adler2.patch
525529
];
526530

527531
postPatch =
@@ -726,7 +730,20 @@ let
726730
# Disable PGO because the profile data requires a newer compiler version (LLVM 14 isn't sufficient):
727731
chrome_pgo_phase = 0;
728732
clang_base_path = "${llvmCcAndBintools}";
729-
use_qt = false;
733+
}
734+
// (
735+
# M134 changed use_qt to use_qt5 (and use_qt6)
736+
if chromiumVersionAtLeast "134" then
737+
{
738+
use_qt5 = false;
739+
use_qt6 = false;
740+
}
741+
else
742+
{
743+
use_qt = false;
744+
}
745+
)
746+
// {
730747
# To fix the build as we don't provide libffi_pic.a
731748
# (ld.lld: error: unable to find library -l:libffi_pic.a):
732749
use_system_libffi = true;
@@ -738,7 +755,7 @@ let
738755
enable_rust = true;
739756
# While we technically don't need the cache-invalidation rustc_version provides, rustc_version
740757
# is still used in some scripts (e.g. build/rust/std/find_std_rlibs.py).
741-
rustc_version = buildPackages.rustc.version;
758+
rustc_version = rustcVersion;
742759
}
743760
// lib.optionalAttrs (!(stdenv.buildPlatform.canExecute stdenv.hostPlatform)) {
744761
# https://www.mail-archive.com/[email protected]/msg14528.html

pkgs/applications/networking/browsers/chromium/depot_tools.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ def repo_from_dep(dep: dict) -> Optional[Repo]:
114114
},
115115
**{
116116
f"checkout_{arch}": True
117-
for arch in ["x64", "arm64", "arm", "x86", "mips", "mips64"]
117+
for arch in ["x64", "arm64", "arm", "x86", "mips", "mips64", "ppc"]
118118
},
119119
},
120120
"",
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
diff --git a/build/rust/std/BUILD.gn b/build/rust/std/BUILD.gn
2+
index 6b996aa1fe3865187d02c017e56c0918bcc9b8f4..68b085be200fa4f116aa709b9157c4d2efdf7d6a 100644
3+
--- a/build/rust/std/BUILD.gn
4+
+++ b/build/rust/std/BUILD.gn
5+
@@ -89,7 +89,7 @@ if (toolchain_has_rust) {
6+
# These are no longer present in the Windows toolchain.
7+
stdlib_files += [
8+
"addr2line",
9+
- "adler2",
10+
+ "adler",
11+
"gimli",
12+
"libc",
13+
"memchr",

0 commit comments

Comments
 (0)