diff options
author | tron <tron@pkgsrc.org> | 2014-08-01 12:31:27 +0000 |
---|---|---|
committer | tron <tron@pkgsrc.org> | 2014-08-01 12:31:27 +0000 |
commit | a206b0fab1b4b0992c9acc7b65c6e3985795a178 (patch) | |
tree | c75479f943e1f36607198912e830c0fc9ca5ef71 /print | |
parent | 7706d777e1965537f0176f886b7647d3a4614994 (diff) | |
download | pkgsrc-a206b0fab1b4b0992c9acc7b65c6e3985795a178.tar.gz |
Update "xpdf" package to version 3.04. Changes since version 3.03:
- New text extractor.
- Added the pdftohtml tool.
- Added the pdftopng tool.
- New trapezoid-based rasterizer core (for performance).
- Generate appearance streams for Line, PolyLine, and Polygon
annotations.
- Added the closeWindowOrQuit command, and changed the default binding
for ctrl-W from closeWindow to closeWindowOrQuit.
- Implemented the new AES-256 mode (R=6, Acrobat X).
- Add an object cache.
- Added a small cache for object streams.
- Modify PSOutputDev to use LZW compression instead of RLE, with a
fallback to RLE if the "psLZW no" setting is given.
- Pdfinfo now prints page rotation info.
- Modified ImageOutputDev, used by pdfimages, to output the masks and
soft masks used when drawing images.
- Remove non-printable characters from error output, just in case they
might cause problems for the terminal program.
- Added initial support for Code3of9 bar codes in XFA forms.
- Added the mapExtTrueTypeFontsViaUnicode xpdfrc command.
- Apply stroke adjustment to rectangular images and clipping regions (in
addition to strokes and fills).
- Decode JPEG 2000 images at less than full resolution if the full res
image isn't needed (i.e., if the raw image is higher resolution than
the output).
- Implemented knockout groups.
- Removed t1lib support.
- Added support for images with 16-bit components.
- Rewrote the Dict class to use a hash table; as a side effect, this
handles dictionaries with multiple definitions for a key, which are
in violation of the spec, but Acrobat appears to handle.
- The transformed line width computation -- used to implement the
minLineWidth setting, and the hairline threshold in monochrome mode --
was incorrect.
- Pdftops was not correctly handling the case where it couldn't find
a 16-bit font -- this led to crashes and/or invalid PostScript.
- A bug in FlateStream::getBlock() was causing problems with narrow
images.
- Use the correct _WIN32 define instead of WIN32.
- Use copy-on-write for the clip path in SplashState (when doing gsave),
for performance.
- Added a Solaris-specific entry to the ghostscript font search path.
- SplashState was initializing line width to 0 instead of 1.
- Abort processing on a content stream after getting 500 errors
(undefined operator, wrong number of args) -- this avoids very long
processing time for malicious PDF files using bogus RLE encoded
content streams.
- Added the psUseCropBoxAsPage xpdfrc option; "pdftops -pagecrop" now
sets psUseCropBoxAsPage; "pdftops -pagecrop -paper match" now uses
the CropBox as the page size.
- Re-architected the AcroForm support code into a separate AcroForm
module.
- Fixed the handling of overprinting/transparency interaction, using
the CompatibleOverprint blend mode.
- The TIFF predictor code for the 1-bit-per-pixel case was broken.
- For triangle and patch mesh shadings (types 4-7) with color functions,
interpolate the function parameter not the color.
- Check the fontFile/fontDir commands before (instead of after) doing
Base-14 substitution in PS output.
- Correctly handle non-embedded TrueType fonts that have an Identity
ToUnicode mapping (display and PS output were failing).
- Added support for XFA form rendering, including an "enableXFA" xpdfrc
setting.
- Handle PFB Type 1 fonts when generating PostScript output.
- Unwind any extraneous saved graphics state at the end of the page
(before drawing annotations).
- Added some integer overflow checks in the GString class.
- Handle 16-bit components in JPEG 2000 images.
- ActualText spans can end without a valid font, in which case
TextPage::beginWord was crashing.
- The Domain entry in function shadings wasn't being parsed correctly.
- Fixed a bug in the JPEG decoder - successive approximation
(progressive mode) coefficients weren't being handled correctly.
- Added a better infinite loop test to the xref parser.
- When generating PostScript, merge reused TrueType fonts (if their
code-to-GID mappings are the same).
- Tweak the Gouraud triangle shaded fill code to end the recursive
splitting if the triangles get sufficiently small.
- Do bilinear interpolation when upsampling images.
- When skipping extraneous image data from an inline image, look for
EI<whitespace> instead of just EI.
- When writing to stdout on Windows, pdftoppm now sets the file mode to
binary. [Thanks to Robert Frunzke.]
- Accept strings as well as names for the BaseFont entry in font
objects.
- Removed the TEXTOUT_WORD_LIST config option (with the new text
extractor, this is always enabled).
- Fixed a bug in the JBIG2 decoder (the TPGD context for template #3 in
readGenericBitmap was incorrect).
- Rewrote the PostScriptFunction code for performance.
- Handle 8-bit OpenType CFF fonts that are missing required tables in
the OpenType wrapper.
- Handle tiling patterns with reversed coordinates in their bounding
boxes.
- Added support for 64-bit file offsets, i.e., PDF files larger than
2GB.
- Optimize the code that rasterizes pattern-filled image masks.
- Added support for Mac OS X system fonts (Base-14 only).
- The backdrop color in luminosity-type soft mask groups was not being
handled correctly.
- Modified behavior of "pdftops -paper match -duplex ..." - it will now
duplex consecutive same-sized pages.
- Tweak the handling of degenerate fills ('moveto lineto fill') to
match Adobe.
- Don't honor the OPM=1 setting with ICCBased CMYK color spaces.
- Whole-word searches were treating certain punctuation (Unicode number
separators and terminators) as part of the word, e.g., searching for
"foo" would not match "foo,".
- Use the TextString class everywhere it makes sense.
- Removed the unnecessary segment sort in Splash (performance
optimization).
- Handle hyperlinks that use Widget-type annotations.
- Fix up the integer overflow checks to avoid issues with clever
compilers. [Thanks to Nickolai Zeldovich.]
- Correctly handle streams with missing Length entries in damaged PDF
files.
- Added a compile-time option (LOAD_FONTS_FROM_MEM) to load fonts from
memory rather than temporary files on disk.
- Added the psRasterSliceSize xpdfrc option.
- Fixed a case in the JPEG 2000 arithmetic decoder where extra data is
present in packet i, and needs to be saved for use in packet i+1.
- Fixed a bug in the JPEG 2000 decoder related to images with fewer than
8 bits per component.
- Handle the case in PSOutputDev where slice size overflows a 32-bit
integer.
- Add (partial) support for TrueType cmap format 2.
- Always pass FT_LOAD_NO_BITMAP to FreeType -- bitmaps apparently fail
with rotated characters.
- Support fonts specified in ExtGState dictionaries.
- Annotations with empty Border arrays should not draw a border.
- Fix the CMap parser to handle large CID ranges.
- Check for Type 3 CharProcs that call q or Q before the d0/d1 operator,
and treat them as uncacheable.
- Invert the selection color when starting in reverse video mode.
- Device{Gray,RGB,CMYK} cannot be mapped via a resource dict.
- Changed the PS output for masked images (explicit and color key
masking): use a plain old clip path instead of rectclip to avoid
array overflows.
- Check the StemSnapH/V arrays when converting Type 1C fonts to Type 1 -
if there are any duplicate or out-of-order values, skip that
StemSnapH/V array.
- Added the psMinLineWidth xpdfrc setting.
- Fix an obscure issue in converting TrueType fonts to Type 42, related
to empty glyph descriptions (12 zero bytes).
- Pdftops now reports an error if there were any I/O errors writing to
the PS output file.
- Fix vertical text (CJK fonts) in PS output -- offset the character
origin correctly.
- Increased the number of digits used by pdfimages for the image number
from three to four.
- Handle right-to-left (e.g., Arabic) ligatures correctly in the text
extractor.
- Added the -loc and -locPS options to pdffonts.
- Extend the object parser recursion limit to cover Stream::addFilters()
/ Stream::makeFilters() - to avoid another possibility of stack
overflow.
- Disable FreeType autohinting, because it can fail badly with font
subsets that use invalid glyph names -- except in the case of Type 1
fonts, which look much better with light autohinting.
- Modified the rasterizer pipeline functions to process a scan line at a
time (for performance).
- Removed VMS build support (it hasn't been updated in ages).
- Removed pdftotext's '-htmlmeta' option (use pdftohtml instead).
- PSOutputDev's font/form setup code, and pdffonts, were not scanning
soft mask groups in ExtGState dictionaries.
- Invalid DCT input (e.g., from a damaged PDF file) could overflow the
dctClip array.
- When upsampling an image mask or image with a large resulting image
size, do it in stream mode instead of prescaling the whole image
(to avoid running out of memory).
- Added infinite loop detection to pdffonts.
Diffstat (limited to 'print')
-rw-r--r-- | print/xpdf/Makefile | 9 | ||||
-rw-r--r-- | print/xpdf/distinfo | 14 | ||||
-rw-r--r-- | print/xpdf/patches/patch-al | 14 | ||||
-rw-r--r-- | print/xpdf/patches/patch-am | 516 | ||||
-rw-r--r-- | print/xpdf/patches/patch-aq | 134 | ||||
-rw-r--r-- | print/xpdf/patches/patch-ar | 17 |
6 files changed, 459 insertions, 245 deletions
diff --git a/print/xpdf/Makefile b/print/xpdf/Makefile index 7cd8bdc157d..b6d808700d2 100644 --- a/print/xpdf/Makefile +++ b/print/xpdf/Makefile @@ -1,9 +1,6 @@ -# $NetBSD: Makefile,v 1.80 2013/06/04 22:17:01 tron Exp $ +# $NetBSD: Makefile,v 1.81 2014/08/01 12:31:27 tron Exp $ -DISTNAME= xpdf-3.03 -#PKGNAME= xpdf-3.02pl4 -#PKGREVISION= 4 -PKGREVISION= 4 +DISTNAME= xpdf-3.04 CATEGORIES= print MASTER_SITES= ftp://ftp.foolabs.com/pub/xpdf/ \ ${MASTER_SITE_SUNSITE:=apps/graphics/viewers/X/xpdf/} \ @@ -28,7 +25,6 @@ USE_LANGUAGES= c c++ GNU_CONFIGURE= yes CONFIGURE_ARGS+= --sysconfdir=${PKG_SYSCONFDIR:Q} CONFIGURE_ARGS+= --with-freetype2-includes=${BUILDLINK_PREFIX.freetype2}/include/freetype2 -CONFIGURE_ARGS+= --with-t1-includes=${BUILDLINK_PREFIX.t1lib}/include CONFIGURE_ENV+= CXXFLAGS=${CXXFLAGS:M*:Q} MAKE_ENV+= SED=${SED:Q} ECHO=${ECHO:Q} @@ -53,7 +49,6 @@ OWN_DIRS= share/xpdf BUILDLINK_API_DEPENDS.freetype2+= freetype2>=2.2.1 -.include "../../fonts/t1lib/buildlink3.mk" .include "../../graphics/freetype2/buildlink3.mk" .include "../../x11/libXpm/buildlink3.mk" .include "../../mk/motif.buildlink3.mk" diff --git a/print/xpdf/distinfo b/print/xpdf/distinfo index 66de83606ce..9161723b4b7 100644 --- a/print/xpdf/distinfo +++ b/print/xpdf/distinfo @@ -1,8 +1,8 @@ -$NetBSD: distinfo,v 1.41 2012/03/21 17:05:57 hans Exp $ +$NetBSD: distinfo,v 1.42 2014/08/01 12:31:27 tron Exp $ -SHA1 (xpdf-3.03.tar.gz) = 499423e8a795e0efd76ca798239eb4d0d52fe248 -RMD160 (xpdf-3.03.tar.gz) = ef1336c189026fb0ecd169e2b37b5a5aa22e04be -Size (xpdf-3.03.tar.gz) = 795537 bytes +SHA1 (xpdf-3.04.tar.gz) = b9b1dbb0335742a09d0442c60fd02f4f934618bd +RMD160 (xpdf-3.04.tar.gz) = fb29aad21054d5d3b349aec4806262feeca1bd8e +Size (xpdf-3.04.tar.gz) = 825519 bytes SHA1 (patch-aa) = ab41e35600d1e625b902076d947ec48a9c1bc59e SHA1 (patch-ac) = 6fa74df05e01510c792eb2b20f670e6903f30aa2 SHA1 (patch-ad) = 08202be663d819f033a7a5e6708b4158255bcf4a @@ -13,10 +13,8 @@ SHA1 (patch-ah) = 61e44757c30800754fc4966acb218325fd1bd26a SHA1 (patch-ai) = 2ef56341ee14cfb22c9d49e659cfa2955aa18ee6 SHA1 (patch-aj) = 36609d6ba7bc56be9b417558b90850fc19e62860 SHA1 (patch-ak) = a45747998f7c72f7db3f9199c244dc1d4962417d -SHA1 (patch-al) = c210ca493be97cf5b7ba8469f5258b10667e8633 -SHA1 (patch-am) = 1140a6030dfec7a737f5ac16c403225c88a046de +SHA1 (patch-al) = df18fb971275f99a7e1757f65455a181bb9eb8eb +SHA1 (patch-am) = e88ff60e7941cb7bdfdc4bf59727ca401f1a5758 SHA1 (patch-ap) = 5961dfe22ac087a7df0311235b4fab27d7554c58 -SHA1 (patch-aq) = 4cba560189d2977d1c5ea60acf2d50ca311efbe1 -SHA1 (patch-ar) = 5e4719a30a0412d9d731dbef8179c38bba67db94 SHA1 (patch-bc) = e3f8092c30325a3f7abf230daeadd4478a9db768 SHA1 (patch-xpdf_XPDFViewer.cc) = 38b1f79365149b37736ecfc73fa0e920fb758d93 diff --git a/print/xpdf/patches/patch-al b/print/xpdf/patches/patch-al index 8d9a3b2f890..9473a72f5a0 100644 --- a/print/xpdf/patches/patch-al +++ b/print/xpdf/patches/patch-al @@ -1,8 +1,10 @@ -$NetBSD: patch-al,v 1.4 2011/10/27 02:35:41 tez Exp $ +$NetBSD: patch-al,v 1.5 2014/08/01 12:31:27 tron Exp $ ---- xpdf/GlobalParams.cc.orig 2011-08-15 16:08:53.000000000 -0500 -+++ xpdf/GlobalParams.cc 2011-10-26 20:15:39.959345400 -0500 -@@ -110,11 +110,13 @@ +Adapt list of directories with fonts. + +--- xpdf/GlobalParams.cc.orig 2014-05-28 19:50:50.000000000 +0100 ++++ xpdf/GlobalParams.cc 2014-08-01 11:10:09.000000000 +0100 +@@ -120,11 +120,13 @@ }; #else static const char *displayFontDirs[] = { @@ -17,6 +19,6 @@ $NetBSD: patch-al,v 1.4 2011/10/27 02:35:41 tez Exp $ + "/usr/X11R7/lib/X11/fonts/Type1", + PREFIX"/xorg/lib/X11/fonts/Type1", + PREFIX"/share/fonts/urw", - NULL - }; + #if defined(__sun) && defined(__SVR4) + "/usr/sfw/share/ghostscript/fonts", #endif diff --git a/print/xpdf/patches/patch-am b/print/xpdf/patches/patch-am index b41b247966f..ca62c23ecb7 100644 --- a/print/xpdf/patches/patch-am +++ b/print/xpdf/patches/patch-am @@ -1,55 +1,98 @@ -$NetBSD: patch-am,v 1.3 2011/10/27 02:35:41 tez Exp $ +$NetBSD: patch-am,v 1.4 2014/08/01 12:31:27 tron Exp $ ---- xpdf/Makefile.in.orig 2011-08-15 16:08:53.000000000 -0500 -+++ xpdf/Makefile.in 2011-10-26 20:22:58.948064100 -0500 +Don't build command line utilities to avoid conflict with the +"poppler-utils" package. + +--- xpdf/Makefile.in.orig 2014-05-28 19:50:50.000000000 +0100 ++++ xpdf/Makefile.in 2014-08-01 13:18:36.000000000 +0100 @@ -19,7 +19,7 @@ SPLASHSRCDIR = $(srcdir)/../splash SPLASHLIBDIR = ../splash --CXXFLAGS = @CXXFLAGS@ @DEFS@ -I.. -I$(GOOSRCDIR) -I$(FOFISRCDIR) -I$(SPLASHSRCDIR) -I$(srcdir) @freetype2_CFLAGS@ @Sgm_CFLAGS@ @Xm_CFLAGS@ @Xt_CFLAGS@ @Xp_CFLAGS@ @Xext_CFLAGS@ @Xpm_CFLAGS@ @t1_CFLAGS@ @libpaper_CFLAGS@ @X_CFLAGS@ -+CXXFLAGS = @CXXFLAGS@ @DEFS@ -DPREFIX="\"@prefix@\"" -I.. -I$(GOOSRCDIR) -I$(FOFISRCDIR) -I$(SPLASHSRCDIR) -I$(srcdir) @freetype2_CFLAGS@ @Sgm_CFLAGS@ @Xm_CFLAGS@ @Xt_CFLAGS@ @Xp_CFLAGS@ @Xext_CFLAGS@ @Xpm_CFLAGS@ @t1_CFLAGS@ @libpaper_CFLAGS@ @X_CFLAGS@ +-CXXFLAGS = @CXXFLAGS@ @DEFS@ -I.. -I$(srcdir)/.. -I$(GOOSRCDIR) -I$(FOFISRCDIR) -I$(SPLASHSRCDIR) -I$(srcdir) @freetype2_CFLAGS@ @Sgm_CFLAGS@ @Xm_CFLAGS@ @Xt_CFLAGS@ @Xp_CFLAGS@ @Xext_CFLAGS@ @Xpm_CFLAGS@ @libpng_CFLAGS@ @libpaper_CFLAGS@ @X_CFLAGS@ @EXTRA_CFLAGS@ ++CXXFLAGS = @CXXFLAGS@ @DEFS@ -DPREFIX="\"@prefix@\"" -I.. -I$(srcdir)/.. -I$(GOOSRCDIR) -I$(FOFISRCDIR) -I$(SPLASHSRCDIR) -I$(srcdir) @freetype2_CFLAGS@ @Sgm_CFLAGS@ @Xm_CFLAGS@ @Xt_CFLAGS@ @Xp_CFLAGS@ @Xext_CFLAGS@ @Xpm_CFLAGS@ @libpng_CFLAGS@ @libpaper_CFLAGS@ @X_CFLAGS@ @EXTRA_CFLAGS@ LDFLAGS = @LDFLAGS@ -@@ -97,22 +97,13 @@ - $(srcdir)/XPDFViewer.cc \ +@@ -104,25 +104,13 @@ $(srcdir)/XpdfPluginAPI.cc \ $(srcdir)/XRef.cc \ + $(srcdir)/Zoox.cc \ - $(srcdir)/pdftops.cc \ - $(srcdir)/pdftotext.cc \ +- $(srcdir)/pdftohtml.cc \ - $(srcdir)/pdfinfo.cc \ - $(srcdir)/pdffonts.cc \ - $(srcdir)/pdfdetach.cc \ - $(srcdir)/pdftoppm.cc \ +- $(srcdir)/pdftopng.cc \ - $(srcdir)/pdfimages.cc \ $(srcdir)/xpdf.cc #------------------------------------------------------------------------ --all: xpdf$(EXE) pdftops$(EXE) pdftotext$(EXE) pdfinfo$(EXE) \ -- pdffonts$(EXE) pdfdetach$(EXE) pdftoppm$(EXE) pdfimages$(EXE) +-all: xpdf$(EXE) pdftops$(EXE) pdftotext$(EXE) pdftohtml$(EXE) \ +- pdfinfo$(EXE) pdffonts$(EXE) pdfdetach$(EXE) pdftoppm$(EXE) \ +- pdftopng$(EXE) pdfimages$(EXE) +all: xpdf$(EXE) --all-no-x: pdftops$(EXE) pdftotext$(EXE) pdfinfo$(EXE) pdffonts$(EXE) \ -- pdfdetach$(EXE) pdfimages$(EXE) +-all-no-x: pdftops$(EXE) pdftotext$(EXE) pdftohtml$(EXE) pdfinfo$(EXE) \ +- pdffonts$(EXE) pdfdetach$(EXE) pdfimages$(EXE) +all-no-x: #------------------------------------------------------------------------ -@@ -134,132 +125,8 @@ +@@ -188,496 +176,8 @@ #------------------------------------------------------------------------ --PDFTOPS_OBJS = Annot.o Array.o BuiltinFont.o BuiltinFontTables.o \ -- Catalog.o CharCodeToUnicode.o CMap.o Decrypt.o Dict.o Error.o \ -- FontEncodingTables.o Function.o Gfx.o GfxFont.o \ -- GfxState.o GlobalParams.o JArithmeticDecoder.o JBIG2Stream.o \ -- JPXStream.o Lexer.o Link.o NameToCharCode.o OptionalContent.o \ -- Outline.o Object.o OutputDev.o Page.o Parser.o PDFDoc.o \ -- PDFDocEncoding.o PreScanOutputDev.o PSOutputDev.o PSTokenizer.o \ -- SecurityHandler.o SplashOutputDev.o Stream.o UnicodeMap.o \ -- XpdfPluginAPI.o XRef.o pdftops.o --PDFTOPS_LIBS = -L$(GOOLIBDIR) -lGoo $(SPLASHLIBS) $(T1LIBS) $(FTLIBS) \ +-PDFTOPS_OBJS = \ +- AcroForm.o \ +- Annot.o \ +- Array.o \ +- BuiltinFont.o \ +- BuiltinFontTables.o \ +- Catalog.o \ +- CharCodeToUnicode.o \ +- CMap.o \ +- Decrypt.o \ +- Dict.o \ +- Error.o \ +- FontEncodingTables.o \ +- Form.o \ +- Function.o \ +- Gfx.o \ +- GfxFont.o \ +- GfxState.o \ +- GlobalParams.o \ +- JArithmeticDecoder.o \ +- JBIG2Stream.o \ +- JPXStream.o \ +- Lexer.o \ +- Link.o \ +- NameToCharCode.o \ +- OptionalContent.o \ +- Outline.o \ +- Object.o \ +- OutputDev.o \ +- Page.o \ +- Parser.o \ +- PDFDoc.o \ +- PDFDocEncoding.o \ +- PreScanOutputDev.o \ +- PSOutputDev.o \ +- PSTokenizer.o \ +- SecurityHandler.o \ +- SplashOutputDev.o \ +- Stream.o \ +- TextString.o \ +- UnicodeMap.o \ +- XFAForm.o \ +- XpdfPluginAPI.o \ +- XRef.o \ +- Zoox.o \ +- pdftops.o +-PDFTOPS_LIBS = -L$(GOOLIBDIR) -lGoo $(SPLASHLIBS) $(FTLIBS) \ - $(OTHERLIBS) -lm - -pdftops$(EXE): $(PDFTOPS_OBJS) $(GOOLIBDIR)/$(LIBPREFIX)Goo.a @@ -58,15 +101,51 @@ $NetBSD: patch-am,v 1.3 2011/10/27 02:35:41 tez Exp $ - -#------------------------------------------------------------------------ - --PDFTOTEXT_OBJS = Annot.o Array.o BuiltinFont.o BuiltinFontTables.o \ -- Catalog.o CharCodeToUnicode.o CMap.o Decrypt.o Dict.o Error.o \ -- FontEncodingTables.o Function.o Gfx.o GfxFont.o \ -- GfxState.o GlobalParams.o JArithmeticDecoder.o JBIG2Stream.o \ -- JPXStream.o Lexer.o Link.o NameToCharCode.o Object.o \ -- OptionalContent.o Outline.o OutputDev.o Page.o Parser.o PDFDoc.o \ -- PDFDocEncoding.o PSTokenizer.o SecurityHandler.o Stream.o \ -- TextOutputDev.o UnicodeMap.o UnicodeTypeTable.o XpdfPluginAPI.o \ -- XRef.o pdftotext.o +-PDFTOTEXT_OBJS = \ +- AcroForm.o \ +- Annot.o \ +- Array.o \ +- BuiltinFont.o \ +- BuiltinFontTables.o \ +- Catalog.o \ +- CharCodeToUnicode.o \ +- CMap.o \ +- Decrypt.o \ +- Dict.o \ +- Error.o \ +- FontEncodingTables.o \ +- Form.o \ +- Function.o \ +- Gfx.o \ +- GfxFont.o \ +- GfxState.o \ +- GlobalParams.o \ +- JArithmeticDecoder.o \ +- JBIG2Stream.o \ +- JPXStream.o \ +- Lexer.o \ +- Link.o \ +- NameToCharCode.o \ +- Object.o \ +- OptionalContent.o \ +- Outline.o \ +- OutputDev.o \ +- Page.o \ +- Parser.o \ +- PDFDoc.o \ +- PDFDocEncoding.o \ +- PSTokenizer.o \ +- SecurityHandler.o \ +- Stream.o \ +- TextOutputDev.o \ +- TextString.o \ +- UnicodeMap.o \ +- UnicodeTypeTable.o \ +- XFAForm.o \ +- XpdfPluginAPI.o \ +- XRef.o \ +- Zoox.o \ +- pdftotext.o -PDFTOTEXT_LIBS = -L$(GOOLIBDIR) -lGoo $(OTHERLIBS) -lm - -pdftotext$(EXE): $(PDFTOTEXT_OBJS) $(GOOLIBDIR)/$(LIBPREFIX)Goo.a @@ -75,14 +154,105 @@ $NetBSD: patch-am,v 1.3 2011/10/27 02:35:41 tez Exp $ - -#------------------------------------------------------------------------ - --PDFINFO_OBJS = Annot.o Array.o BuiltinFont.o BuiltinFontTables.o \ -- Catalog.o CharCodeToUnicode.o CMap.o Decrypt.o Dict.o Error.o \ -- FontEncodingTables.o Function.o Gfx.o GfxFont.o \ -- GfxState.o GlobalParams.o JArithmeticDecoder.o JBIG2Stream.o \ -- JPXStream.o Lexer.o Link.o NameToCharCode.o Object.o \ -- OptionalContent.o Outline.o OutputDev.o Page.o Parser.o PDFDoc.o \ -- PDFDocEncoding.o PSTokenizer.o SecurityHandler.o Stream.o \ -- UnicodeMap.o XpdfPluginAPI.o XRef.o pdfinfo.o +-PDFTOHTML_OBJS = \ +- AcroForm.o \ +- Annot.o \ +- Array.o \ +- BuiltinFont.o \ +- BuiltinFontTables.o \ +- Catalog.o \ +- CharCodeToUnicode.o \ +- CMap.o \ +- Decrypt.o \ +- Dict.o \ +- Error.o \ +- FontEncodingTables.o \ +- Form.o \ +- Function.o \ +- Gfx.o \ +- GfxFont.o \ +- GfxState.o \ +- GlobalParams.o \ +- HTMLGen.o \ +- JArithmeticDecoder.o \ +- JBIG2Stream.o \ +- JPXStream.o \ +- Lexer.o \ +- Link.o \ +- NameToCharCode.o \ +- Object.o \ +- OptionalContent.o \ +- Outline.o \ +- OutputDev.o \ +- Page.o \ +- Parser.o \ +- PDFDoc.o \ +- PDFDocEncoding.o \ +- PSTokenizer.o \ +- SecurityHandler.o \ +- SplashOutputDev.o \ +- Stream.o \ +- TextOutputDev.o \ +- TextString.o \ +- UnicodeMap.o \ +- UnicodeTypeTable.o \ +- XFAForm.o \ +- XpdfPluginAPI.o \ +- XRef.o \ +- Zoox.o \ +- pdftohtml.o +-PDFTOHTML_LIBS = -L$(GOOLIBDIR) -lGoo $(SPLASHLIBS) $(FTLIBS) \ +- $(OTHERLIBS) $(PNGLIBS) -lm +- +-pdftohtml$(EXE): $(PDFTOHTML_OBJS) $(GOOLIBDIR)/$(LIBPREFIX)Goo.a +- $(CXX) $(CXXFLAGS) $(LDFLAGS) -o pdftohtml$(EXE) $(PDFTOHTML_OBJS) \ +- $(PDFTOHTML_LIBS) +- +-#------------------------------------------------------------------------ +- +-PDFINFO_OBJS = \ +- AcroForm.o \ +- Annot.o \ +- Array.o \ +- BuiltinFont.o \ +- BuiltinFontTables.o \ +- Catalog.o \ +- CharCodeToUnicode.o \ +- CMap.o \ +- Decrypt.o \ +- Dict.o \ +- Error.o \ +- FontEncodingTables.o \ +- Form.o \ +- Function.o \ +- Gfx.o \ +- GfxFont.o \ +- GfxState.o \ +- GlobalParams.o \ +- JArithmeticDecoder.o \ +- JBIG2Stream.o \ +- JPXStream.o \ +- Lexer.o \ +- Link.o \ +- NameToCharCode.o \ +- Object.o \ +- OptionalContent.o \ +- Outline.o \ +- OutputDev.o \ +- Page.o \ +- Parser.o \ +- PDFDoc.o \ +- PDFDocEncoding.o \ +- PSTokenizer.o \ +- SecurityHandler.o \ +- Stream.o \ +- TextString.o \ +- UnicodeMap.o \ +- XFAForm.o \ +- XpdfPluginAPI.o \ +- XRef.o \ +- Zoox.o \ +- pdfinfo.o -PDFINFO_LIBS = -L$(GOOLIBDIR) -lGoo $(OTHERLIBS) -lm - -pdfinfo$(EXE): $(PDFINFO_OBJS) $(GOOLIBDIR)/$(LIBPREFIX)Goo.a @@ -91,14 +261,49 @@ $NetBSD: patch-am,v 1.3 2011/10/27 02:35:41 tez Exp $ - -#------------------------------------------------------------------------ - --PDFFONTS_OBJS = Annot.o Array.o BuiltinFont.o BuiltinFontTables.o \ -- Catalog.o CharCodeToUnicode.o CMap.o Decrypt.o Dict.o Error.o \ -- FontEncodingTables.o Function.o Gfx.o GfxFont.o \ -- GfxState.o GlobalParams.o JArithmeticDecoder.o JBIG2Stream.o \ -- JPXStream.o Lexer.o Link.o NameToCharCode.o Object.o \ -- OptionalContent.o Outline.o OutputDev.o Page.o Parser.o PDFDoc.o \ -- PDFDocEncoding.o PSTokenizer.o SecurityHandler.o Stream.o \ -- UnicodeMap.o XpdfPluginAPI.o XRef.o pdffonts.o +-PDFFONTS_OBJS = \ +- AcroForm.o \ +- Annot.o \ +- Array.o \ +- BuiltinFont.o \ +- BuiltinFontTables.o \ +- Catalog.o \ +- CharCodeToUnicode.o \ +- CMap.o \ +- Decrypt.o \ +- Dict.o \ +- Error.o \ +- FontEncodingTables.o \ +- Form.o \ +- Function.o \ +- Gfx.o \ +- GfxFont.o \ +- GfxState.o \ +- GlobalParams.o \ +- JArithmeticDecoder.o \ +- JBIG2Stream.o \ +- JPXStream.o \ +- Lexer.o \ +- Link.o \ +- NameToCharCode.o \ +- Object.o \ +- OptionalContent.o \ +- Outline.o \ +- OutputDev.o \ +- Page.o \ +- Parser.o \ +- PDFDoc.o \ +- PDFDocEncoding.o \ +- PSTokenizer.o \ +- SecurityHandler.o \ +- Stream.o \ +- TextString.o \ +- UnicodeMap.o \ +- XFAForm.o \ +- XpdfPluginAPI.o \ +- XRef.o \ +- Zoox.o \ +- pdffonts.o -PDFFONTS_LIBS = -L$(GOOLIBDIR) -lGoo $(OTHERLIBS) -lm - -pdffonts$(EXE): $(PDFFONTS_OBJS) $(GOOLIBDIR)/$(LIBPREFIX)Goo.a @@ -107,14 +312,49 @@ $NetBSD: patch-am,v 1.3 2011/10/27 02:35:41 tez Exp $ - -#------------------------------------------------------------------------ - --PDFDETACH_OBJS = Annot.o Array.o BuiltinFont.o BuiltinFontTables.o \ -- Catalog.o CharCodeToUnicode.o CMap.o Decrypt.o Dict.o Error.o \ -- FontEncodingTables.o Function.o Gfx.o GfxFont.o \ -- GfxState.o GlobalParams.o JArithmeticDecoder.o JBIG2Stream.o \ -- JPXStream.o Lexer.o Link.o NameToCharCode.o Object.o \ -- OptionalContent.o Outline.o OutputDev.o Page.o Parser.o PDFDoc.o \ -- PDFDocEncoding.o PSTokenizer.o SecurityHandler.o Stream.o \ -- UnicodeMap.o XpdfPluginAPI.o XRef.o pdfdetach.o +-PDFDETACH_OBJS = \ +- AcroForm.o \ +- Annot.o \ +- Array.o \ +- BuiltinFont.o \ +- BuiltinFontTables.o \ +- Catalog.o \ +- CharCodeToUnicode.o \ +- CMap.o \ +- Decrypt.o \ +- Dict.o \ +- Error.o \ +- FontEncodingTables.o \ +- Form.o \ +- Function.o \ +- Gfx.o \ +- GfxFont.o \ +- GfxState.o \ +- GlobalParams.o \ +- JArithmeticDecoder.o \ +- JBIG2Stream.o \ +- JPXStream.o \ +- Lexer.o \ +- Link.o \ +- NameToCharCode.o \ +- Object.o \ +- OptionalContent.o \ +- Outline.o \ +- OutputDev.o \ +- Page.o \ +- Parser.o \ +- PDFDoc.o \ +- PDFDocEncoding.o \ +- PSTokenizer.o \ +- SecurityHandler.o \ +- Stream.o \ +- TextString.o \ +- UnicodeMap.o \ +- XFAForm.o \ +- XpdfPluginAPI.o \ +- XRef.o \ +- Zoox.o \ +- pdfdetach.o -PDFDETACH_LIBS = -L$(GOOLIBDIR) -lGoo $(OTHERLIBS) -lm - -pdfdetach$(EXE): $(PDFDETACH_OBJS) $(GOOLIBDIR)/$(LIBPREFIX)Goo.a @@ -123,16 +363,53 @@ $NetBSD: patch-am,v 1.3 2011/10/27 02:35:41 tez Exp $ - -#------------------------------------------------------------------------ - --PDFTOPPM_OBJS = Annot.o Array.o BuiltinFont.o BuiltinFontTables.o \ -- Catalog.o CharCodeToUnicode.o CMap.o Decrypt.o Dict.o Error.o \ -- FontEncodingTables.o Function.o Gfx.o GfxFont.o GfxState.o \ -- GlobalParams.o JArithmeticDecoder.o JBIG2Stream.o JPXStream.o \ -- Lexer.o Link.o NameToCharCode.o Object.o OptionalContent.o \ -- Outline.o OutputDev.o Page.o Parser.o PDFDoc.o PDFDocEncoding.o \ -- PSTokenizer.o SecurityHandler.o SplashOutputDev.o Stream.o \ -- TextOutputDev.o UnicodeMap.o UnicodeTypeTable.o XpdfPluginAPI.o \ -- XRef.o pdftoppm.o --PDFTOPPM_LIBS = -L$(GOOLIBDIR) -lGoo $(SPLASHLIBS) $(T1LIBS) $(FTLIBS) \ +-PDFTOPPM_OBJS = \ +- AcroForm.o \ +- Annot.o \ +- Array.o \ +- BuiltinFont.o \ +- BuiltinFontTables.o \ +- Catalog.o \ +- CharCodeToUnicode.o \ +- CMap.o \ +- Decrypt.o \ +- Dict.o \ +- Error.o \ +- FontEncodingTables.o \ +- Form.o \ +- Function.o \ +- Gfx.o \ +- GfxFont.o \ +- GfxState.o \ +- GlobalParams.o \ +- JArithmeticDecoder.o \ +- JBIG2Stream.o \ +- JPXStream.o \ +- Lexer.o \ +- Link.o \ +- NameToCharCode.o \ +- Object.o \ +- OptionalContent.o \ +- Outline.o \ +- OutputDev.o \ +- Page.o \ +- Parser.o \ +- PDFDoc.o \ +- PDFDocEncoding.o \ +- PSTokenizer.o \ +- SecurityHandler.o \ +- SplashOutputDev.o \ +- Stream.o \ +- TextOutputDev.o \ +- TextString.o \ +- UnicodeMap.o \ +- UnicodeTypeTable.o \ +- XFAForm.o \ +- XpdfPluginAPI.o \ +- XRef.o \ +- Zoox.o \ +- pdftoppm.o +-PDFTOPPM_LIBS = -L$(GOOLIBDIR) -lGoo $(SPLASHLIBS) $(FTLIBS) \ - $(OTHERLIBS) -lm - -pdftoppm$(EXE): $(PDFTOPPM_OBJS) $(GOOLIBDIR)/$(LIBPREFIX)Goo.a @@ -141,14 +418,105 @@ $NetBSD: patch-am,v 1.3 2011/10/27 02:35:41 tez Exp $ - -#------------------------------------------------------------------------ - --PDFIMAGES_OBJS = Annot.o Array.o BuiltinFont.o BuiltinFontTables.o \ -- Catalog.o CharCodeToUnicode.o CMap.o Decrypt.o Dict.o Error.o \ -- FontEncodingTables.o Function.o Gfx.o GfxFont.o GfxState.o \ -- GlobalParams.o ImageOutputDev.o JArithmeticDecoder.o \ -- JBIG2Stream.o JPXStream.o Lexer.o Link.o NameToCharCode.o Object.o \ -- OptionalContent.o Outline.o OutputDev.o Page.o Parser.o PDFDoc.o \ -- PDFDocEncoding.o PSTokenizer.o SecurityHandler.o Stream.o \ -- UnicodeMap.o XpdfPluginAPI.o XRef.o pdfimages.o +-PDFTOPNG_OBJS = \ +- AcroForm.o \ +- Annot.o \ +- Array.o \ +- BuiltinFont.o \ +- BuiltinFontTables.o \ +- Catalog.o \ +- CharCodeToUnicode.o \ +- CMap.o \ +- Decrypt.o \ +- Dict.o \ +- Error.o \ +- FontEncodingTables.o \ +- Form.o \ +- Function.o \ +- Gfx.o \ +- GfxFont.o \ +- GfxState.o \ +- GlobalParams.o \ +- JArithmeticDecoder.o \ +- JBIG2Stream.o \ +- JPXStream.o \ +- Lexer.o \ +- Link.o \ +- NameToCharCode.o \ +- Object.o \ +- OptionalContent.o \ +- Outline.o \ +- OutputDev.o \ +- Page.o \ +- Parser.o \ +- PDFDoc.o \ +- PDFDocEncoding.o \ +- PSTokenizer.o \ +- SecurityHandler.o \ +- SplashOutputDev.o \ +- Stream.o \ +- TextOutputDev.o \ +- TextString.o \ +- UnicodeMap.o \ +- UnicodeTypeTable.o \ +- XFAForm.o \ +- XpdfPluginAPI.o \ +- XRef.o \ +- Zoox.o \ +- pdftopng.o +-PDFTOPNG_LIBS = -L$(GOOLIBDIR) -lGoo $(SPLASHLIBS) $(FTLIBS) \ +- $(OTHERLIBS) $(PNGLIBS) -lm +- +-pdftopng$(EXE): $(PDFTOPNG_OBJS) $(GOOLIBDIR)/$(LIBPREFIX)Goo.a +- $(CXX) $(CXXFLAGS) $(LDFLAGS) -o pdftopng$(EXE) $(PDFTOPNG_OBJS) \ +- $(PDFTOPNG_LIBS) +- +-#------------------------------------------------------------------------ +- +-PDFIMAGES_OBJS = \ +- AcroForm.o \ +- Annot.o \ +- Array.o \ +- BuiltinFont.o \ +- BuiltinFontTables.o \ +- Catalog.o \ +- CharCodeToUnicode.o \ +- CMap.o \ +- Decrypt.o \ +- Dict.o \ +- Error.o \ +- FontEncodingTables.o \ +- Form.o \ +- Function.o \ +- Gfx.o \ +- GfxFont.o \ +- GfxState.o \ +- GlobalParams.o \ +- ImageOutputDev.o \ +- JArithmeticDecoder.o \ +- JBIG2Stream.o \ +- JPXStream.o \ +- Lexer.o \ +- Link.o \ +- NameToCharCode.o \ +- Object.o \ +- OptionalContent.o \ +- Outline.o \ +- OutputDev.o \ +- Page.o \ +- Parser.o \ +- PDFDoc.o \ +- PDFDocEncoding.o \ +- PSTokenizer.o \ +- SecurityHandler.o \ +- Stream.o \ +- TextString.o \ +- UnicodeMap.o \ +- XFAForm.o \ +- XpdfPluginAPI.o \ +- XRef.o \ +- Zoox.o \ +- pdfimages.o -PDFIMAGES_LIBS = -L$(GOOLIBDIR) -lGoo $(OTHERLIBS) -lm - -pdfimages$(EXE): $(PDFIMAGES_OBJS) $(GOOLIBDIR)/$(LIBPREFIX)Goo.a @@ -161,10 +529,12 @@ $NetBSD: patch-am,v 1.3 2011/10/27 02:35:41 tez Exp $ rm -f $(XPDF_OBJS) xpdf$(EXE) - rm -f $(PDFTOPS_OBJS) pdftops$(EXE) - rm -f $(PDFTOTEXT_OBJS) pdftotext$(EXE) +- rm -f $(PDFTOHTML_OBJS) pdftohtml$(EXE) - rm -f $(PDFINFO_OBJS) pdfinfo$(EXE) - rm -f $(PDFFONTS_OBJS) pdffonts$(EXE) - rm -f $(PDFDETACH_OBJS) pdfdetach$(EXE) - rm -f $(PDFTOPPM_OBJS) pdftoppm$(EXE) +- rm -f $(PDFTOPNG_OBJS) pdftopng$(EXE) - rm -f $(PDFIMAGES_OBJS) pdfimages$(EXE) #------------------------------------------------------------------------ diff --git a/print/xpdf/patches/patch-aq b/print/xpdf/patches/patch-aq deleted file mode 100644 index a056d225e23..00000000000 --- a/print/xpdf/patches/patch-aq +++ /dev/null @@ -1,134 +0,0 @@ -$NetBSD: patch-aq,v 1.4 2011/10/27 02:35:41 tez Exp $ - -Fix arbitrary code execution with embedded fonts (CVE-2008-1693). - ---- xpdf/Object.h.orig 2011-08-15 16:08:53.000000000 -0500 -+++ xpdf/Object.h 2011-10-26 20:48:41.411023600 -0500 -@@ -68,17 +68,18 @@ - //------------------------------------------------------------------------ - - #ifdef DEBUG_MEM --#define initObj(t) ++numAlloc[type = t] -+#define initObj(t) zeroUnion(); ++numAlloc[type = t] - #else --#define initObj(t) type = t -+#define initObj(t) zeroUnion(); type = t - #endif - - class Object { - public: -- -+ // attempt to clear the anonymous union -+ void zeroUnion() { this->name = NULL; } - // Default constructor. - Object(): -- type(objNone) {} -+ type(objNone) { zeroUnion(); } - - // Initialize an object. - Object *initBool(GBool boolnA) -@@ -220,16 +221,16 @@ - #include "Array.h" - - inline int Object::arrayGetLength() -- { return array->getLength(); } -+ { if (type != objArray) return 0; return array->getLength(); } - - inline void Object::arrayAdd(Object *elem) -- { array->add(elem); } -+ { if (type == objArray) array->add(elem); } - - inline Object *Object::arrayGet(int i, Object *obj) -- { return array->get(i, obj); } -+ { if (type != objArray) return obj->initNull(); return array->get(i, obj); } - - inline Object *Object::arrayGetNF(int i, Object *obj) -- { return array->getNF(i, obj); } -+ { if (type != objArray) return obj->initNull(); return array->getNF(i, obj); } - - //------------------------------------------------------------------------ - // Dict accessors. -@@ -238,31 +239,31 @@ - #include "Dict.h" - - inline int Object::dictGetLength() -- { return dict->getLength(); } -+ { if (type != objDict) return 0; return dict->getLength(); } - - inline void Object::dictAdd(char *key, Object *val) -- { dict->add(key, val); } -+ { if (type == objDict) dict->add(key, val); } - - inline GBool Object::dictIs(const char *dictType) -- { return dict->is(dictType); } -+ { return (type == objDict) && dict->is(dictType); } - - inline GBool Object::isDict(const char *dictType) - { return type == objDict && dictIs(dictType); } - - inline Object *Object::dictLookup(const char *key, Object *obj, int recursion) -- { return dict->lookup(key, obj, recursion); } -+ { if (type != objDict) return obj->initNull(); return dict->lookup(key, obj, recursion); } - - inline Object *Object::dictLookupNF(const char *key, Object *obj) -- { return dict->lookupNF(key, obj); } -+ { if (type != objDict) return obj->initNull(); return dict->lookupNF(key, obj); } - - inline char *Object::dictGetKey(int i) -- { return dict->getKey(i); } -+ { if (type != objDict) return NULL; return dict->getKey(i); } - - inline Object *Object::dictGetVal(int i, Object *obj) -- { return dict->getVal(i, obj); } -+ { if (type != objDict) return obj->initNull(); return dict->getVal(i, obj); } - - inline Object *Object::dictGetValNF(int i, Object *obj) -- { return dict->getValNF(i, obj); } -+ { if (type != objDict) return obj->initNull(); return dict->getValNF(i, obj); } - - //------------------------------------------------------------------------ - // Stream accessors. -@@ -271,33 +272,33 @@ - #include "Stream.h" - - inline GBool Object::streamIs(char *dictType) -- { return stream->getDict()->is(dictType); } -+ { return (type == objStream) && stream->getDict()->is(dictType); } - - inline GBool Object::isStream(char *dictType) -- { return type == objStream && streamIs(dictType); } -+ { return (type == objStream) && streamIs(dictType); } - - inline void Object::streamReset() -- { stream->reset(); } -+ { if (type == objStream) stream->reset(); } - - inline void Object::streamClose() -- { stream->close(); } -+ { if (type == objStream) stream->close(); } - - inline int Object::streamGetChar() -- { return stream->getChar(); } -+ { if (type != objStream) return EOF; return stream->getChar(); } - - inline int Object::streamLookChar() -- { return stream->lookChar(); } -+ { if (type != objStream) return EOF; return stream->lookChar(); } - - inline char *Object::streamGetLine(char *buf, int size) -- { return stream->getLine(buf, size); } -+ { if (type != objStream) return NULL; return stream->getLine(buf, size); } - - inline Guint Object::streamGetPos() -- { return stream->getPos(); } -+ { if (type != objStream) return 0; return stream->getPos(); } - - inline void Object::streamSetPos(Guint pos, int dir) -- { stream->setPos(pos, dir); } -+ { if (type == objStream) stream->setPos(pos, dir); } - - inline Dict *Object::streamGetDict() -- { return stream->getDict(); } -+ { if (type != objStream) return NULL; return stream->getDict(); } - - #endif diff --git a/print/xpdf/patches/patch-ar b/print/xpdf/patches/patch-ar deleted file mode 100644 index 48dff81936e..00000000000 --- a/print/xpdf/patches/patch-ar +++ /dev/null @@ -1,17 +0,0 @@ -$NetBSD: patch-ar,v 1.4 2008/04/20 15:48:12 tonnerre Exp $ - ---- xpdf/GfxState.cc.orig 2008-02-09 12:46:17.000000000 +0100 -+++ xpdf/GfxState.cc -@@ -3349,6 +3349,12 @@ GfxImageColorMap::GfxImageColorMap(int b - maxPixel = (1 << bits) - 1; - colorSpace = colorSpaceA; - -+ // this is a hack to support 16 bits images, everywhere -+ // we assume a component fits in 8 bits, with this hack -+ // we treat 16 bit images as 8 bit ones until it's fixed correctly. -+ // The hack has another part on ImageStream::getLine -+ if (maxPixel > 255) maxPixel = 255; -+ - // initialize - for (k = 0; k < gfxColorMaxComps; ++k) { - lookup[k] = NULL; |