fixup texlive-base-20210325-poppler-22.08.0.patch (bz2121167)
This commit is contained in:
parent
34082adda9
commit
1c7ecd2c33
|
@ -9,45 +9,6 @@
|
||||||
;
|
;
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
--- texlive-base-20210325/source/texk/web2c/pdftexdir/pdftoepdf.cc
|
|
||||||
+++ texlive-base-20210325/source/texk/web2c/pdftexdir/pdftoepdf.cc
|
|
||||||
@@ -167,8 +167,8 @@ static PdfDocument *find_add_document(ch
|
|
||||||
p->file_name = xstrdup(file_name);
|
|
||||||
p->xref = xref = 0;
|
|
||||||
p->occurences = 0;
|
|
||||||
- GString *docName = new GString(p->file_name);
|
|
||||||
- p->doc = new PDFDoc(docName); // takes ownership of docName
|
|
||||||
+ std::unique_ptr<GString> docName = std::make_unique<GString>(p->file_name);
|
|
||||||
+ p->doc = new PDFDoc(std::move(docName)); // takes ownership of docName
|
|
||||||
if (!p->doc->isOk() || !p->doc->okToPrint()) {
|
|
||||||
pdftex_fail("xpdf: reading PDF image failed");
|
|
||||||
}
|
|
||||||
@@ -395,7 +395,7 @@ static void copyFont(const char *tag, Ob
|
|
||||||
{
|
|
||||||
Object fontdict, subtype, basefont, fontdescRef, fontdesc, charset,
|
|
||||||
stemV;
|
|
||||||
- GfxFont *gfont;
|
|
||||||
+ std::shared_ptr<GfxFont> gfont;
|
|
||||||
fd_entry *fd;
|
|
||||||
fm_entry *fontmap;
|
|
||||||
// Check whether the font has already been embedded before analysing it.
|
|
||||||
@@ -444,7 +444,7 @@ static void copyFont(const char *tag, Ob
|
|
||||||
gfont = GfxFont::makeFont(xref, tag, fontRef->getRef(),
|
|
||||||
fontdict.getDict());
|
|
||||||
pdf_printf(" %d 0 R ", addFont(fontRef->getRef(), fd,
|
|
||||||
- addEncoding(gfont)));
|
|
||||||
+ addEncoding(gfont.get())));
|
|
||||||
} else {
|
|
||||||
copyName(tag);
|
|
||||||
pdf_puts(" ");
|
|
||||||
@@ -682,7 +682,6 @@ static void writeEncodings()
|
|
||||||
}
|
|
||||||
for (r = encodingList; r != 0; r = n) {
|
|
||||||
n = r->next;
|
|
||||||
- r->font->decRefCnt();
|
|
||||||
delete r;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
--- texlive-base-20210325/source/texk/web2c/pdftexdir/pdftosrc.cc
|
--- texlive-base-20210325/source/texk/web2c/pdftexdir/pdftosrc.cc
|
||||||
+++ texlive-base-20210325/source/texk/web2c/pdftexdir/pdftosrc.cc
|
+++ texlive-base-20210325/source/texk/web2c/pdftexdir/pdftosrc.cc
|
||||||
@@ -72,7 +72,7 @@ int main(int argc, char *argv[])
|
@@ -72,7 +72,7 @@ int main(int argc, char *argv[])
|
||||||
|
@ -89,3 +50,72 @@
|
||||||
if ((p = strrchr(buf, '.')) == 0)
|
if ((p = strrchr(buf, '.')) == 0)
|
||||||
p = strchr(buf, 0);
|
p = strchr(buf, 0);
|
||||||
sprintf(p, ".xref");
|
sprintf(p, ".xref");
|
||||||
|
diff -up texlive-base-20210325/source/texk/web2c/pdftexdir/pdftoepdf.cc.spot texlive-base-20210325/source/texk/web2c/pdftexdir/pdftoepdf.cc
|
||||||
|
--- texlive-base-20210325/source/texk/web2c/pdftexdir/pdftoepdf.cc.spot 2022-08-24 21:21:36.558035301 +0000
|
||||||
|
+++ texlive-base-20210325/source/texk/web2c/pdftexdir/pdftoepdf.cc 2022-08-24 21:41:04.409172692 +0000
|
||||||
|
@@ -123,7 +123,7 @@ struct InObj {
|
||||||
|
|
||||||
|
struct UsedEncoding {
|
||||||
|
int enc_objnum;
|
||||||
|
- GfxFont *font;
|
||||||
|
+ std::shared_ptr<GfxFont> font;
|
||||||
|
UsedEncoding *next;
|
||||||
|
};
|
||||||
|
|
||||||
|
@@ -167,8 +167,8 @@ static PdfDocument *find_add_document(ch
|
||||||
|
p->file_name = xstrdup(file_name);
|
||||||
|
p->xref = xref = 0;
|
||||||
|
p->occurences = 0;
|
||||||
|
- GString *docName = new GString(p->file_name);
|
||||||
|
- p->doc = new PDFDoc(docName); // takes ownership of docName
|
||||||
|
+ // GString *docName = new GString(p->file_name);
|
||||||
|
+ p->doc = new PDFDoc(std::make_unique<GooString>(p->file_name)); // takes ownership of docName
|
||||||
|
if (!p->doc->isOk() || !p->doc->okToPrint()) {
|
||||||
|
pdftex_fail("xpdf: reading PDF image failed");
|
||||||
|
}
|
||||||
|
@@ -204,7 +204,7 @@ static void delete_document(PdfDocument
|
||||||
|
|
||||||
|
// --------------------------------------------------------------------
|
||||||
|
|
||||||
|
-static int addEncoding(GfxFont * gfont)
|
||||||
|
+static int addEncoding(std::shared_ptr<GfxFont> gfont)
|
||||||
|
{
|
||||||
|
UsedEncoding *n;
|
||||||
|
n = new UsedEncoding;
|
||||||
|
@@ -395,7 +395,8 @@ static void copyFont(const char *tag, Ob
|
||||||
|
{
|
||||||
|
Object fontdict, subtype, basefont, fontdescRef, fontdesc, charset,
|
||||||
|
stemV;
|
||||||
|
- GfxFont *gfont;
|
||||||
|
+ // GfxFont *gfont;
|
||||||
|
+ std::shared_ptr<GfxFont> gfont;
|
||||||
|
fd_entry *fd;
|
||||||
|
fm_entry *fontmap;
|
||||||
|
// Check whether the font has already been embedded before analysing it.
|
||||||
|
@@ -666,6 +667,7 @@ static void writeEncodings()
|
||||||
|
UsedEncoding *r, *n;
|
||||||
|
char *glyphNames[256], *s;
|
||||||
|
int i;
|
||||||
|
+
|
||||||
|
for (r = encodingList; r != 0; r = r->next) {
|
||||||
|
for (i = 0; i < 256; i++) {
|
||||||
|
if (r->font->isCIDFont()) {
|
||||||
|
@@ -673,7 +675,8 @@ static void writeEncodings()
|
||||||
|
("PDF inclusion: CID fonts are not supported"
|
||||||
|
" (try to disable font replacement to fix this)");
|
||||||
|
}
|
||||||
|
- if ((s = (char *) ((Gfx8BitFont *) r->font)->getCharName(i)) != 0)
|
||||||
|
+ const GfxFont *const font = r->font.get();
|
||||||
|
+ if ((s = (char *) ((Gfx8BitFont *) font)->getCharName(i)) != 0)
|
||||||
|
glyphNames[i] = s;
|
||||||
|
else
|
||||||
|
glyphNames[i] = notdef;
|
||||||
|
@@ -682,7 +685,7 @@ static void writeEncodings()
|
||||||
|
}
|
||||||
|
for (r = encodingList; r != 0; r = n) {
|
||||||
|
n = r->next;
|
||||||
|
- r->font->decRefCnt();
|
||||||
|
+ // r->font->decRefCnt();
|
||||||
|
delete r;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
|
@ -20,7 +20,7 @@
|
||||||
|
|
||||||
Name: %{shortname}-base
|
Name: %{shortname}-base
|
||||||
Version: %{source_date}
|
Version: %{source_date}
|
||||||
Release: 51%{?dist}
|
Release: 52%{?dist}
|
||||||
Epoch: 9
|
Epoch: 9
|
||||||
Summary: TeX formatting system
|
Summary: TeX formatting system
|
||||||
# The only files in the base package are directories, cache, and license texts
|
# The only files in the base package are directories, cache, and license texts
|
||||||
|
@ -9413,6 +9413,9 @@ yes | %{_bindir}/updmap-sys --quiet --syncwithtrees >/dev/null 2>&1 || :
|
||||||
%doc %{_texdir}/texmf-dist/doc/latex/yplan/
|
%doc %{_texdir}/texmf-dist/doc/latex/yplan/
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Wed Aug 24 2022 Tom Callaway <spot@fedoraproject.org> - 9:202110325-52
|
||||||
|
- fixup texlive-base-20210325-poppler-22.08.0.patch (bz2121167)
|
||||||
|
|
||||||
* Mon Aug 08 2022 Marek Kasik <mkasik@redhat.com> - 9:20210325-51
|
* Mon Aug 08 2022 Marek Kasik <mkasik@redhat.com> - 9:20210325-51
|
||||||
- Bootstrap off
|
- Bootstrap off
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue