update to 10.73.33 [release 10.73.33-1mamba;Sun Nov 29 2020]
This commit is contained in:
parent
31c2edcaa1
commit
602171403d
@ -1,16 +1,16 @@
|
||||
--- netpbm-10.29/converter/other/pstopnm.c.CAN-2005-2471 2005-08-15 02:39:46.000000000 +0200
|
||||
+++ netpbm-10.29/converter/other/pstopnm.c 2005-08-16 15:38:15.000000000 +0200
|
||||
@@ -711,11 +711,11 @@
|
||||
"'%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s'",
|
||||
@@ -818,11 +818,11 @@
|
||||
ghostscriptProg, arg0,
|
||||
deviceopt, outfileopt, gopt, ropt, "-q", "-dNOPAUSE",
|
||||
deviceopt, outfileopt, gopt, ropt, textalphabitsopt,
|
||||
"-q", "-dNOPAUSE",
|
||||
- "-dSAFER", "-");
|
||||
+ "-dPARANOIDSAFER", "-");
|
||||
}
|
||||
|
||||
execl(ghostscriptProg, arg0, deviceopt, outfileopt, gopt, ropt, "-q",
|
||||
- "-dNOPAUSE", "-dSAFER", "-", NULL);
|
||||
+ "-dNOPAUSE", "-dPARANOIDSAFER", "-", NULL);
|
||||
execl(ghostscriptProg, arg0, deviceopt, outfileopt, gopt, ropt,
|
||||
- textalphabitsopt, "-q", "-dNOPAUSE", "-dSAFER", "-", NULL);
|
||||
+ textalphabitsopt, "-q", "-dNOPAUSE", "-dPARANOIDSAFER", "-", NULL);
|
||||
|
||||
pm_error("execl() of Ghostscript ('%s') failed, errno=%d (%s)",
|
||||
ghostscriptProg, errno, strerror(errno));
|
16
netpbm-10.73.33-reproducible-man-gzip.patch
Normal file
16
netpbm-10.73.33-reproducible-man-gzip.patch
Normal file
@ -0,0 +1,16 @@
|
||||
diff -aur netpbm-10.73.31.old/buildtools/manpage.mk netpbm-10.73.31/buildtools/manpage.mk
|
||||
--- netpbm-10.73.31.old/buildtools/manpage.mk 2020-05-28 18:41:20.400790506 +0200
|
||||
+++ netpbm-10.73.31/buildtools/manpage.mk 2020-05-28 18:50:50.444143414 +0200
|
||||
@@ -388,9 +388,9 @@
|
||||
# This will install the generated man pages
|
||||
installman:
|
||||
set -x
|
||||
- for f in netpbm.1 $(MAN1); do if [ -f $$f ]; then gzip <$$f >$(MANDIR)/man1/$$f.gz; fi; done
|
||||
- for f in $(MAN3); do if [ -f $$f ]; then gzip <$$f >$(MANDIR)/man3/$$f.gz; fi; done
|
||||
- for f in $(MAN5); do if [ -f $$f ]; then gzip <$$f >$(MANDIR)/man5/$$f.gz; fi; done
|
||||
+ for f in netpbm.1 $(MAN1); do if [ -f $$f ]; then gzip -n <$$f >$(MANDIR)/man1/$$f.gz; fi; done
|
||||
+ for f in $(MAN3); do if [ -f $$f ]; then gzip -n <$$f >$(MANDIR)/man3/$$f.gz; fi; done
|
||||
+ for f in $(MAN5); do if [ -f $$f ]; then gzip -n <$$f >$(MANDIR)/man5/$$f.gz; fi; done
|
||||
|
||||
# This will uninstall them
|
||||
uninstallman:
|
1432
netpbm-10.73.33-security-code.patch
Normal file
1432
netpbm-10.73.33-security-code.patch
Normal file
File diff suppressed because it is too large
Load Diff
369
netpbm-10.73.33-security-scripts.patch
Normal file
369
netpbm-10.73.33-security-scripts.patch
Normal file
@ -0,0 +1,369 @@
|
||||
diff --git a/converter/other/anytopnm b/converter/other/anytopnm
|
||||
index acf8813..335312a 100755
|
||||
--- a/converter/other/anytopnm
|
||||
+++ b/converter/other/anytopnm
|
||||
@@ -511,10 +511,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
|
||||
@@ -537,12 +534,17 @@ typeDescription=`file "$file" | cut -d: -f2- | cut -c2-`
|
||||
determineType "$file" "$mimeType" "$typeDescription" "$fileExtension"
|
||||
|
||||
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 --git a/editor/pamstretch-gen b/editor/pamstretch-gen
|
||||
index ba0e818..250fca0 100755
|
||||
--- a/editor/pamstretch-gen
|
||||
+++ b/editor/pamstretch-gen
|
||||
@@ -31,9 +31,7 @@ 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
|
||||
diff --git a/editor/pnmmargin b/editor/pnmmargin
|
||||
index 0f57d1d..e0d3625 100755
|
||||
--- a/editor/pnmmargin
|
||||
+++ b/editor/pnmmargin
|
||||
@@ -11,11 +11,7 @@
|
||||
# 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
|
||||
-
|
||||
+tempdir=$(mktemp -d -t ppmmargin.XXXXXXX) || exit 1
|
||||
tmp1=$tempdir/pnmm1
|
||||
tmp2=$tempdir/pnmm2
|
||||
tmp3=$tempdir/pnmm3
|
||||
@@ -90,6 +86,7 @@ else
|
||||
-white | -black )
|
||||
pnmpad $plainopt $color \
|
||||
-left=$size -right=$size -top=$size -bottom=$size $tmp1
|
||||
+ rm -rf "$tempdir"
|
||||
exit
|
||||
;;
|
||||
* )
|
||||
@@ -103,4 +100,4 @@ else
|
||||
pnmcat -tb $plainopt $tmp3 $tmp4 $tmp3
|
||||
fi
|
||||
|
||||
-
|
||||
+rm -rf "$tempdir"
|
||||
diff --git a/editor/ppmfade b/editor/ppmfade
|
||||
index 027fc79..8eb094f 100755
|
||||
--- a/editor/ppmfade
|
||||
+++ b/editor/ppmfade
|
||||
@@ -40,6 +40,7 @@ exec perl -w -x -S -- "$0" "$@"
|
||||
#
|
||||
##############################################################################
|
||||
use strict;
|
||||
+use File::Temp "tempdir";
|
||||
|
||||
my $SPREAD = 1;
|
||||
my $SHIFT = 2;
|
||||
@@ -137,20 +138,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");
|
||||
}
|
||||
|
||||
#
|
||||
@@ -158,14 +165,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++) {
|
||||
@@ -173,147 +180,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 --git a/editor/ppmshadow b/editor/ppmshadow
|
||||
index 62cdf8b..72e1b22 100755
|
||||
--- a/editor/ppmshadow
|
||||
+++ b/editor/ppmshadow
|
||||
@@ -97,9 +97,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
|
||||
|
||||
|
122
netpbm.spec
122
netpbm.spec
@ -1,5 +1,5 @@
|
||||
Name: netpbm
|
||||
Version: 10.61.02
|
||||
Version: 10.73.33
|
||||
Release: 1mamba
|
||||
Summary: Tools for manipulating graphics files in netpbm supported formats
|
||||
Group: Applications/Multimedia
|
||||
@ -7,20 +7,23 @@ Vendor: openmamba
|
||||
Distribution: openmamba
|
||||
Packager: Silvan Calarco <silvan.calarco@mambasoft.it>
|
||||
URL: http://netpbm.sourceforge.net
|
||||
Source0: https://downloads.sourceforge.net/project/netpbm/super_stable/%{version}/netpbm-%{version}.tgz
|
||||
#Source: http://www12.frugalware.org/mirrors/ftp.frugalware.org/pub/other/sources/netpbm/netpbm-%{version}.tar.bz2
|
||||
#Source0: http://downloads.sourceforge.net/project/netpbm/super_stable/%{version}/netpbm-%{version}.tgz
|
||||
Source: http://archlinux.c3sl.ufpr.br/other/packages/netpbm/netpbm-%{version}.tar.gz
|
||||
Source1: %{name}-docs-20030520.tar.bz2
|
||||
#Source: http://archlinux.c3sl.ufpr.br/other/packages/netpbm/netpbm-%{version}.tar.xz
|
||||
Source1: https://sources.archlinux.org/other/packages/netpbm/netpbm-doc-31Jan2014.tar.xz
|
||||
Source2: %{name}-10.51.00-config.mk
|
||||
Patch0: %{name}-10.15-make.patch
|
||||
Patch1: %{name}-10.30-manpath.patch
|
||||
Patch2: %{name}-10.22-security_mktemp.patch
|
||||
Patch3: %{name}-10.23-security-rh.patch
|
||||
Patch4: %{name}-10.27-bmptopnm.patch
|
||||
Patch5: %{name}-10.28-CAN-2005-2471.patch
|
||||
Patch5: %{name}-10.73.33-CAN-2005-2471.patch
|
||||
Patch6: %{name}-10.28-gcc4.patch
|
||||
Patch7: %{name}-10.20-CAN-2005-2978.patch
|
||||
Patch8: %{name}-10.30-pamtofits.patch
|
||||
Patch9: netpbm-10.73.33-security-code.patch
|
||||
Patch10: netpbm-10.73.33-security-scripts.patch
|
||||
Patch11: netpbm-10.73.33-reproducible-man-gzip.patch
|
||||
License: Freeware
|
||||
## AUTOBUILDREQ-BEGIN
|
||||
BuildRequires: glibc-devel
|
||||
@ -83,31 +86,36 @@ Examples of the sort of image manipulation we're talking about are:
|
||||
|
||||
This package contains static libraries and header files need for development.
|
||||
|
||||
#% debug_package
|
||||
|
||||
%prep
|
||||
%setup -q -c -a1 -n netpbm-%{version}
|
||||
%setup -q -a1
|
||||
%patch5 -p1
|
||||
%patch9 -p1
|
||||
%patch10 -p1
|
||||
%patch11 -p1
|
||||
|
||||
mv advanced/* .
|
||||
rmdir advanced
|
||||
cp config.mk.in config.mk
|
||||
|
||||
%patch0 -p1
|
||||
#%patch1 -p1 -b .manpath
|
||||
#%patch2 -p1 -b .security_mktemp
|
||||
#%patch3 -p1 -b .security_rh
|
||||
#%patch4 -p1 -b .bmptopnm
|
||||
#%patch5 -p1 -b .can_2005_2471
|
||||
%patch6 -p1 -b .gcc4
|
||||
#%patch7 -p1 -b .can_2005_2978
|
||||
#%patch8 -p1 -b .pamtofits
|
||||
#install -m0644 %{SOURCE2} ./config.mk
|
||||
#sed -i "s|CC =.*|CC = %{_host}-gcc|" config.mk
|
||||
#%if "%{stage1}" == "1"
|
||||
#sed -i "s|X11LIB =.*|X11LIB = NONE|" config.mk
|
||||
#%endif
|
||||
|
||||
install -m0644 %{SOURCE2} ./config.mk
|
||||
sed -i "s|CC =.*|CC = %{_host}-gcc|" config.mk
|
||||
%if "%{stage1}" == "1"
|
||||
sed -i "s|X11LIB =.*|X11LIB = NONE|" config.mk
|
||||
%ifarch x86_64 aarch64
|
||||
echo 'CFLAGS_SHLIB = -fPIC' >> config.mk
|
||||
%endif
|
||||
echo "NETPBM_DOCURL = file://${PWD}/doc" >> config.mk
|
||||
echo 'TIFFLIB = libtiff.so' >> config.mk
|
||||
echo 'JPEGLIB = libjpeg.so' >> config.mk
|
||||
echo 'PNGLIB = libpng.so' >> config.mk
|
||||
echo 'ZLIB = libz.so' >> config.mk
|
||||
echo 'JBIGLIB = /usr/lib/libjbig.a' >> config.mk
|
||||
|
||||
# fix strange permissions
|
||||
find netpbm.sourceforge.net -type d | xargs chmod 755
|
||||
find netpbm.sourceforge.net -type f | xargs chmod 644
|
||||
sed -i 's|misc|share/netpbm|' common.mk
|
||||
sed -i 's|/link|/lib|' lib/Makefile
|
||||
sed -i 's|install.manwebmain install.manweb install.man|install.man|' GNUmakefile
|
||||
|
||||
%build
|
||||
#%if "%{_host}" != "%{_build}"
|
||||
@ -115,20 +123,43 @@ find netpbm.sourceforge.net -type f | xargs chmod 644
|
||||
#sed -i "s|libpng-config|-lpng14|" converter/other/Makefile
|
||||
#%endif
|
||||
|
||||
%make \
|
||||
CFLAGS="%{optflags} -fPIC" -j1 \
|
||||
CC=%{_host}-gcc \
|
||||
LINUXSVGALIB=NONE \
|
||||
%if "%{stage1}" != "1"
|
||||
X11LIB=%{_libdir}/libX11.so \
|
||||
%else
|
||||
X11LIB=NONE \
|
||||
%endif
|
||||
NETPBM_DOCURL=%{_datadir}/doc/%{name}-%{version}/netpbm.sourceforge.net/doc
|
||||
%make
|
||||
#\
|
||||
# CFLAGS="%{optflags} -fPIC" -j1 \
|
||||
# CC=%{_host}-gcc \
|
||||
# LINUXSVGALIB=NONE \
|
||||
#%if "%{stage1}" != "1"
|
||||
# X11LIB=%{_libdir}/libX11.so \
|
||||
#%else
|
||||
# X11LIB=NONE \
|
||||
#%endif
|
||||
# NETPBM_DOCURL=%{_datadir}/doc/%{name}-%{version}/netpbm.sourceforge.net/doc
|
||||
|
||||
# Generating useful man pages with html doc
|
||||
make MAKEMAN="${PWD}/buildtools/makeman" USERGUIDE=. \
|
||||
-C doc -f "${PWD}/buildtools/manpage.mk" manpages
|
||||
|
||||
%install
|
||||
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
|
||||
install -d %{buildroot}
|
||||
|
||||
make pkgdir=%{buildroot}%{_prefix} PKGMANDIR=share/man install-run install-dev
|
||||
|
||||
# Removing dummy man pages
|
||||
rm %{buildroot}%{_mandir}/man{1,3,5}/*
|
||||
|
||||
make MAKEMAN=${PWD}/buildtools/makeman MANDIR=%{buildroot}%{_mandir} \
|
||||
-C doc -f ${PWD}/buildtools/manpage.mk installman
|
||||
|
||||
%ifarch x86_64 aarch64
|
||||
mv %{buildroot}%{_prefix}/lib %{buildroot}%{_libdir}
|
||||
rm -f %{buildroot}%{_libdir}/libnetpbm.so
|
||||
ln -s libnetpbm.so.11 %{buildroot}%{_libdir}/libnetpbm.so
|
||||
%endif
|
||||
|
||||
# Replace obsolete utility
|
||||
echo -e '#!/bin/sh\npamditherbw $@ | pamtopnm\n' > %{buildroot}%{_bindir}/pgmtopbm
|
||||
|
||||
:<< __OBSOLETE
|
||||
make package \
|
||||
pkgdir=%{buildroot}%{_prefix} \
|
||||
STRIPFLAG="" \
|
||||
@ -141,9 +172,6 @@ make package \
|
||||
%endif
|
||||
NETPBM_DOCURL=%{_datadir}/doc/%{name}-%{version}/netpbm.sourceforge.net/doc
|
||||
|
||||
%ifarch x86_64
|
||||
mv %{buildroot}%{_prefix}/lib %{buildroot}%{_libdir}
|
||||
%endif
|
||||
|
||||
mv %{buildroot}%{_prefix}/link/libnetpbm.a %{buildroot}%{_libdir}
|
||||
mv %{buildroot}%{_prefix}/misc/*.map %{buildroot}%{_libdir}
|
||||
@ -167,25 +195,29 @@ rm %{buildroot}%{_prefix}/config_template
|
||||
|
||||
%files
|
||||
%defattr(-,root,root,-)
|
||||
%attr(755,root,root) %{_bindir}/*
|
||||
%{_bindir}/*
|
||||
%dir %{_datadir}/netpbm
|
||||
%{_datadir}/netpbm/*
|
||||
%{_mandir}/man[15]/*
|
||||
|
||||
%files -n libnetpbm
|
||||
%defattr(-,root,root,-)
|
||||
%{_libdir}/libnetpbm.so.*
|
||||
%{_libdir}/*.map
|
||||
%{_mandir}/man[15]/*
|
||||
%doc README doc/COPYRIGHT.PATENT
|
||||
%doc doc/COPYRIGHT.PATENT
|
||||
|
||||
%files -n libnetpbm-devel
|
||||
%defattr(-,root,root,-)
|
||||
%attr(644,root,root) %{_libdir}/libnetpbm.a
|
||||
%attr(755,root,root) %{_libdir}/libnetpbm.so
|
||||
%{_includedir}/*
|
||||
%{_libdir}/libnetpbm.a
|
||||
%{_libdir}/libnetpbm.so
|
||||
%{_mandir}/man3/*
|
||||
%doc README doc/{HISTORY,USERDOC}
|
||||
%doc netpbm.sourceforge.net
|
||||
#%doc netpbm.sourceforge.net
|
||||
|
||||
%changelog
|
||||
* Sun Nov 29 2020 Silvan Calarco <silvan.calarco@mambasoft.it> 10.73.33-1mamba
|
||||
- update to 10.73.33
|
||||
|
||||
* Fri Jul 26 2013 Automatic Build System <autodist@mambasoft.it> 10.61.02-1mamba
|
||||
- update to 10.61.02
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user