[arch-commits] Commit in xfig/trunk (3 files)

Eric Bélanger eric at archlinux.org
Sun Nov 28 02:40:08 UTC 2010


    Date: Saturday, November 27, 2010 @ 21:40:08
  Author: eric
Revision: 101110

upgpkg: xfig 3.2.5b-5
Fixed eps importing (close FS#21848), Updated url, Removed force option, Remove ChangeLog

Added:
  xfig/trunk/xfig-3.2.5b-fix-eps-reading.patch
Modified:
  xfig/trunk/PKGBUILD
Deleted:
  xfig/trunk/ChangeLog

-----------------------------------+
 ChangeLog                         |   44 ----------------------------------
 PKGBUILD                          |   46 ++++++++++++++++++++----------------
 xfig-3.2.5b-fix-eps-reading.patch |   46 ++++++++++++++++++++++++++++++++++++
 3 files changed, 72 insertions(+), 64 deletions(-)

Deleted: ChangeLog
===================================================================
--- ChangeLog	2010-11-28 01:50:25 UTC (rev 101109)
+++ ChangeLog	2010-11-28 02:40:08 UTC (rev 101110)
@@ -1,44 +0,0 @@
-2010-05-26  Jan de Groot  <jgc at archlinux.org>
-
-	* xfig 3.2.5b-4
-	* Rebuilt for libpng 1.4.2 - png_set_dither has been renamed
-
-2010-01-27  Eric Belanger  <eric at archlinux.org>
-
-	* xfig 3.2.5b-3
-	* Rebuilt for libpng 1.4 and libjpeg 8
-
-2010-01-11  Eric Belanger  <eric at archlinux.org>
-
-	* xfig 3.2.5b-2
-	* Added gsfonts depends (close FS#17200)
-
-2009-08-13  Eric Belanger  <eric at archlinux.org>
-
-	* xfig 3.2.5b-1
-	* Upstream update
-	* Improved description
-	* Updated and cleaned up patches
-	* Fixed files and directory permissions
-	* Added force option
-
-2009-07-01  Eric Belanger  <eric at archlinux.org>
-
-	* xfig 3.2.5-3
-	* Rebuilt against libjpeg 7
-
-2009-05-15  Jan de Groot  <jgc at archlinux.org>
-
-	* xfig 3.2.5-2
-	* Rebuild without libxp
-	* Remove libxaw dependency
-
-2008-12-14  Eric Belanger  <eric at archlinux.org>
-
-	* xfig 3.2.5-1
-	* Upstream update
-	* Added transfig optdepends
-	* Improved .desktop file
-	* Added patches to fix several issues including fonts (close FS#8806)
-	* Cleaned up PKGBUILD
-	* Added ChangeLog

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2010-11-28 01:50:25 UTC (rev 101109)
+++ PKGBUILD	2010-11-28 02:40:08 UTC (rev 101110)
@@ -1,49 +1,55 @@
 # $Id$
 # Maintainer: Eric Belanger <eric at archlinux.org>
-# Contributor: Ben <ben at benmazer.net>
 
 pkgname=xfig
 pkgver=3.2.5b
-pkgrel=4
+pkgrel=5
 pkgdesc="An interactive drawing tool"
 arch=('i686' 'x86_64')
-url="http://www.xfig.org"
+url="http://www.xfig.org/userman/"
 license=('custom')
 depends=('libpng' 'libjpeg' 'xaw3d' 'libxi' 'desktop-file-utils' 'gsfonts')
 makedepends=('imake')
 optdepends=('transfig: to use the frontend to convert fig files')
-options=('!makeflags' '!emptydirs' 'force')
+options=('!makeflags' '!emptydirs')
 install=xfig.install
 source=(http://downloads.sourceforge.net/mcj/${pkgname}.${pkgver}.full.tar.gz \
 	xfig-3.2.4-redhat.patch xfig-3.2.5-color-resources.patch \
         xfig-3.2.5-enable-Xaw3d.patch xfig-3.2.5-urwfonts.patch \
         xfig-3.2.5-fhs.patch xfig-3.2.5-missing-protos.patch \
-        xfig.3.2.5-modularX.patch LICENSE xfig.desktop)
+        xfig.3.2.5-modularX.patch xfig-3.2.5b-fix-eps-reading.patch LICENSE xfig.desktop)
 md5sums=('499b0ce103a6b353453bf7e327f9a3b9' '5c2bc208c8ee852bc9ffa00dcbfd8241'\
          'a4b91e4aaf48ed07f4a579a1f692ef82' '46c6fb15d26c9fe03e558bdacc0b0a53'\
          'c5b7dc054063f02c6bfcd132dae82b6f' 'b532871c792716465e3b05967bcfba10'\
          'de059a6b8ce287942c7da35d19ee46f3' '7347389f7fdecd582579845df0c0b664'\
-         'f405b7a96f3401c12153fe6170a7d8f1' '8ac2de637c9148aa4a32978910822230')
+         'fa14e85b5365d07ca8deca9ea47d4e6a' 'f405b7a96f3401c12153fe6170a7d8f1'\
+         '8ac2de637c9148aa4a32978910822230')
 sha1sums=('0730d7e6bc217c0de02682efb0078821512bb542' '926ad99c7221baa4aa9e9737722958860b2700fc'\
          'b7c03fb70066ff476a4039a8c0f8930c15edef68' '33bff26b42ce164e79de11808b5b34b363f0d59f'\
          'e595ccdbe293ea0fdecbf59a2192ae57ced2c8eb' '39bec6bac9746b643b05fd1286826113ede07ff6'\
          'bd76cd50be6a5789cfd6f182309cfd7056be04f3' 'a1285f4e61ad2eec040460ab03e8022098e7f78e'\
-         '31edf4cfab708820ea3f114d095dfef5aa88e5aa' '9011b8fa6143e37525b28cc9800a3bf2d6b008d2')
+         '12a64ddaf65a73e23ef74f31483515a0e262768c' '31edf4cfab708820ea3f114d095dfef5aa88e5aa'\
+         '9011b8fa6143e37525b28cc9800a3bf2d6b008d2')
 
 build() {
   cd "${srcdir}/${pkgname}.${pkgver}"
-  patch -p1 < ../xfig-3.2.4-redhat.patch || return 1
-  patch -p1 < ../xfig-3.2.5-fhs.patch || return 1
-  patch -p1 < ../xfig.3.2.5-modularX.patch || return 1
-  patch -p1 < ../xfig-3.2.5-enable-Xaw3d.patch || return 1
-  patch -p1 < ../xfig-3.2.5-color-resources.patch || return 1
-  patch -p1 < ../xfig-3.2.5-urwfonts.patch || return 1
-  patch -p1 < ../xfig-3.2.5-missing-protos.patch || return 1
+  patch -p1 < ../xfig-3.2.4-redhat.patch
+  patch -p1 < ../xfig-3.2.5-fhs.patch
+  patch -p1 < ../xfig.3.2.5-modularX.patch
+  patch -p1 < ../xfig-3.2.5-enable-Xaw3d.patch
+  patch -p1 < ../xfig-3.2.5-color-resources.patch
+  patch -p1 < ../xfig-3.2.5-urwfonts.patch
+  patch -p1 < ../xfig-3.2.5-missing-protos.patch
+  patch -p1 < ../xfig-3.2.5b-fix-eps-reading.patch
   chmod 755 Libraries
 
-  xmkmf || return 1
-  make DOCDIR=/usr/share/doc || return 1
-  make DESTDIR="${pkgdir}" DOCDIR=/usr/share/doc install.all || return 1
+  xmkmf
+  make DOCDIR=/usr/share/doc
+}
+
+package() {
+  cd "${srcdir}/${pkgname}.${pkgver}"
+  make DESTDIR="${pkgdir}" DOCDIR=/usr/share/doc install.all
   rm "${pkgdir}/usr/lib/X11/app-defaults"
 
   find "${pkgdir}/usr/share/xfig/Libraries" -type f -exec chmod 0644 {} \;
@@ -51,7 +57,7 @@
   find "${pkgdir}/usr/share/doc/xfig" -type f -exec chmod 0644 {} \;
   find "${pkgdir}/usr/share/doc/xfig" -type d -exec chmod 0755 {} \;
 
-  install -D -m644 ../xfig.desktop "${pkgdir}/usr/share/applications/xfig.desktop" || return 1
-  install -D -m644 xfig.png  "${pkgdir}/usr/share/pixmaps/xfig.png" || return 1
-  install -D -m644 ../LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE" || return 1	
+  install -D -m644 ../xfig.desktop "${pkgdir}/usr/share/applications/xfig.desktop"
+  install -D -m644 xfig.png  "${pkgdir}/usr/share/pixmaps/xfig.png"
+  install -D -m644 ../LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"	
 }

