ladybird: 0-unstable-2026-10-14 -> 0-unstable-2026-10-24 (#578408)

This commit is contained in:
Francesco Gazzetta
2026-10-25 09:08:05 +00:00
committed by GitHub
5 changed files with 67 additions and 66 deletions

View File

@@ -2,7 +2,10 @@
{
name = "ladybird";
meta = with pkgs.lib.maintainers; {
maintainers = [ fgaz ];
maintainers = [
fgaz
schembriaiden
];
};
nodes.machine =
@@ -14,6 +17,10 @@
services.xserver.enable = true;
programs.ladybird.enable = true;
environment.systemPackages = [
pkgs.groff
pkgs.groff.perl
];
};
enableOCR = true;
@@ -28,5 +35,12 @@
machine.send_key("ctrl-tab")
machine.wait_for_text("Hello world")
machine.screenshot("screen")
# Check that the PDF.js viewer renders the document, not just its toolbar.
machine.succeed("printf '.ps 32\\n.sp 1i\\nPDF rendering works\\n' | SOURCE_DATE_EPOCH=1 groff -Tpdf > /tmp/ladybird-test.pdf")
machine.send_key("ctrl-l")
machine.send_chars("file:///tmp/ladybird-test.pdf\n")
machine.wait_for_text("PDF rendering works")
machine.screenshot("pdf")
'';
}

View File

