servo: 0.5.0 -> 0.6.0, add maintainer niklaskorz (#568688)

This commit is contained in:
nixpkgs-ci[bot]
2026-09-30 19:22:01 +00:00
committed by GitHub

View File

@@ -69,13 +69,13 @@ in
rustPlatform.buildRustPackage (finalAttrs: {
pname = "servo";
version = "0.5.0";
version = "0.6.0";
src = fetchFromGitHub {
owner = "servo";
repo = "servo";
tag = "v${finalAttrs.version}";
hash = "sha256-cJtmh/gzwno1gIqHPFgDsynGi//BvV9UyevuAbllRtg=";
hash = "sha256-inhpSzLQExTD5VT7hCzoycYMa2U4oZv8fz7NhZAlP2I=";
# Breaks reproducibility depending on whether the picked commit
# has other ref-names or not, which may change over time, i.e. with
# "ref-names: HEAD -> main" as long this commit is the branch HEAD
@@ -85,7 +85,23 @@ rustPlatform.buildRustPackage (finalAttrs: {
'';
};
cargoHash = "sha256-zZeHqxBvs5M0/TO/ifM1m5F0mSdT4cTJzoW2ja1+s28=";
cargoHash = "sha256-hjea0ze+GO3i+x1HZxSpWfXc57kvVVjmTWl2ytQYxco=";
postPatch = ''
# The mozjs crates all use cbindgen with `cargo metadata` invocations,
# which looks up the nearest cargo config.
# In our case, that's $cargoDepsCopy/.cargo/config.toml, which is the
# template of the config cargo-setup-hook creates in the build directory.
# The easiest workaround is to copy the final config back into $cargoDepsCopy,
# so `cargo metadata` invoked inside the mozjs crates finds the correct vendor path.
cp .cargo/config.toml $cargoDepsCopy/.cargo/config.toml
# We also need to make sure that `cargo metadata` knows what versions each of the
# mozjs crates' dependencies resolve to in our dependency cache, which can be achieved
# by copying our lockfile into the mozjs crate directories.
for mozjs_dir in $cargoDepsCopy/*/mozjs_*/; do
cp Cargo.lock $mozjs_dir
done
'';
# set `HOME` to a temp dir for write access
# Fix invalid option errors during linking (https://github.com/mozilla/nixpkgs-mozilla/commit/c72ff151a3e25f14182569679ed4cd22ef352328)
@@ -137,11 +153,6 @@ rustPlatform.buildRustPackage (finalAttrs: {
vulkan-loader
];
# Builds with additional features for aarch64, see https://github.com/servo/servo/issues/36819
buildFeatures = lib.optionals stdenv.hostPlatform.isAarch64 [
"servo-allocator/use-system-allocator"
];
env.NIX_CFLAGS_COMPILE = toString (
[
# mozjs-sys fails with:
@@ -176,7 +187,7 @@ rustPlatform.buildRustPackage (finalAttrs: {
homepage = "https://servo.org";
license = lib.licenses.mpl20;
maintainers = with lib.maintainers; [
hexa
niklaskorz
];
teams = with lib.teams; [ ngi ];
mainProgram = "servoshell";