remove obsolete PyMuPDF support
PyMuPDF and above do not rely on patched mupdf sources any more, so not provide the extra exported function and revert back to vanilla sources.
This commit is contained in:
parent
bf6f961ab9
commit
2651dbfbbb
@ -1,42 +0,0 @@
|
||||
From c8e13f6b200ca086085f8318409bd324ef498852 Mon Sep 17 00:00:00 2001
|
||||
Message-Id: <c8e13f6b200ca086085f8318409bd324ef498852.1602190618.git.mjg@fedoraproject.org>
|
||||
From: Michael J Gruber <mjg@fedoraproject.org>
|
||||
Date: Thu, 8 Oct 2020 22:55:36 +0200
|
||||
Subject: [PATCH] support PyMuPDF
|
||||
|
||||
PyMuPDF patches mupdf sources to build. Support this by including the
|
||||
desired function.
|
||||
|
||||
Originally-by: Jorj X. McKie <jorj.x.mckie@outlook.de>
|
||||
---
|
||||
source/pdf/pdf-font-add.c | 17 +++++++++++++++++
|
||||
1 file changed, 17 insertions(+)
|
||||
|
||||
diff --git a/source/pdf/pdf-font-add.c b/source/pdf/pdf-font-add.c
|
||||
index f68b74c02..2ff11efe1 100644
|
||||
--- a/source/pdf/pdf-font-add.c
|
||||
+++ b/source/pdf/pdf-font-add.c
|
||||
@@ -778,3 +778,20 @@ pdf_add_cjk_font(fz_context *ctx, pdf_document *doc, fz_font *fzfont, int script
|
||||
|
||||
return fref;
|
||||
}
|
||||
+void jm_valid_chars(fz_context *ctx, fz_font *font, void *arr)
|
||||
+{
|
||||
+ FT_Face face = font->ft_face;
|
||||
+ FT_ULong ucs;
|
||||
+ FT_UInt gid;
|
||||
+ long *table = (long *)arr;
|
||||
+ fz_lock(ctx, FZ_LOCK_FREETYPE);
|
||||
+ ucs = FT_Get_First_Char(face, &gid);
|
||||
+ while (gid > 0)
|
||||
+ {
|
||||
+ if (gid < (FT_ULong)face->num_glyphs && face->num_glyphs > 0)
|
||||
+ table[gid] = (long)ucs;
|
||||
+ ucs = FT_Get_Next_Char(face, ucs, &gid);
|
||||
+ }
|
||||
+ fz_unlock(ctx, FZ_LOCK_FREETYPE);
|
||||
+ return;
|
||||
+}
|
||||
--
|
||||
2.28.0.945.gedc4c61efd
|
||||
|
@ -5,7 +5,7 @@
|
||||
|
||||
Name: mupdf
|
||||
Version: 1.18.0
|
||||
Release: 5%{?dist}
|
||||
Release: 6%{?dist}
|
||||
Summary: A lightweight PDF viewer and toolkit
|
||||
License: AGPLv3+
|
||||
URL: http://mupdf.com/
|
||||
@ -30,8 +30,7 @@ Provides: bundled(freeglut-devel) = 3.0.0
|
||||
# muPDF needs the muJS sources for the build even if we build against the system
|
||||
# version so bundling them is the safer choice.
|
||||
Provides: bundled(mujs-devel) = 1.0.9
|
||||
Patch1: 0001-support-PyMuPDF.patch
|
||||
Patch2: 0001-Bug-703366-Fix-double-free-of-object-during-lineariz.patch
|
||||
Patch1: 0001-Bug-703366-Fix-double-free-of-object-during-lineariz.patch
|
||||
|
||||
%description
|
||||
MuPDF is a lightweight PDF viewer and toolkit written in portable C.
|
||||
@ -64,7 +63,6 @@ do
|
||||
rm -rf thirdparty/$d
|
||||
done
|
||||
%patch1 -p1
|
||||
%patch2 -p1
|
||||
|
||||
echo > user.make "\
|
||||
USE_SYSTEM_FREETYPE := yes
|
||||
@ -113,6 +111,9 @@ cd %{buildroot}/%{_bindir} && ln -s %{name}-x11 %{name}
|
||||
%{_libdir}/lib%{name}*.a
|
||||
|
||||
%changelog
|
||||
* Wed Feb 24 2021 Michael J Gruber <mjg@fedoraproject.org> - 1.18.0-6
|
||||
- remove obsolete PyMuPDF support
|
||||
|
||||
* Tue Feb 23 2021 Michael J Gruber <mjg@fedoraproject.org> - 1.18.0-5
|
||||
- CVE-2021-3407 (bz #1931964, bz#1931965)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user