python3.pkgs.weasyprint: 53.4 → 54.0
Updated hoping it fixes tests, no luck (https://github.com/Kozea/WeasyPrint/issues/1535). https://github.com/Kozea/WeasyPrint/releases/tag/v54.0b1 https://github.com/Kozea/WeasyPrint/releases/tag/v54.0
This commit is contained in:
parent
345370b21c
commit
b26451314a
@ -4,6 +4,7 @@
|
||||
, pytestCheckHook
|
||||
, brotli
|
||||
, cairosvg
|
||||
, flit-core
|
||||
, fonttools
|
||||
, pydyf
|
||||
, pyphen
|
||||
@ -26,46 +27,17 @@
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "weasyprint";
|
||||
version = "53.4";
|
||||
version = "54.0";
|
||||
disabled = !isPy3k;
|
||||
|
||||
format = "pyproject";
|
||||
|
||||
src = fetchPypi {
|
||||
inherit version;
|
||||
pname = "weasyprint";
|
||||
sha256 = "sha256-EMyxfVXHMJa98e3T7+WMuFWwfkwwfZutTryaPxP/RYA=";
|
||||
sha256 = "0aeda9a045c7881289420cac917cc57115b1243e476187338e66d593dd000853";
|
||||
};
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace pyproject.toml \
|
||||
--replace "--isort --flake8 --cov --no-cov-on-fail" ""
|
||||
'';
|
||||
|
||||
disabledTests = [
|
||||
# needs the Ahem font (fails on macOS)
|
||||
"test_font_stretch"
|
||||
];
|
||||
|
||||
checkInputs = [
|
||||
pytestCheckHook
|
||||
ghostscript
|
||||
];
|
||||
|
||||
FONTCONFIG_FILE = "${fontconfig.out}/etc/fonts/fonts.conf";
|
||||
|
||||
propagatedBuildInputs = [
|
||||
brotli
|
||||
cairosvg
|
||||
cffi
|
||||
cssselect
|
||||
fonttools
|
||||
html5lib
|
||||
lxml
|
||||
pydyf
|
||||
pyphen
|
||||
tinycss
|
||||
zopfli
|
||||
];
|
||||
|
||||
patches = [
|
||||
(substituteAll {
|
||||
src = ./library-paths.patch;
|
||||
@ -78,6 +50,47 @@ buildPythonPackage rec {
|
||||
})
|
||||
];
|
||||
|
||||
nativeBuildInputs = [
|
||||
flit-core
|
||||
];
|
||||
|
||||
propagatedBuildInputs = [
|
||||
brotli
|
||||
cairosvg
|
||||
cffi
|
||||
cssselect
|
||||
fonttools
|
||||
html5lib
|
||||
lxml
|
||||
flit-core
|
||||
pydyf
|
||||
pyphen
|
||||
tinycss
|
||||
zopfli
|
||||
];
|
||||
|
||||
checkInputs = [
|
||||
pytestCheckHook
|
||||
ghostscript
|
||||
];
|
||||
|
||||
disabledTests = [
|
||||
# needs the Ahem font (fails on macOS)
|
||||
"test_font_stretch"
|
||||
];
|
||||
|
||||
FONTCONFIG_FILE = "${fontconfig.out}/etc/fonts/fonts.conf";
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace pyproject.toml \
|
||||
--replace "--isort --flake8 --cov --no-cov-on-fail" ""
|
||||
'';
|
||||
|
||||
preCheck = ''
|
||||
# Fontconfig wants to create a cache.
|
||||
export HOME=$TMPDIR
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://weasyprint.org/";
|
||||
description = "Converts web documents to PDF";
|
||||
|
@ -2,25 +2,26 @@ diff --git a/weasyprint/text/ffi.py b/weasyprint/text/ffi.py
|
||||
index 0734cbea..22e31a5e 100644
|
||||
--- a/weasyprint/text/ffi.py
|
||||
+++ b/weasyprint/text/ffi.py
|
||||
@@ -387,21 +387,11 @@ def _dlopen(ffi, *names):
|
||||
@@ -387,22 +387,11 @@ def _dlopen(ffi, *names):
|
||||
return ffi.dlopen(names[0]) # pragma: no cover
|
||||
|
||||
|
||||
-gobject = _dlopen(
|
||||
- ffi, 'gobject-2.0-0', 'gobject-2.0', 'libgobject-2.0-0',
|
||||
- 'libgobject-2.0.so.0', 'libgobject-2.0.dylib')
|
||||
- 'libgobject-2.0.so.0', 'libgobject-2.0.dylib', 'libgobject-2.0-0.dll')
|
||||
-pango = _dlopen(
|
||||
- ffi, 'pango-1.0-0', 'pango-1.0', 'libpango-1.0-0', 'libpango-1.0.so.0',
|
||||
- 'libpango-1.0.dylib')
|
||||
- 'libpango-1.0.dylib', 'libpango-1.0-0.dll')
|
||||
-harfbuzz = _dlopen(
|
||||
- ffi, 'harfbuzz', 'harfbuzz-0.0', 'libharfbuzz-0',
|
||||
- 'libharfbuzz.so.0', 'libharfbuzz.so.0', 'libharfbuzz.0.dylib')
|
||||
- 'libharfbuzz.so.0', 'libharfbuzz.so.0', 'libharfbuzz.0.dylib',
|
||||
- 'libharfbuzz-0.dll')
|
||||
-fontconfig = _dlopen(
|
||||
- ffi, 'fontconfig-1', 'fontconfig', 'libfontconfig', 'libfontconfig-1.dll',
|
||||
- 'libfontconfig.so.1', 'libfontconfig-1.dylib')
|
||||
- ffi, 'fontconfig-1', 'fontconfig', 'libfontconfig', 'libfontconfig.so.1',
|
||||
- 'libfontconfig-1.dylib', 'libfontconfig-1.dll')
|
||||
-pangoft2 = _dlopen(
|
||||
- ffi, 'pangoft2-1.0-0', 'pangoft2-1.0', 'libpangoft2-1.0-0',
|
||||
- 'libpangoft2-1.0.so.0', 'libpangoft2-1.0.dylib')
|
||||
- 'libpangoft2-1.0.so.0', 'libpangoft2-1.0.dylib', 'libpangoft2-1.0-0.dll')
|
||||
+gobject = _dlopen(ffi, '@gobject@')
|
||||
+pango = _dlopen(ffi, '@pango@')
|
||||
+harfbuzz = _dlopen(ffi, '@harfbuzz@')
|
||||
|
Loading…
Reference in New Issue
Block a user