@@ -1,19 +1,10 @@
Link LibGfx's direct CoreText calls explicitly and use Nix dependencies
instead of searching the host's Homebrew installation.
Use Nix dependencies instead of searching the host's Homebrew installation.
Defer bundle signing until postFixup, after Nix has finished modifying it.
Use rcodesign for helper and Cranelift compiler signing during the build.
Use rcodesign for helper signing during the build.
Provide a default CA bundle to both curl and the RequestServer sandbox
when no certificate file was supplied explicitly.
--- a/Libraries/LibGfx/CMakeLists.txt
+++ b/Libraries/LibGfx/CMakeLists.txt
@@ -105,4 +105,5 @@
if (APPLE)
+ target_link_libraries(LibGfx PRIVATE "-framework CoreText")
target_link_libraries(LibGfx PRIVATE "-framework Metal" "-framework Accelerate")
endif()
--- a/Meta/CMake/compile_options.cmake
+++ b/Meta/CMake/compile_options.cmake
@@ -210,7 +210,6 @@
@@ -79,14 +70,3 @@ when no certificate file was supplied explicitly.
VERBATIM
)
endfunction()
--- a/Libraries/LibWasm/CMakeLists.txt
+++ b/Libraries/LibWasm/CMakeLists.txt
@@ -50,7 +50,7 @@
set(cranelift_compiler_signed_stamp "${CMAKE_CURRENT_BINARY_DIR}/cranelift_compiler_signed.stamp")
add_custom_command(
OUTPUT "${cranelift_compiler_signed_stamp}"
- COMMAND codesign -s - -f -o runtime "${WASM_CRANELIFT_COMPILER_BINARY}"
+ COMMAND rcodesign sign --code-signature-flags runtime "${WASM_CRANELIFT_COMPILER_BINARY}"
COMMAND "${CMAKE_COMMAND}" -E touch "${cranelift_compiler_signed_stamp}"
DEPENDS "${WASM_CRANELIFT_COMPILER_BINARY}"
VERBATIM

View File

@@ -5,7 +5,6 @@
darwinMinVersionHook,
cacert,
fetchFromGitHub,
fetchzip,
pdfjs,
chromium-hsts-preload-list,
cmake,
@@ -61,35 +60,23 @@
vulkan-loader,
vulkan-memory-allocator,
zlib,
zmij,
}:
let
# The integration patch shipped by Ladybird targets this PDF.js version.
pdfjsForLadybird = pdfjs.overrideAttrs (
final: _prev: {
version = "5.6.205";
src = fetchzip {
url = "https://github.com/mozilla/pdf.js/releases/download/v${final.version}/pdfjs-${final.version}-dist.zip";
hash = "sha256-JMmxoT68PNJ/MmlMwVNYcHerorklLv5YY6C55xjn73w=";
stripRoot = false;
};
}
);
in
stdenv.mkDerivation (finalAttrs: {
pname = "ladybird";
version = "0-unstable-2026-10-14";
version = "0-unstable-2026-10-24";
src = fetchFromGitHub {
owner = "LadybirdBrowser";
repo = "ladybird";
rev = "41e923c58147fd7ff64dcbc1ea52456ddf235c3c";
hash = "sha256-LQAe+TkqdpWU0ipq3pkuEwx0fhl0RlTPG+xxEBAjTMY=";
rev = "7e15f8e935189b116dd178537849f2e1c94ed764";
hash = "sha256-xsvPE6mpbHreBvIfbmpONQywlUkE6uF6dZKzHU8M/eE=";
};
cargoDeps = rustPlatform.fetchCargoVendor {
inherit (finalAttrs) pname version src;
hash = "sha256-r4HKvfwDqcH3nuS72+PmgP9xmlG5yPvmxtGrwbTodSU=";
hash = "sha256-pPS3GJsDcvzZAEQina1v6SGPLmhtetXUX5+paTRY428=";
};
patches = [
@@ -107,7 +94,6 @@ stdenv.mkDerivation (finalAttrs: {
postPatch = ''
sed -i '/iconutil/d' UI/CMakeLists.txt
# https://github.com/LadybirdBrowser/ladybird/pull/12751
# New Rust releases can deprecate APIs used by this snapshot.
substituteInPlace Meta/CMake/rust_crate.cmake \
@@ -117,7 +103,6 @@ stdenv.mkDerivation (finalAttrs: {
# Use nixpkgs' FFmpeg, which already provides the additional decoders.
substituteInPlace Meta/CMake/check_for_dependencies.cmake \
--replace-fail libavcodec-ladybird libavcodec \
--replace-fail libavformat-ladybird libavformat \
--replace-fail libavutil-ladybird libavutil \
--replace-fail libswresample-ladybird libswresample
@@ -126,7 +111,7 @@ stdenv.mkDerivation (finalAttrs: {
Meta/CMake/check_for_dependencies.cmake
# Install the same PDF viewer assets and integration patch as the vcpkg build.
cp -r ${pdfjsForLadybird}/share/pdf.js pdfjs
cp -r ${pdfjs}/share/pdf.js pdfjs
chmod -R u+w pdfjs
patch -d pdfjs -p1 < Meta/CMake/vcpkg/overlay-ports/pdfjs/0001-ladybird-embed.patch
substituteInPlace UI/cmake/ResourceFiles.cmake \
@@ -220,27 +205,13 @@ stdenv.mkDerivation (finalAttrs: {
$out/include/skia/src/utils/mac/SkUniqueCFRef.h
'';
}))
(wuffs.overrideAttrs (prev: {
# Ladybird includes the stable 0.3 single-file library.
version = "0.3.4";
vendorHash = "sha256-CRzsGHE3K/WWPX0A3B1CvvEdADlxdIhaT5fOtaA3LPo=";
src = fetchFromGitHub {
owner = "google";
repo = "wuffs";
tag = "v0.3.4";
hash = "sha256-XiaHus+bZ4jAk2zwinzz7VzyThCNlx36Auqyw2OH5rM=";
};
postInstall =
lib.replaceStrings
[ "release/c/wuffs-unsupported-snapshot.c" "wuffs-v0.4.c" ]
[ "release/c/wuffs-v0.3.c" "wuffs-v0.3.c" ]
prev.postInstall;
}))
wuffs
woff2
icu78
simdjson
sqlite
zlib
zmij
]
++ lib.optionals stdenv.hostPlatform.isLinux [
libpulseaudio.dev

View File

@@ -18,7 +18,7 @@ let
in
buildGoModule (finalAttrs: {
pname = "wuffs";
version = "0.4.0-alpha.9";
version = "0.3.6";
outputs = [
"out"
@@ -30,10 +30,10 @@ buildGoModule (finalAttrs: {
owner = "google";
repo = "wuffs";
tag = "v" + finalAttrs.version;
hash = "sha256-XbupK4QYnPudUlO5tRWrQRncGHITzJL//Yk/E7WNxYk=";
hash = "sha256-TxvmC5eEuJhAdHh2cSVI9GJHOvFLWIOpAIJA9m4xWYQ=";
};
vendorHash = null;
vendorHash = "sha256-CRzsGHE3K/WWPX0A3B1CvvEdADlxdIhaT5fOtaA3LPo=";
nativeBuildInputs = [ makeBinaryWrapper ];
@@ -63,7 +63,7 @@ buildGoModule (finalAttrs: {
install -Dm444 -t "$lib/lib" gen/lib/c/${compiler}-dynamic/libwuffs.*
install -Dm444 release/c/wuffs-unsupported-snapshot.c "$dev/include/wuffs/wuffs-v0.4.c"
install -Dm444 release/c/wuffs-v0.3.c "$dev/include/wuffs/wuffs-v0.3.c"
install -Dm444 ${pkgconfig} "$dev/lib/pkgconfig/wuffs.pc"
'';
@@ -79,7 +79,6 @@ buildGoModule (finalAttrs: {
mit
asl20
];
maintainers = [
];
maintainers = with lib.maintainers; [ schembriaiden ];
};
})

View File

@@ -0,0 +1,37 @@
{
lib,
stdenv,
fetchFromGitHub,
cmake,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "zmij";
version = "1.2";
src = fetchFromGitHub {
owner = "vitaut";
repo = "zmij";
tag = "v${finalAttrs.version}";
hash = "sha256-2tppKuONy9IS5IzGJF+4bqAav3aaQMZjiQCMoi5WscE=";
};
strictDeps = true;
__structuredAttrs = true;
nativeBuildInputs = [ cmake ];
cmakeFlags = [
(lib.cmakeBool "BUILD_SHARED_LIBS" (!stdenv.hostPlatform.isStatic))
(lib.cmakeBool "ZMIJ_TEST" false)
(lib.cmakeBool "ZMIJ_EXAMPLE" false)
];
meta = {
description = "Fast floating-point-to-string conversion library";
homepage = "https://github.com/vitaut/zmij";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ schembriaiden ];
platforms = lib.platforms.all;
};
})