summaryrefslogtreecommitdiff
path: root/graphics/netpbm/files/patch-cp
diff options
context:
space:
mode:
Diffstat (limited to 'graphics/netpbm/files/patch-cp')
-rw-r--r--graphics/netpbm/files/patch-cp42
1 files changed, 42 insertions, 0 deletions
diff --git a/graphics/netpbm/files/patch-cp b/graphics/netpbm/files/patch-cp
new file mode 100644
index 000000000000..969b3aa50f03
--- /dev/null
+++ b/graphics/netpbm/files/patch-cp
@@ -0,0 +1,42 @@
+--- ppm/ppmtogif.c.orig Sat Dec 16 16:34:16 2000
++++ ppm/ppmtogif.c Sat Jan 13 00:00:00 2001
+@@ -22,6 +22,7 @@
+
+ #include "ppm.h"
+ #include "ppmcmap.h"
++#include "shhopt.h"
+
+ #define MAXCOLORS 256
+
+@@ -91,12 +92,22 @@
+
+ unsigned int option_def_index;
+
++ /* Create the OptStruct structure describing our options */
++ #define OPTENTRY(shortvalue,longvalue,typevalue,outputvalue,flagvalue) {\
++ option_def[option_def_index].shortName = (shortvalue); \
++ option_def[option_def_index].longName = (longvalue); \
++ option_def[option_def_index].type = (typevalue); \
++ option_def[option_def_index].arg = (outputvalue); \
++ option_def[option_def_index].flags = (flagvalue); \
++ option_def_index++; \
++ }
+ option_def_index = 0; /* incremented by OPTENTRY */
+ OPTENTRY(0, "interlace", OPT_FLAG, &cmdline_p->interlace, 0);
+ OPTENTRY(0, "sort", OPT_FLAG, &cmdline_p->sort, 0);
+ OPTENTRY(0, "mapfile", OPT_STRING, &cmdline_p->mapfile, 0);
+ OPTENTRY(0, "transparent", OPT_STRING, &cmdline_p->transparent, 0);
+ OPTENTRY(0, "comment", OPT_STRING, &cmdline_p->comment, 0);
++ option_def[option_def_index].type = OPT_END;
+
+ /* Set the defaults */
+ cmdline_p->interlace = FALSE;
+@@ -109,7 +120,7 @@
+ opt.short_allowed = FALSE; /* We have no short (old-fashioned) options */
+ opt.allowNegNum = FALSE; /* We may have parms that are negative numbers */
+
+- pm_optParseOptions2(&argc, argv, opt, 0);
++ optParseOptions2(&argc, argv, opt, 0);
+ /* Uses and sets argc, argv, and some of *cmdline_p and others. */
+
+ if (argc-1 == 0)