packages: xpdf/xpdf-fontdirs.patch, xpdf/xpdf-remove_protections.patch, xpd...

qboosh qboosh at pld-linux.org
Sun Aug 21 08:54:11 CEST 2011


Author: qboosh                       Date: Sun Aug 21 06:54:11 2011 GMT
Module: packages                      Tag: HEAD
---- Log message:
- updated to 3.03
- updated remove_protections,fontdirs patches
- updated License (GPL v2 or v3 now)
- no longer uses external t1lib (caused security problems)

---- Files affected:
packages/xpdf:
   xpdf-fontdirs.patch (1.1 -> 1.2) , xpdf-remove_protections.patch (1.7 -> 1.8) , xpdf.spec (1.124 -> 1.125) , xpdf-3.02pl1.patch (1.1 -> NONE)  (REMOVED), xpdf-3.02pl2.patch (1.1 -> NONE)  (REMOVED), xpdf-3.02pl3.patch (1.1 -> NONE)  (REMOVED), xpdf-3.02pl4.patch (1.1 -> NONE)  (REMOVED), xpdf-3.02pl5.patch (1.1 -> NONE)  (REMOVED)

---- Diffs:

================================================================
Index: packages/xpdf/xpdf-fontdirs.patch
diff -u packages/xpdf/xpdf-fontdirs.patch:1.1 packages/xpdf/xpdf-fontdirs.patch:1.2
--- packages/xpdf/xpdf-fontdirs.patch:1.1	Sun Jan 25 16:25:18 2004
+++ packages/xpdf/xpdf-fontdirs.patch	Sun Aug 21 08:54:05 2011
@@ -1,12 +1,15 @@
---- xpdf-3.00/xpdf/GlobalParams.cc.orig	2004-01-22 02:26:45.000000000 +0100
-+++ xpdf-3.00/xpdf/GlobalParams.cc	2004-01-25 16:22:04.270214784 +0100
-@@ -81,8 +81,7 @@
+--- xpdf-3.03/xpdf/GlobalParams.cc.orig	2011-08-15 23:08:53.000000000 +0200
++++ xpdf-3.03/xpdf/GlobalParams.cc	2011-08-21 08:31:54.652749969 +0200
+@@ -110,11 +110,7 @@
  };
- 
- static char *displayFontDirs[] = {
+ #else
+ static const char *displayFontDirs[] = {
 -  "/usr/share/ghostscript/fonts",
 -  "/usr/local/share/ghostscript/fonts",
+-  "/usr/share/fonts/default/Type1",
+-  "/usr/share/fonts/default/ghostscript",
+-  "/usr/share/fonts/type1/gsfonts",
 +  "/usr/share/fonts/Type1",
-   "/usr/share/fonts/default/Type1",
    NULL
  };
+ #endif

================================================================
Index: packages/xpdf/xpdf-remove_protections.patch
diff -u packages/xpdf/xpdf-remove_protections.patch:1.7 packages/xpdf/xpdf-remove_protections.patch:1.8
--- packages/xpdf/xpdf-remove_protections.patch:1.7	Sun Jun  6 23:15:22 2010
+++ packages/xpdf/xpdf-remove_protections.patch	Sun Aug 21 08:54:06 2011
@@ -5,31 +5,8 @@
 ## DP: Remove PDF file permission checks
 
 @DPATCH@
---- a/xpdf/PDFCore.cc
-+++ b/xpdf/PDFCore.cc
-@@ -4,6 +4,8 @@
- //
- // Copyright 2004 Glyph & Cog, LLC
- //
-+// Modified for Debian by Hamish Moffatt, 18 August 2005.
-+//
- //========================================================================
- 
- #include <aconf.h>
-@@ -1563,9 +1565,11 @@
-   int x0, y0, x1, y1, t;
-   GString *s;
- 
-+#ifdef ENFORCE_PERMISSIONS
-   if (!doc->okToCopy()) {
-     return NULL;
-   }
-+#endif
-   if ((page = findPage(pg))) {
-     cvtUserToDev(pg, xMin, yMin, &x0, &y0);
-     cvtUserToDev(pg, xMax, yMax, &x1, &y1);
---- a/xpdf/XPDFCore.cc
-+++ b/xpdf/XPDFCore.cc
+--- xpdf-3.03/xpdf/XPDFCore.cc.orig	2011-08-15 23:08:53.000000000 +0200
++++ xpdf-3.03/xpdf/XPDFCore.cc	2011-08-21 08:23:12.502750231 +0200
 @@ -4,6 +4,8 @@
  //
  // Copyright 2002-2003 Glyph & Cog, LLC
@@ -39,7 +16,7 @@
  //========================================================================
  
  #include <aconf.h>
-@@ -384,11 +386,15 @@
+@@ -384,12 +386,16 @@
  #ifndef NO_TEXT_SELECT
        if (selectULX != selectLRX &&
  	  selectULY != selectLRY) {
@@ -47,15 +24,16 @@
  	if (doc->okToCopy()) {
  	  copySelection();
  	} else {
- 	  error(-1, "Copying of text from this document is not allowed.");
+ 	  error(errNotAllowed, -1,
+ 		"Copying of text from this document is not allowed.");
  	}
 +#else
-+        copySelection();
++	  copySelection();
 +#endif
        }
  #endif
      }
-@@ -407,9 +413,11 @@
+@@ -408,9 +414,11 @@
    int pg;
    double ulx, uly, lrx, lry;
  
@@ -67,8 +45,8 @@
    if (getSelection(&pg, &ulx, &uly, &lrx, &lry)) {
      //~ for multithreading: need a mutex here
      if (currentSelection) {
---- a/xpdf/XPDFViewer.cc
-+++ b/xpdf/XPDFViewer.cc
+--- xpdf-3.03/xpdf/XPDFViewer.cc.orig	2011-08-15 23:08:53.000000000 +0200
++++ xpdf-3.03/xpdf/XPDFViewer.cc	2011-08-21 08:23:52.699416877 +0200
 @@ -4,6 +4,8 @@
  //
  // Copyright 2002-2003 Glyph & Cog, LLC
@@ -78,21 +56,21 @@
  //========================================================================
  
  #include <aconf.h>
-@@ -3406,10 +3408,12 @@
+@@ -3492,10 +3494,12 @@
    PSOutputDev *psOut;
  
    doc = viewer->core->getDoc();
 +#ifdef ENFORCE_PERMISSIONS
    if (!doc->okToPrint()) {
-     error(-1, "Printing this document is not allowed.");
+     error(errNotAllowed, -1, "Printing this document is not allowed.");
      return;
    }
 +#endif
  
    viewer->core->setBusyCursor(gTrue);
  
---- a/xpdf/pdfimages.cc
-+++ b/xpdf/pdfimages.cc
+--- xpdf-3.03/xpdf/pdfimages.cc.orig	2011-08-15 23:08:53.000000000 +0200
++++ xpdf-3.03/xpdf/pdfimages.cc	2011-08-21 08:24:17.356083531 +0200
 @@ -4,6 +4,8 @@
  //
  // Copyright 1998-2003 Glyph & Cog, LLC
@@ -102,13 +80,14 @@
  //========================================================================
  
  #include <aconf.h>
-@@ -119,11 +121,13 @@
+@@ -119,12 +121,14 @@
    }
  
    // check for copy permission
 +#ifdef ENFORCE_PERMISSIONS
    if (!doc->okToCopy()) {
-     error(-1, "Copying of images from this document is not allowed.");
+     error(errNotAllowed, -1,
+ 	  "Copying of images from this document is not allowed.");
      exitCode = 3;
      goto err1;
    }
@@ -116,8 +95,8 @@
  
    // get page range
    if (firstPage < 1)
---- a/xpdf/pdftops.cc
-+++ b/xpdf/pdftops.cc
+--- xpdf-3.03/xpdf/pdftops.cc.orig	2011-08-15 23:08:53.000000000 +0200
++++ xpdf-3.03/xpdf/pdftops.cc	2011-08-21 08:24:36.072750189 +0200
 @@ -4,6 +4,8 @@
  //
  // Copyright 1996-2003 Glyph & Cog, LLC
@@ -134,7 +113,7 @@
 +#ifdef ENFORCE_PERMISSIONS
    // check for print permission
    if (!doc->okToPrint()) {
-     error(-1, "Printing this document is not allowed.");
+     error(errNotAllowed, -1, "Printing this document is not allowed.");
      exitCode = 3;
      goto err1;
    }
@@ -142,8 +121,8 @@
  
    // construct PostScript file name
    if (argc == 3) {
---- a/xpdf/pdftotext.cc
-+++ b/xpdf/pdftotext.cc
+--- xpdf-3.03/xpdf/pdftotext.cc.orig	2011-08-15 23:08:53.000000000 +0200
++++ xpdf-3.03/xpdf/pdftotext.cc	2011-08-21 08:24:58.639416844 +0200
 @@ -4,6 +4,8 @@
  //
  // Copyright 1997-2003 Glyph & Cog, LLC
@@ -153,14 +132,15 @@
  //========================================================================
  
  #include <aconf.h>
-@@ -160,12 +162,14 @@
+@@ -168,6 +170,7 @@
      goto err2;
    }
  
 +#ifdef ENFORCE_PERMISSIONS
    // check for copy permission
    if (!doc->okToCopy()) {
-     error(-1, "Copying of text from this document is not allowed.");
+     error(errNotAllowed, -1,
+@@ -175,6 +178,7 @@
      exitCode = 3;
      goto err2;
    }

================================================================
Index: packages/xpdf/xpdf.spec
diff -u packages/xpdf/xpdf.spec:1.124 packages/xpdf/xpdf.spec:1.125
--- packages/xpdf/xpdf.spec:1.124	Sat Jan 29 01:08:10 2011
+++ packages/xpdf/xpdf.spec	Sun Aug 21 08:54:06 2011
@@ -6,7 +6,7 @@
 #	  support files but don't require entire xpdf
 #
 # Conditional build:
-%bcond_with	protections	# remove protections against fair use (printing and copying)
+%bcond_with	protections	# protections against fair use (printing and copying)
 %bcond_without	x		# X-based browser
 #
 Summary:	Portable Document Format (PDF) file viewer
@@ -17,22 +17,17 @@
 Summary(ru.UTF-8):	Программа для просмотра PDF файлов
 Summary(uk.UTF-8):	Програма для перегляду PDF файлів
 Name:		xpdf
-Version:	3.02
-Release:	9
-License:	GPL
+Version:	3.03
+Release:	1
+License:	GPL v2 or GPL v3
 Group:		X11/Applications
 Source0:	ftp://ftp.foolabs.com/pub/xpdf/%{name}-%{version}.tar.gz
-# Source0-md5:	599dc4cc65a07ee868cf92a667a913d2
+# Source0-md5:	af75f772bee0e5ae4a811ff9d03eac5a
 Source1:	%{name}.desktop
 Source2:	%{name}.png
 Source3:	%{name}rc
 Patch0:		%{name}-remove_protections.patch
 Patch1:		%{name}-fontdirs.patch
-Patch2:		%{name}-%{version}pl1.patch
-Patch3:		%{name}-%{version}pl2.patch
-Patch4:		%{name}-%{version}pl3.patch
-Patch5:		%{name}-%{version}pl4.patch
-Patch6:		%{name}-%{version}pl5.patch
 URL:		http://www.foolabs.com/xpdf/
 %{?with_x:BuildRequires:	xorg-lib-libX11-devel}
 BuildRequires:	autoconf
@@ -40,7 +35,6 @@
 BuildRequires:	libpaper-devel
 BuildRequires:	libstdc++-devel
 %{?with_x:BuildRequires:	motif-devel}
-BuildRequires:	t1lib-devel >= 1.3.0
 Suggests:	ghostscript-fonts-std
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
@@ -111,11 +105,6 @@
 %setup -q
 %{!?with_protections:%patch0 -p1}
 %patch1 -p1
-%patch2 -p1
-%patch3 -p1
-%patch4 -p1
-%patch5 -p1
-%patch6 -p1
 
 %build
 %{__autoconf}
@@ -160,18 +149,30 @@
 %defattr(644,root,root,755)
 %doc ANNOUNCE CHANGES README
 %attr(755,root,root) %{_bindir}/xpdf
-%config(noreplace,missingok) %verify(not md5 mtime size) %{_sysconfdir}/*
+%config(noreplace,missingok) %verify(not md5 mtime size) %{_sysconfdir}/xpdfrc
 %{_datadir}/xpdf
 %{_mandir}/man1/xpdf.1*
 %{_mandir}/man5/xpdfrc.5*
-%{_desktopdir}/*.desktop
-%{_pixmapsdir}/*
+%{_desktopdir}/xpdf.desktop
+%{_pixmapsdir}/xpdf.png
 %endif
 
 %files tools
 %defattr(644,root,root,755)
-%attr(755,root,root) %{_bindir}/pdf*
-%{_mandir}/man1/pdf*
+%attr(755,root,root) %{_bindir}/pdfdetach
+%attr(755,root,root) %{_bindir}/pdffonts
+%attr(755,root,root) %{_bindir}/pdfimages
+%attr(755,root,root) %{_bindir}/pdfinfo
+%attr(755,root,root) %{_bindir}/pdftoppm
+%attr(755,root,root) %{_bindir}/pdftops
+%attr(755,root,root) %{_bindir}/pdftotext
+%{_mandir}/man1/pdfdetach.1*
+%{_mandir}/man1/pdffonts.1*
+%{_mandir}/man1/pdfimages.1*
+%{_mandir}/man1/pdfinfo.1*
+%{_mandir}/man1/pdftoppm.1*
+%{_mandir}/man1/pdftops.1*
+%{_mandir}/man1/pdftotext.1*
 
 %define date	%(echo `LC_ALL="C" date +"%a %b %d %Y"`)
 %changelog
@@ -179,6 +180,12 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.125  2011/08/21 06:54:06  qboosh
+- updated to 3.03
+- updated remove_protections,fontdirs patches
+- updated License (GPL v2 or v3 now)
+- no longer uses external t1lib (caused security problems)
+
 Revision 1.124  2011/01/29 00:08:10  sparky
 - dropped pre-cvs changelog
 
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/xpdf/xpdf-fontdirs.patch?r1=1.1&r2=1.2&f=u
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/xpdf/xpdf-remove_protections.patch?r1=1.7&r2=1.8&f=u
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/xpdf/xpdf.spec?r1=1.124&r2=1.125&f=u



More information about the pld-cvs-commit mailing list