summaryrefslogtreecommitdiff
path: root/graphics
diff options
context:
space:
mode:
authorobache <obache>2011-09-04 08:54:02 +0000
committerobache <obache>2011-09-04 08:54:02 +0000
commit4a84cca9ad4f02f9fcfde2ecb95f12727eccd776 (patch)
tree015648b3124db8c34ac502555c83620f16c4d269 /graphics
parent4147f357fe3515777b346309a03ef48ae5243501 (diff)
downloadpkgsrc-4a84cca9ad4f02f9fcfde2ecb95f12727eccd776.tar.gz
* Add a patch for CVE-2008-4935, based on Debian's fix, adjust mktemp(1)
behavior differ between OpenBSD orign and FreeBSD one. * Add some missing includion of header files. * LICENSE=gnu-gpl-v2 Bump PKGREVISION.
Diffstat (limited to 'graphics')
-rw-r--r--graphics/aview/Makefile6
-rw-r--r--graphics/aview/distinfo5
-rw-r--r--graphics/aview/patches/patch-asciiview51
-rw-r--r--graphics/aview/patches/patch-flip.c14
-rw-r--r--graphics/aview/patches/patch-main.c13
5 files changed, 86 insertions, 3 deletions
diff --git a/graphics/aview/Makefile b/graphics/aview/Makefile
index 868270ed114..213962343ff 100644
--- a/graphics/aview/Makefile
+++ b/graphics/aview/Makefile
@@ -1,15 +1,16 @@
-# $NetBSD: Makefile,v 1.25 2011/01/13 13:37:56 wiz Exp $
+# $NetBSD: Makefile,v 1.26 2011/09/04 08:54:02 obache Exp $
#
DISTNAME= aview-1.3.0rc1
PKGNAME= aview-1.3.0.1
-PKGREVISION= 11
+PKGREVISION= 12
CATEGORIES= graphics converters
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=aa-project/}
MAINTAINER= salo@Xtrmntr.org
HOMEPAGE= http://aa-project.sourceforge.net/aview/
COMMENT= ASCII Art image viewer
+LICENSE= gnu-gpl-v2
PKG_DESTDIR_SUPPORT= user-destdir
@@ -20,6 +21,7 @@ PLIST_SRC= ${WRKDIR}/PLIST
WRKSRC= ${WRKDIR}/aview-1.3.0
GNU_CONFIGURE= yes
USE_LIBTOOL= yes
+USE_TOOLS+= mktemp:run
.include "../../mk/bsd.prefs.mk"
diff --git a/graphics/aview/distinfo b/graphics/aview/distinfo
index 70bb8b73551..4f3aa752881 100644
--- a/graphics/aview/distinfo
+++ b/graphics/aview/distinfo
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.4 2006/03/09 14:50:31 ghen Exp $
+$NetBSD: distinfo,v 1.5 2011/09/04 08:54:02 obache Exp $
SHA1 (aview-1.3.0rc1.tar.gz) = d757ff9f62e6ce4d926c03ae4f4096d9fcf353fc
RMD160 (aview-1.3.0rc1.tar.gz) = f57808dfb9efc36af3b4107bfd48ae875d709cd0
@@ -6,3 +6,6 @@ Size (aview-1.3.0rc1.tar.gz) = 54317 bytes
SHA1 (patch-aa) = 4fb90e608e912839a3febef1b7086909eb93d42a
SHA1 (patch-ac) = c9a66a3e6bf97dffe7335ccb9af666250d25f370
SHA1 (patch-ad) = 690a8af07eee1e44611b9111678ab1aff52c7bfa
+SHA1 (patch-asciiview) = 0049ca64f6ae513ca8a5253ae866223664440dcd
+SHA1 (patch-flip.c) = b5f82621ab97bab76b62225341f316c93a1c0a19
+SHA1 (patch-main.c) = c1bbd21abf0955efe3b24a90f51e9fa57a4954c2
diff --git a/graphics/aview/patches/patch-asciiview b/graphics/aview/patches/patch-asciiview
new file mode 100644
index 00000000000..6b014137915
--- /dev/null
+++ b/graphics/aview/patches/patch-asciiview
@@ -0,0 +1,51 @@
+$NetBSD: patch-asciiview,v 1.1 2011/09/04 08:54:03 obache Exp $
+
+* CVE-2008-4935
+* some space-in-the-path fixes
+
+--- asciiview.orig 2011-09-02 14:12:10.000000000 +0000
++++ asciiview
+@@ -3,13 +3,13 @@
+ clear()
+ {
+ kill $! 2>/dev/null
+- rm -f /tmp/aview$$.pgm 2>/dev/null
++ rm -rf $tmpdir 2>/dev/null
+ }
+ myconvert()
+ {
+- if anytopnm $1 >/tmp/aview$$.pgm 2>/dev/null ; then
++ if anytopnm "$1" > "$2" 2>/dev/null ; then
+ exit
+- elif convert -colorspace gray $1 pgm:- 2>/dev/null ; then
++ elif convert -colorspace gray "$1" pgm:- 2>/dev/null ; then
+ exit
+ fi
+ echo "Failed to convert file format to PNM by both convert and anytopnm" >&2
+@@ -51,20 +51,21 @@ while [ "$1" != "" ]; do
+ esac
+ done
+ trap clear 0
+-mkfifo /tmp/aview$$.pgm
+-outfile=/tmp/aview$$.pgm
++tmpdir=`mktemp -d -t aview.XXXXXX`
++outfile=$tmpdir/aview.pgm
++mkfifo $outfile
+ for name in $filenames ; do
+ if test -r $name ; then
+ case $name in
+ *.fli | *.lfc | *.flic )
+ PATH="$PATH:."
+- aaflip $options $name
++ aaflip $options "$name"
+ ;;
+ *)
+- myconvert $name >/tmp/aview$$.pgm &
++ myconvert "$name" "$outfile" >"$outfile" &
+ pid=$!
+ PATH="$PATH:."
+- aview $options /tmp/aview$$.pgm
++ aview $options $outfile
+ kill $pid 2>/dev/null
+ esac
+ else
diff --git a/graphics/aview/patches/patch-flip.c b/graphics/aview/patches/patch-flip.c
new file mode 100644
index 00000000000..0b7ee0a3446
--- /dev/null
+++ b/graphics/aview/patches/patch-flip.c
@@ -0,0 +1,14 @@
+$NetBSD: patch-flip.c,v 1.1 2011/09/04 08:54:03 obache Exp $
+
+* include <string.h> for memcpy(3), and so on.
+
+--- flip.c.orig 2001-04-25 15:48:59.000000000 +0000
++++ flip.c
+@@ -7,6 +7,7 @@
+
+ #include <stdlib.h>
+ #include <stdio.h>
++#include <string.h>
+ #include <sys/time.h>
+ #include <unistd.h>
+ #include <aalib.h>
diff --git a/graphics/aview/patches/patch-main.c b/graphics/aview/patches/patch-main.c
new file mode 100644
index 00000000000..636ee7b46a5
--- /dev/null
+++ b/graphics/aview/patches/patch-main.c
@@ -0,0 +1,13 @@
+$NetBSD: patch-main.c,v 1.1 2011/09/04 08:54:03 obache Exp $
+
+* include <stdlib.h> for exit(3).
+* include <string.h> for strncpy(3).
+
+--- main.c.orig 2001-04-25 16:00:06.000000000 +0000
++++ main.c
+@@ -1,3 +1,5 @@
++#include <stdlib.h>
++#include <string.h>
+ #include <aalib.h>
+ #include "image.h"
+ #include "ui.h"