mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-12-07 13:45:11 -05:00
Add test for poppler build and include lcms2 dll
This commit is contained in:
parent
f138d60a40
commit
95f9cd9584
@ -42,7 +42,7 @@ def binary_includes():
|
||||
' webp webpmux webpdemux sharpyuv exslt ncursesw readline chm hunspell-1.7 hyphen'
|
||||
' icudata icui18n icuuc icuio stemmer gcrypt gpg-error uchardet graphite2 espeak-ng'
|
||||
' brotlicommon brotlidec brotlienc zstd podofo ssl crypto deflate tiff onnxruntime'
|
||||
' gobject-2.0 glib-2.0 gthread-2.0 gmodule-2.0 gio-2.0 dbus-glib-1').split()
|
||||
' gobject-2.0 glib-2.0 gthread-2.0 gmodule-2.0 gio-2.0 dbus-glib-1 lcms2').split()
|
||||
)) + [
|
||||
# debian/ubuntu for for some typical stupid reason use libpcre.so.3
|
||||
# instead of libpcre.so.0 like other distros. And Qt's idiotic build
|
||||
|
||||
@ -484,7 +484,7 @@ class Freeze:
|
||||
@flush
|
||||
def add_poppler(self):
|
||||
print('\nAdding poppler')
|
||||
for x in ('libopenjp2.7.dylib', 'libpoppler.130.dylib',):
|
||||
for x in ('libopenjp2.7.dylib', 'libpoppler.130.dylib', 'liblcms2.2.dylib',):
|
||||
self.install_dylib(join(PREFIX, 'lib', x))
|
||||
for x in ('pdftohtml', 'pdftoppm', 'pdfinfo', 'pdftotext'):
|
||||
self.install_dylib(
|
||||
|
||||
@ -24,6 +24,7 @@
|
||||
# Copy opengl32sw.dll from
|
||||
# https://download.qt.io/development_releases/prebuilt/llvmpipe/windows/
|
||||
# to C:/mesa/64
|
||||
# Install MESON and NINJA using the MSI from the meson github releases page
|
||||
|
||||
vm_name 'windows-calibre'
|
||||
root 'C:/r'
|
||||
|
||||
@ -113,6 +113,14 @@ class BuildTest(unittest.TestCase):
|
||||
from html5_parser import parse
|
||||
parse('<p>xxx')
|
||||
|
||||
def test_poppler(self):
|
||||
import subprocess
|
||||
|
||||
from calibre.ebooks.pdf.pdftohtml import PDFTOHTML, popen
|
||||
p = popen([PDFTOHTML, '--help'], stderr=subprocess.DEVNULL, stdout=subprocess.DEVNULL)
|
||||
if p.wait() != 0:
|
||||
raise RuntimeError(f'pdftohtml --help failed with return code: {p.returncode}')
|
||||
|
||||
def test_bs4(self):
|
||||
import bs4
|
||||
import soupsieve
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user