From 27470e1676e69455acf06ae25ebd42ebd5bdecdb Mon Sep 17 00:00:00 2001 From: Hiroki Sato Date: Sat, 22 Aug 2015 17:48:35 +0000 Subject: - Split ghostscript into X11-independent and -dependent parts: * print/ghostscript{7,8,9,9-agpl}-base Installs Ghostscript binary, libgs, and related files. These ports do not depend on X11 libraries (i.e. x11* devices are not available). USES=ghostscript will set dependency on one of them depending on GHOSTSCRIPT_DEFAULT. The default device is set to "display" or "bbox". * print/ghostscript{7,8,9,9-agpl}-x11 Installs a shared library which provides X11 support to the installed Ghostscript binaries. x11* devices will be enabled when the library is available. This depends on *-base (RUN_DEPENDS). USES=ghostscript:x11 will set dependency on one of them. - Fix integer overflow reported as CVE-2015-3228. - Update Uses/ghostscript.mk: * Add x11 keyword. nox11 keyword is now obsolete. * Use packagename in *_DEPENDS line to prevent relationship between -base and -x11 packages from being broken. - Fix x11/nox11 keyword and bump PORTREVISION in ports using USES=ghostscript to update dependency of pre-compiled packages. --- print/ghostscript7/files/patch-src:gdevpdff.c | 59 --------------------------- 1 file changed, 59 deletions(-) delete mode 100644 print/ghostscript7/files/patch-src:gdevpdff.c (limited to 'print/ghostscript7/files/patch-src:gdevpdff.c') diff --git a/print/ghostscript7/files/patch-src:gdevpdff.c b/print/ghostscript7/files/patch-src:gdevpdff.c deleted file mode 100644 index 8a292bd4cdec..000000000000 --- a/print/ghostscript7/files/patch-src:gdevpdff.c +++ /dev/null @@ -1,59 +0,0 @@ ---- src/gdevpdff.c.org 2003-01-17 09:49:02.000000000 +0900 -+++ src/gdevpdff.c 2003-09-21 05:08:36.000000000 +0900 -@@ -276,6 +276,11 @@ - const byte *chars = font->font_name.chars; - uint size = font->font_name.size; - -+ /* CIDFonts has null string in font_name, key_name is used */ -+ if (0 == size) { -+ chars = font->key_name.chars; -+ size = font->key_name.size; -+ } - /* - * The behavior of Acrobat Distiller changed between 3.0 (PDF 1.2), - * which will never embed the base 14 fonts, and 4.0 (PDF 1.3), which -@@ -720,19 +725,22 @@ - same &= ~FONT_SAME_METRICS; - break; - case FONT_EMBED_NO: -- /* -- * Per the PDF 1.3 documentation, there are only 3 BaseEncoding -- * values allowed for non-embedded fonts. Pick one here. -- */ -- BaseEncoding = -- ((const gs_font_base *)base_font)->nearest_encoding_index; -- switch (BaseEncoding) { -- default: -- BaseEncoding = ENCODING_INDEX_WINANSI; -- case ENCODING_INDEX_WINANSI: -- case ENCODING_INDEX_MACROMAN: -- case ENCODING_INDEX_MACEXPERT: -- break; -+ if (!(font->FontType == ft_CID_encrypted || -+ font->FontType == ft_CID_TrueType)) { -+ /* -+ * Per the PDF 1.3 documentation, there are only 3 BaseEncoding -+ * values allowed for non-embedded fonts. Pick one here. -+ */ -+ BaseEncoding = -+ ((const gs_font_base *)base_font)->nearest_encoding_index; -+ switch (BaseEncoding) { -+ default: -+ BaseEncoding = ENCODING_INDEX_WINANSI; -+ case ENCODING_INDEX_WINANSI: -+ case ENCODING_INDEX_MACROMAN: -+ case ENCODING_INDEX_MACEXPERT: -+ break; -+ } - } - code = pdf_compute_font_descriptor(pdev, &fdesc, font, NULL); - if (code < 0) -@@ -888,6 +896,7 @@ - memcpy(ppf->widths_known, ftemp_widths_known, - sizeof(ftemp_widths_known)); - } -+ ppf->embed = embed; - code = pdf_register_font(pdev, font, ppf); - - *pppf = ppf; - -- cgit v1.2.3