wkhtmltopdf: restore support for aarch64-linux

Some production instances of odoo run on aarch64-linux,
which depends on wkhtmltopdf.

Commit 569d5e54 moved to the -bin release of wkhtmltopdf
but did not include the binary package for aarch64-linux.

This commit extends the -bin packaging to pull the "arm64"
release for aarch64-linux.

Signed-off-by: Sirio Balmelli <sirio@b-ad.ch>
This commit is contained in:
Sirio Balmelli
2024-09-04 09:20:15 +02:00
parent f1321e4e63
commit e3a09a5f14
+19 -9
View File
@@ -39,13 +39,7 @@ let
'';
};
linuxAttrs = rec {
version = "0.12.6.1-3";
src = fetchurl {
url = "https://github.com/wkhtmltopdf/packaging/releases/download/${version}/wkhtmltox_${version}.bookworm_amd64.deb";
hash = "sha256-mLoNFXtQ028jvQ3t9MCqKMewxQ/NzcVKpba7uoGjlB0=";
};
_linuxAttrs = {
nativeBuildInputs = [ dpkg autoPatchelfHook ];
buildInputs = [
@@ -79,6 +73,22 @@ let
runHook postInstall
'';
};
linuxAttrs.aarch64-linux = rec {
version = "0.12.6.1-3";
src = fetchurl {
url = "https://github.com/wkhtmltopdf/packaging/releases/download/${version}/wkhtmltox_${version}.bookworm_arm64.deb";
hash = "sha256-tmBhV7J8E+BE0Ku+ZwMB+I3k4Xgq/KT5wGpYF/PgOpw=";
};
} // _linuxAttrs;
linuxAttrs.x86_64-linux = rec {
version = "0.12.6.1-3";
src = fetchurl {
url = "https://github.com/wkhtmltopdf/packaging/releases/download/${version}/wkhtmltox_${version}.bookworm_amd64.deb";
hash = "sha256-mLoNFXtQ028jvQ3t9MCqKMewxQ/NzcVKpba7uoGjlB0=";
};
} // _linuxAttrs;
in
stdenv.mkDerivation ({
pname = "wkhtmltopdf";
@@ -105,9 +115,9 @@ stdenv.mkDerivation ({
'';
license = licenses.gpl3Plus;
maintainers = with maintainers; [ nbr kalbasit ];
platforms = [ "x86_64-darwin" "x86_64-linux" ];
platforms = [ "x86_64-darwin" "x86_64-linux" "aarch64-linux" ];
};
}
// lib.optionalAttrs (stdenv.hostPlatform.isDarwin) darwinAttrs
// lib.optionalAttrs (stdenv.hostPlatform.isLinux) linuxAttrs
// lib.optionalAttrs (stdenv.hostPlatform.isLinux) linuxAttrs.${stdenv.system}
)