Added: xfig-3.2.5b-fix-eps-reading.patch
===================================================================
--- xfig-3.2.5b-fix-eps-reading.patch	                        (rev 0)
+++ xfig-3.2.5b-fix-eps-reading.patch	2010-11-28 02:40:08 UTC (rev 101110)
@@ -0,0 +1,46 @@
+diff -ur xfig.3.2.5b/f_readeps.c xfig.3.2.5b.new/f_readeps.c
+--- xfig.3.2.5b/f_readeps.c	2009-03-30 17:52:18.000000000 +0200
++++ xfig.3.2.5b.new/f_readeps.c	2010-11-25 16:53:54.328247928 +0100
+@@ -252,12 +252,13 @@
+ {
+     char        buf[300];
+     FILE       *tmpfp, *pixfile, *gsfile;
+-    char       *psnam, *driver;
++    char       *driver;
+     int         status, wid, ht, nbitmap, fd;
+     char        tmpfile[PATH_MAX],
+ 		pixnam[PATH_MAX],
+ 		errnam[PATH_MAX],
+-		gscom[2 * PATH_MAX];
++		gscom[2 * PATH_MAX],
++		psnam[PATH_MAX];
+ 
+     wid = urx - llx;
+     ht = ury - lly;
+@@ -307,19 +308,14 @@
+ 	/* for color, use pcx */
+ 	driver = "pcx256";
+     }
+-    /* avoid absolute paths (for Cygwin with gswin32) by changing directory */
+-    if (tmpfile[0] == '/') {
+-	psnam = strrchr(tmpfile, '/');
+-	*psnam = 0;
+-	sprintf(gscom, "cd \"%s/\";", tmpfile);
+-	*psnam++ = '/';		/* Restore name for unlink() below */
+-    } else {
+-	psnam = tmpfile;
+-	gscom[0] = '\0';
++    /* Canonicalize the eps file filename, needed to "defeat" -dSAFER */
++    if (!realpath(tmpfile, psnam)) {
++	file_msg("Cannot canonicalize %s: %s\n", tmpfile, strerror(errno));
++	return False;
+     }
+-    sprintf(&gscom[strlen(gscom)],
+-	    "%s -r72x72 -dSAFER -sDEVICE=%s -g%dx%d -sOutputFile=%s -q - > %s 2>&1",
+-	    appres.ghostscript, driver, wid, ht, pixnam, errnam);
++    sprintf(gscom,
++	    "%s -r72x72 -sDEVICE=%s -g%dx%d -sOutputFile=%s -dDELAYSAFER -c '<< /PermitFileReading [ (%s)] >> setuserparams .locksafe' -dSAFER -q - > %s 2>&1",
++	    appres.ghostscript, driver, wid, ht, pixnam, psnam, errnam);
+     if (appres.DEBUG)
+ 	fprintf(stderr,"calling: %s\n",gscom);
+     if ((gsfile = popen(gscom, "w")) == 0) {




More information about the arch-commits mailing list