New package: netpbm-10.66.03
This commit is contained in:
parent
f86babcec4
commit
dc7045ec36
5 changed files with 2099 additions and 0 deletions
15
srcpkgs/netpbm/files/config.mk
Normal file
15
srcpkgs/netpbm/files/config.mk
Normal file
|
@ -0,0 +1,15 @@
|
|||
DEFAULT_TARGET = nonmerge
|
||||
NETPBMLIBTYPE=unixshared
|
||||
NETPBMLIBSUFFIX=so
|
||||
STATICLIB_TOO=N
|
||||
CFLAGS = -O3 -ffast-math -pedantic -fno-common -Wall -Wno-uninitialized -Wmissing-declarations -Wimplicit -Wwrite-strings -Wmissing-prototypes -Wundef -Wno-unknown-pragmas
|
||||
CFLAGS_MERGE = -Wno-missing-declarations -Wno-missing-prototypes
|
||||
LDRELOC = ld --reloc
|
||||
LINKER_CAN_DO_EXPLICIT_LIBRARY=Y
|
||||
LINKERISCOMPILER = N
|
||||
CFLAGS_SHLIB += -fPIC
|
||||
TIFFLIB = libtiff.so
|
||||
JPEGLIB = libjpeg.so
|
||||
ZLIB = libz.so
|
||||
NETPBM_DOCURL = http://netpbm.sourceforge.net/doc/
|
||||
WANT_SSE = Y
|
16
srcpkgs/netpbm/patches/netpbm-CAN-2005-2471.patch
Normal file
16
srcpkgs/netpbm/patches/netpbm-CAN-2005-2471.patch
Normal file
|
@ -0,0 +1,16 @@
|
|||
--- converter/other/pstopnm.c.CAN-2005-2471 2005-08-15 02:39:46.000000000 +0200
|
||||
+++ converter/other/pstopnm.c 2005-08-16 15:38:15.000000000 +0200
|
||||
@@ -711,11 +711,11 @@
|
||||
ghostscriptProg, arg0,
|
||||
deviceopt, outfileopt, gopt, ropt, textalphabitsopt,
|
||||
"-q", "-dNOPAUSE",
|
||||
- "-dSAFER", "-");
|
||||
+ "-dPARANOIDSAFER", "-");
|
||||
}
|
||||
|
||||
execl(ghostscriptProg, arg0, deviceopt, outfileopt, gopt, ropt, "-q",
|
||||
- "-dNOPAUSE", "-dSAFER", "-", NULL);
|
||||
+ "-dNOPAUSE", "-dPARANOIDSAFER", "-", NULL);
|
||||
|
||||
pm_error("execl() of Ghostscript ('%s') failed, errno=%d (%s)",
|
||||
ghostscriptProg, errno, strerror(errno));
|
1660
srcpkgs/netpbm/patches/netpbm-security-code.patch
Normal file
1660
srcpkgs/netpbm/patches/netpbm-security-code.patch
Normal file
File diff suppressed because it is too large
Load diff
373
srcpkgs/netpbm/patches/netpbm-security-scripts.patch
Normal file
373
srcpkgs/netpbm/patches/netpbm-security-scripts.patch
Normal file
|
@ -0,0 +1,373 @@
|
|||
diff -up converter/other/anytopnm.security-scripts converter/other/anytopnm
|
||||
--- converter/other/anytopnm.security-scripts 2009-12-10 08:34:36.000000000 +0100
|
||||
+++ converter/other/anytopnm 2010-03-16 21:28:09.000000000 +0100
|
||||
@@ -510,10 +510,7 @@ else
|
||||
inputFile="-"
|
||||
fi
|
||||
|
||||
-tempdir="${TMPDIR-/tmp}/anytopnm.$$"
|
||||
-mkdir -m 0700 $tempdir || \
|
||||
- { echo "Could not create temporary file. Exiting."; exit 1;}
|
||||
-trap 'rm -rf $tempdir' 0
|
||||
+tempdir=$(mktemp -d -t anytopnm.XXXXXXXXXX) || exit 1
|
||||
|
||||
# Take out all spaces
|
||||
# Find the filename extension for last-ditch efforts later
|
||||
@@ -539,9 +536,17 @@ if [ "$filetype" = "unknown" ]; then
|
||||
echo "$progname: unknown file type. " \
|
||||
"'file' says mime type is '$mimeType', " 1>&2
|
||||
echo "type description is '$typeDescription'" 1>&2
|
||||
+ if [ -d "$tempdir" ] ; then
|
||||
+ rm -rf "$tempdir"
|
||||
+ fi
|
||||
+
|
||||
exit 1
|
||||
fi
|
||||
|
||||
convertIt $file $filetype
|
||||
|
||||
+if [ -d "$tempdir" ] ; then
|
||||
+ rm -rf "$tempdir"
|
||||
+fi
|
||||
+
|
||||
exit 0
|
||||
diff -up editor/pamstretch-gen.security-scripts editor/pamstretch-gen
|
||||
--- editor/pamstretch-gen.security-scripts 2009-12-10 08:34:32.000000000 +0100
|
||||
+++ editor/pamstretch-gen 2010-03-16 21:28:47.000000000 +0100
|
||||
@@ -31,13 +31,9 @@ if [ "$1" = "" ]; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
-tempdir="${TMPDIR-/tmp}/pamstretch-gen.$$"
|
||||
-mkdir -m 0700 $tempdir || \
|
||||
- { echo "Could not create temporary file. Exiting."; exit 1;}
|
||||
+tempfile=$(mktemp /tmp/pnmig.XXXXXXXXXX) || exit 1
|
||||
trap 'rm -rf $tempdir' 0 1 3 15
|
||||
|
||||
-tempfile=$tempdir/pnmig
|
||||
-
|
||||
if ! cat $2 >$tempfile 2>/dev/null; then
|
||||
echo 'pamstretch-gen: error reading file' 1>&2
|
||||
exit 1
|
||||
diff -up editor/pnmmargin.security-scripts editor/pnmmargin
|
||||
--- editor/pnmmargin.security-scripts 2009-12-10 08:34:32.000000000 +0100
|
||||
+++ editor/pnmmargin 2010-03-16 21:28:09.000000000 +0100
|
||||
@@ -11,15 +11,11 @@
|
||||
# documentation. This software is provided "as is" without express or
|
||||
# implied warranty.
|
||||
|
||||
-tempdir="${TMPDIR-/tmp}/pnmmargin.$$"
|
||||
-mkdir -m 0700 $tempdir || \
|
||||
- { echo "Could not create temporary file. Exiting." 1>&2; exit 1;}
|
||||
-trap 'rm -rf $tempdir' 0 1 3 15
|
||||
-
|
||||
-tmp1=$tempdir/pnmm1
|
||||
-tmp2=$tempdir/pnmm2
|
||||
-tmp3=$tempdir/pnmm3
|
||||
-tmp4=$tempdir/pnmm4
|
||||
+tmpdir=$(mktemp -d -t ppmmargin.XXXXXXX) || exit 1
|
||||
+tmp1="$tmpdir/tmp1"
|
||||
+tmp2="$tmpdir/tmp2"
|
||||
+tmp3="$tmpdir/tmp3"
|
||||
+tmp4="$tmpdir/tmp4"
|
||||
|
||||
color="-gofigure"
|
||||
plainopt=""
|
||||
@@ -90,6 +86,7 @@ else
|
||||
-white | -black )
|
||||
pnmpad $plainopt $color \
|
||||
-left=$size -right=$size -top=$size -bottom=$size $tmp1
|
||||
+ rm -rf "$tmpdir"
|
||||
exit
|
||||
;;
|
||||
* )
|
||||
diff -up editor/ppmfade.security-scripts editor/ppmfade
|
||||
--- editor/ppmfade.security-scripts 2009-12-10 08:34:32.000000000 +0100
|
||||
+++ editor/ppmfade 2010-03-16 21:28:09.000000000 +0100
|
||||
@@ -14,6 +14,7 @@
|
||||
#
|
||||
#-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
|
||||
use strict;
|
||||
+use File::Temp "tempdir";
|
||||
|
||||
my $SPREAD = 1;
|
||||
my $SHIFT = 2;
|
||||
@@ -111,20 +112,26 @@ if ($first_file ne "undefined") {
|
||||
|
||||
print("Frames are " . $width . "W x " . $height . "H\n");
|
||||
|
||||
+#
|
||||
+# We create a tmp-directory right here
|
||||
+#
|
||||
+my $tmpdir = tempdir("ppmfade.XXXXXX", CLEANUP => 1);
|
||||
+
|
||||
+
|
||||
if ($first_file eq "undefined") {
|
||||
print "Fading from black to ";
|
||||
- system("ppmmake \\#000 $width $height >junk1$$.ppm");
|
||||
+ system("ppmmake \\#000 $width $height >$tmpdir/junk1$$.ppm");
|
||||
} else {
|
||||
print "Fading from $first_file to ";
|
||||
- system("cp", $first_file, "junk1$$.ppm");
|
||||
+ system("cp", $first_file, "$tmpdir/junk1$$.ppm");
|
||||
}
|
||||
|
||||
if ($last_file eq "undefined") {
|
||||
print "black.\n";
|
||||
- system("ppmmake \\#000 $width $height >junk2$$.ppm");
|
||||
+ system("ppmmake \\#000 $width $height >$tmpdir/junk2$$.ppm");
|
||||
} else {
|
||||
print "$last_file\n";
|
||||
- system("cp", $last_file, "junk2$$.ppm");
|
||||
+ system("cp", $last_file, "$tmpdir/junk2$$.ppm");
|
||||
}
|
||||
|
||||
#
|
||||
@@ -132,14 +139,14 @@ if ($last_file eq "undefined") {
|
||||
#
|
||||
|
||||
# Here's what our temporary files are:
|
||||
-# junk1$$.ppm: The original (fade-from) image
|
||||
-# junk2$$.ppm: The target (fade-from) image
|
||||
-# junk3$$.ppm: The frame of the fade for the current iteration of the
|
||||
-# the for loop.
|
||||
-# junk1a$$.ppm: If the fade involves a ppmmix sequence from one intermediate
|
||||
-# image to another, this is the first frame of that
|
||||
-# sequence.
|
||||
-# junk2a$$.ppm: This is the last frame of the above-mentioned ppmmix sequence
|
||||
+# $tmpdir/junk1$$.ppm: The original (fade-from) image
|
||||
+# $tmpdir/junk2$$.ppm: The target (fade-from) image
|
||||
+# $tmpdir/junk3$$.ppm: The frame of the fade for the current iteration of the
|
||||
+# the for loop.
|
||||
+# $tmpdir/junk1a$$.ppm: If the fade involves a ppmmix sequence from one intermediate
|
||||
+# image to another, this is the first frame of that
|
||||
+# sequence.
|
||||
+# $tmpdir/junk2a$$.ppm: This is the last frame of the above-mentioned ppmmix sequence
|
||||
|
||||
my $i; # Frame number
|
||||
for ($i = 1; $i <= $nframes; $i++) {
|
||||
@@ -147,147 +154,147 @@ for ($i = 1; $i <= $nframes; $i++) {
|
||||
if ($mode eq $SPREAD) {
|
||||
if ($i <= 10) {
|
||||
my $n = $spline20[$i] * 100;
|
||||
- system("ppmspread $n junk1$$.ppm >junk3$$.ppm");
|
||||
+ system("ppmspread $n $tmpdir/junk1$$.ppm >$tmpdir/junk3$$.ppm");
|
||||
} elsif ($i <= 20) {
|
||||
my $n;
|
||||
$n = $spline20[$i] * 100;
|
||||
- system("ppmspread $n junk1$$.ppm >junk1a$$.ppm");
|
||||
+ system("ppmspread $n $tmpdir/junk1$$.ppm >$tmpdir/junk1a$$.ppm");
|
||||
$n = (1-$spline20[$i-10]) * 100;
|
||||
- system("ppmspread $n junk2$$.ppm >junk2a$$.ppm");
|
||||
+ system("ppmspread $n $tmpdir/junk2$$.ppm >$tmpdir/junk2a$$.ppm");
|
||||
$n = $spline10[$i-10];
|
||||
- system("ppmmix $n junk1a$$.ppm junk2a$$.ppm >junk3$$.ppm");
|
||||
+ system("ppmmix $n $tmpdir/junk1a$$.ppm $tmpdir/junk2a$$.ppm >$tmpdir/junk3$$.ppm");
|
||||
} else {
|
||||
my $n = (1-$spline20[$i-10])*100;
|
||||
- system("ppmspread $n junk2$$.ppm >junk3$$.ppm");
|
||||
+ system("ppmspread $n $tmpdir/junk2$$.ppm >$tmpdir/junk3$$.ppm");
|
||||
}
|
||||
} elsif ($mode eq $SHIFT) {
|
||||
if ($i <= 10) {
|
||||
my $n = $spline20[$i] * 100;
|
||||
- system("ppmshift $n junk1$$.ppm >junk3$$.ppm");
|
||||
+ system("ppmshift $n $tmpdir/junk1$$.ppm >$tmpdir/junk3$$.ppm");
|
||||
} elsif ($i <= 20) {
|
||||
my $n;
|
||||
$n = $spline20[$i] * 100;
|
||||
- system("ppmshift $n junk1$$.ppm >junk1a$$.ppm");
|
||||
+ system("ppmshift $n $tmpdir/junk1$$.ppm >$tmpdir/junk1a$$.ppm");
|
||||
$n = (1-$spline20[$i-10])*100;
|
||||
- system("ppmshift $n junk2$$.ppm >junk2a$$.ppm");
|
||||
+ system("ppmshift $n $tmpdir/junk2$$.ppm >$tmpdir/junk2a$$.ppm");
|
||||
$n = $spline10[$i-10];
|
||||
- system("ppmmix $n junk1a$$.ppm junk2a$$.ppm >junk3$$.ppm");
|
||||
+ system("ppmmix $n $tmpdir/junk1a$$.ppm $tmpdir/junk2a$$.ppm >$tmpdir/junk3$$.ppm");
|
||||
} else {
|
||||
my $n = (1-$spline20[$i-10]) * 100;
|
||||
- system("ppmshift $n junk2$$.ppm >junk3$$.ppm");
|
||||
+ system("ppmshift $n $tmpdir/junk2$$.ppm >$tmpdir/junk3$$.ppm");
|
||||
}
|
||||
} elsif ($mode eq $RELIEF) {
|
||||
if ($i == 1) {
|
||||
- system("ppmrelief junk1$$.ppm >junk1r$$.ppm");
|
||||
+ system("ppmrelief $tmpdir/junk1$$.ppm >$tmpdir/junk1r$$.ppm");
|
||||
}
|
||||
if ($i <= 10) {
|
||||
my $n = $spline10[$i];
|
||||
- system("ppmmix $n junk1$$.ppm junk1r$$.ppm >junk3$$.ppm");
|
||||
+ system("ppmmix $n $tmpdir/junk1$$.ppm $tmpdir/junk1r$$.ppm >$tmpdir/junk3$$.ppm");
|
||||
} elsif ($i <= 20) {
|
||||
my $n = $spline10[$i-10];
|
||||
- system("ppmmix $n junk1r$$.ppm junk2r$$.ppm >junk3$$.ppm");
|
||||
+ system("ppmmix $n $tmpdir/junk1r$$.ppm $tmpdir/junk2r$$.ppm >$tmpdir/junk3$$.ppm");
|
||||
} else {
|
||||
my $n = $spline10[$i-20];
|
||||
- system("ppmmix $n junk2r$$.ppm junk2$$.ppm >junk3$$.ppm");
|
||||
+ system("ppmmix $n $tmpdir/junk2r$$.ppm $tmpdir/junk2$$.ppm >$tmpdir/junk3$$.ppm");
|
||||
}
|
||||
if ($i == 10) {
|
||||
- system("ppmrelief junk2$$.ppm >junk2r$$.ppm");
|
||||
+ system("ppmrelief $tmpdir/junk2$$.ppm >$tmpdir/junk2r$$.ppm");
|
||||
}
|
||||
} elsif ($mode eq $OIL) {
|
||||
if ($i == 1) {
|
||||
- system("ppmtopgm junk1$$.ppm | pgmoil >junko$$.ppm");
|
||||
- system("rgb3toppm junko$$.ppm junko$$.ppm junko$$.ppm " .
|
||||
- ">junk1o$$.ppm");
|
||||
+ system("ppmtopgm $tmpdir/junk1$$.ppm | pgmoil >$tmpdir/junko$$.ppm");
|
||||
+ system("rgb3toppm $tmpdir/junko$$.ppm $tmpdir/junko$$.ppm $tmpdir/junko$$.ppm " .
|
||||
+ ">$tmpdir/junk1o$$.ppm");
|
||||
}
|
||||
if ($i <= 10) {
|
||||
my $n = $spline10[$i];
|
||||
- system("ppmmix $n junk1$$.ppm junk1o$$.ppm >junk3$$.ppm");
|
||||
+ system("ppmmix $n $tmpdir/junk1$$.ppm $tmpdir/junk1o$$.ppm >$tmpdir/junk3$$.ppm");
|
||||
} elsif ($i <= 20) {
|
||||
my $n = $spline10[$i-10];
|
||||
- system("ppmmix $n junk1o$$.ppm junk2o$$.ppm >junk3$$.ppm");
|
||||
+ system("ppmmix $n $tmpdir/junk1o$$.ppm $tmpdir/junk2o$$.ppm >$tmpdir/junk3$$.ppm");
|
||||
} else {
|
||||
my $n = $spline10[$i-20];
|
||||
- system("ppmmix $n junk2o$$.ppm junk2$$.ppm >junk3$$.ppm");
|
||||
+ system("ppmmix $n $tmpdir/junk2o$$.ppm $tmpdir/junk2$$.ppm >$tmpdir/junk3$$.ppm");
|
||||
}
|
||||
if ($i == 10) {
|
||||
- system("ppmtopgm junk2$$.ppm | pgmoil >junko$$.ppm");
|
||||
- system("rgb3toppm junko$$.ppm junko$$.ppm junko$$.ppm " .
|
||||
- ">junk2o$$.ppm");
|
||||
+ system("ppmtopgm $tmpdir/junk2$$.ppm | pgmoil >$tmpdir/junko$$.ppm");
|
||||
+ system("rgb3toppm $tmpdir/junko$$.ppm $tmpdir/junko$$.ppm $tmpdir/junko$$.ppm " .
|
||||
+ ">$tmpdir/junk2o$$.ppm");
|
||||
}
|
||||
} elsif ($mode eq $EDGE) {
|
||||
if ($i == 1) {
|
||||
- system("ppmtopgm junk1$$.ppm | pgmedge >junko$$.ppm");
|
||||
- system("rgb3toppm junko$$.ppm junko$$.ppm junko$$.ppm " .
|
||||
- ">junk1o$$.ppm");
|
||||
+ system("ppmtopgm $tmpdir/junk1$$.ppm | pgmedge >$tmpdir/junko$$.ppm");
|
||||
+ system("rgb3toppm $tmpdir/junko$$.ppm $tmpdir/junko$$.ppm $tmpdir/junko$$.ppm " .
|
||||
+ ">$tmpdir/junk1o$$.ppm");
|
||||
}
|
||||
if ($i <= 10) {
|
||||
my $n = $spline10[$i];
|
||||
- system("ppmmix $n junk1$$.ppm junk1o$$.ppm >junk3$$.ppm");
|
||||
+ system("ppmmix $n $tmpdir/junk1$$.ppm $tmpdir/junk1o$$.ppm >$tmpdir/junk3$$.ppm");
|
||||
} elsif ($i <= 20) {
|
||||
my $n = $spline10[$i-10];
|
||||
- system("ppmmix $n junk1o$$.ppm junk2o$$.ppm >junk3$$.ppm");
|
||||
+ system("ppmmix $n $tmpdir/junk1o$$.ppm $tmpdir/junk2o$$.ppm >$tmpdir/junk3$$.ppm");
|
||||
} else {
|
||||
my $n = $spline10[$i-20];
|
||||
- system("ppmmix $n junk2o$$.ppm junk2$$.ppm >junk3$$.ppm");
|
||||
+ system("ppmmix $n $tmpdir/junk2o$$.ppm $tmpdir/junk2$$.ppm >$tmpdir/junk3$$.ppm");
|
||||
}
|
||||
if ($i == 10) {
|
||||
- system("ppmtopgm junk2$$.ppm | pgmedge >junko$$.ppm");
|
||||
- system("rgb3toppm junko$$.ppm junko$$.ppm junko$$.ppm " .
|
||||
- ">junk2o$$.ppm");
|
||||
+ system("ppmtopgm $tmpdir/junk2$$.ppm | pgmedge >$tmpdir/junko$$.ppm");
|
||||
+ system("rgb3toppm $tmpdir/junko$$.ppm $tmpdir/junko$$.ppm $tmpdir/junko$$.ppm " .
|
||||
+ ">$tmpdir/junk2o$$.ppm");
|
||||
}
|
||||
} elsif ($mode eq $BENTLEY) {
|
||||
if ($i == 1) {
|
||||
- system("ppmtopgm junk1$$.ppm | pgmbentley >junko$$.ppm");
|
||||
- system("rgb3toppm junko$$.ppm junko$$.ppm junko$$.ppm " .
|
||||
- ">junk1o$$.ppm");
|
||||
+ system("ppmtopgm $tmpdir/junk1$$.ppm | pgmbentley >$tmpdir/junko$$.ppm");
|
||||
+ system("rgb3toppm $tmpdir/junko$$.ppm $tmpdir/junko$$.ppm $tmpdir/junko$$.ppm " .
|
||||
+ ">$tmpdir/junk1o$$.ppm");
|
||||
}
|
||||
if ($i <= 10) {
|
||||
my $n = $spline10[$i];
|
||||
- system("ppmmix $n junk1$$.ppm junk1o$$.ppm >junk3$$.ppm");
|
||||
+ system("ppmmix $n $tmpdir/junk1$$.ppm $tmpdir/junk1o$$.ppm >$tmpdir/junk3$$.ppm");
|
||||
} elsif ($i <= 20) {
|
||||
my $n = $spline10[$i-10];
|
||||
- system("ppmmix $n junk1o$$.ppm junk2o$$.ppm >junk3$$.ppm");
|
||||
+ system("ppmmix $n $tmpdir/junk1o$$.ppm $tmpdir/junk2o$$.ppm >$tmpdir/junk3$$.ppm");
|
||||
} else {
|
||||
my $n = $spline10[$i-20];
|
||||
- system("ppmmix $n junk2o$$.ppm junk2$$.ppm >junk3$$.ppm");
|
||||
+ system("ppmmix $n $tmpdir/junk2o$$.ppm $tmpdir/junk2$$.ppm >$tmpdir/junk3$$.ppm");
|
||||
}
|
||||
if ($i == 10) {
|
||||
- system("ppmtopgm junk2$$.ppm | pgmbentley >junko$$.ppm");
|
||||
- system("rgb3toppm junko$$.ppm junko$$.ppm junko$$.ppm " .
|
||||
- ">junk2o$$.ppm");
|
||||
+ system("ppmtopgm $tmpdir/junk2$$.ppm | pgmbentley >$tmpdir/junko$$.ppm");
|
||||
+ system("rgb3toppm $tmpdir/junko$$.ppm $tmpdir/junko$$.ppm $tmpdir/junko$$.ppm " .
|
||||
+ ">$tmpdir/junk2o$$.ppm");
|
||||
}
|
||||
} elsif ($mode eq $BLOCK) {
|
||||
if ($i <= 10) {
|
||||
my $n = 1 - 1.9*$spline20[$i];
|
||||
- system("pamscale $n junk1$$.ppm | " .
|
||||
- "pamscale -width $width -height $height >junk3$$.ppm");
|
||||
+ system("pamscale $n $tmpdir/junk1$$.ppm | " .
|
||||
+ "pamscale -width $width -height $height >$tmpdir/junk3$$.ppm");
|
||||
} elsif ($i <= 20) {
|
||||
my $n = $spline10[$i-10];
|
||||
- system("ppmmix $n junk1a$$.ppm junk2a$$.ppm >junk3$$.ppm");
|
||||
+ system("ppmmix $n $tmpdir/junk1a$$.ppm $tmpdir/junk2a$$.ppm >$tmpdir/junk3$$.ppm");
|
||||
} else {
|
||||
my $n = 1 - 1.9*$spline20[31-$i];
|
||||
- system("pamscale $n junk2$$.ppm | " .
|
||||
- "pamscale -width $width -height $height >junk3$$.ppm");
|
||||
+ system("pamscale $n $tmpdir/junk2$$.ppm | " .
|
||||
+ "pamscale -width $width -height $height >$tmpdir/junk3$$.ppm");
|
||||
}
|
||||
if ($i == 10) {
|
||||
- system("cp", "junk3$$.ppm", "junk1a$$.ppm");
|
||||
- system("pamscale $n junk2$$.ppm | " .
|
||||
- "pamscale -width $width -height $height >junk2a$$.ppm");
|
||||
+ system("cp", "$tmpdir/junk3$$.ppm", "$tmpdir/junk1a$$.ppm");
|
||||
+ system("pamscale $n $tmpdir/junk2$$.ppm | " .
|
||||
+ "pamscale -width $width -height $height >$tmpdir/junk2a$$.ppm");
|
||||
}
|
||||
} elsif ($mode eq $MIX) {
|
||||
my $fade_factor = sqrt(1/($nframes-$i+1));
|
||||
- system("ppmmix $fade_factor junk1$$.ppm junk2$$.ppm >junk3$$.ppm");
|
||||
+ system("ppmmix $fade_factor $tmpdir/junk1$$.ppm $tmpdir/junk2$$.ppm >$tmpdir/junk3$$.ppm");
|
||||
} else {
|
||||
print("Internal error: impossible mode value '$mode'\n");
|
||||
}
|
||||
|
||||
my $outfile = sprintf("%s.%04d.ppm", $base_name, $i);
|
||||
- system("cp", "junk3$$.ppm", $outfile);
|
||||
+ system("cp", "$tmpdir/junk3$$.ppm", $outfile);
|
||||
}
|
||||
|
||||
#
|
||||
# Clean up shop.
|
||||
#
|
||||
-system("rm junk*$$.ppm");
|
||||
+system("rm $tmpdir/junk*$$.ppm");
|
||||
|
||||
exit(0);
|
||||
diff -up editor/ppmshadow.security-scripts editor/ppmshadow
|
||||
--- editor/ppmshadow.security-scripts 2009-12-10 08:34:32.000000000 +0100
|
||||
+++ editor/ppmshadow 2010-03-16 21:28:09.000000000 +0100
|
||||
@@ -72,9 +72,10 @@ sub makeConvolutionKernel($$) {
|
||||
|
||||
|
||||
my $tmpdir = $ENV{TMPDIR} || "/tmp";
|
||||
-my $ourtmp = "$tmpdir/ppmshadow$$";
|
||||
-mkdir($ourtmp, 0777) or
|
||||
- die("Unable to create directory for temporary files '$ourtmp");
|
||||
+my $ourtmp; chomp($ourtmp = `mktemp -d -t PPMshadow.XXXXXX`);
|
||||
+if ($? >> 8) {
|
||||
+ die "Can't create directory for temporary files";
|
||||
+}
|
||||
|
||||
# Process command line options
|
||||
|
||||
--- editor/pnmmargin.orig 2014-06-16 21:30:27.480812666 -0400
|
||||
+++ editor/pnmmargin 2014-06-16 21:30:41.500789921 -0400
|
||||
@@ -101,3 +101,4 @@
|
||||
fi
|
||||
|
||||
|
||||
+rm -rf "$tmpdir"
|
35
srcpkgs/netpbm/template
Normal file
35
srcpkgs/netpbm/template
Normal file
|
@ -0,0 +1,35 @@
|
|||
# Template file for 'netpbm'
|
||||
pkgname=netpbm
|
||||
version=10.66.03
|
||||
revision=1
|
||||
wrksrc=advanced
|
||||
makedepends="pkg-config perl python flex libjpeg-turbo-devel tiff-devel libpng-devel zlib-devel libxml2-devel libX11-devel"
|
||||
depends=""
|
||||
short_desc="Toolkit for manipulation of graphic images"
|
||||
maintainer="Christian Neukirchen <chneukirchen@gmail.com>"
|
||||
license="BSD,GPL,LGPL,custom"
|
||||
homepage="http://netpbm.sourceforge.net/"
|
||||
distfiles="ftp://ftp.archlinux.org/other/packages/$pkgname/$pkgname-$version.tar.xz
|
||||
ftp://ftp.archlinux.org/other/packages/$pkgname/$pkgname-doc-31Jan2014.tar.xz"
|
||||
checksum="705551823155dcfebdb6b914447769a62eefd7157efd1dae925b36fb7cc647b1
|
||||
74bcf840ee643c6917330c382484010cb99c004a3fcf05391bebcac63815acb3"
|
||||
|
||||
do_configure() {
|
||||
cat config.mk.in ${FILESDIR}/config.mk >config.mk
|
||||
sed -i 's|/link|/lib|' lib/Makefile
|
||||
sed -i 's|install.manwebmain install.manweb install.man|install.man|' GNUmakefile
|
||||
}
|
||||
|
||||
do_build() {
|
||||
make ${makejobs}
|
||||
make MAKEMAN="${PWD}/buildtools/makeman" USERGUIDE=. \
|
||||
-C ../doc -f "${PWD}/buildtools/manpage.mk" manpages
|
||||
}
|
||||
|
||||
do_install() {
|
||||
make pkgdir=$DESTDIR/usr PKGMANDIR=share/man install-run install-dev
|
||||
rm $DESTDIR/usr/share/man/man?/*
|
||||
make MAKEMAN="${PWD}/buildtools/makeman" MANDIR="$DESTDIR/usr/share/man" \
|
||||
-C ../doc -f "${PWD}/buildtools/manpage.mk" installman
|
||||
vinstall doc/copyright_summary 644 usr/share/licenses/$pkgname
|
||||
}
|
Loading…
Reference in a new issue