mirror of
https://git.FreeBSD.org/ports.git
synced 2024-10-30 21:49:25 +00:00
e466c33aa6
PR: 19622 Submitted by: Ports Fury
39 lines
1.4 KiB
Plaintext
39 lines
1.4 KiB
Plaintext
--- ppm/ppmtobmp.c.orig Sat Jul 1 03:00:34 2000
|
|
+++ ppm/ppmtobmp.c Sat Jul 1 12:00:00 2000
|
|
@@ -51,6 +51,7 @@
|
|
#include "ppm.h"
|
|
#include "ppmcmap.h"
|
|
#include "bitio.h"
|
|
+#include "shhopt.h"
|
|
|
|
#define MAXCOLORS 256
|
|
|
|
@@ -93,16 +94,26 @@
|
|
opt.short_allowed = FALSE; /* We have no short (old-fashioned) options */
|
|
opt.allowNegNum = FALSE; /* We have no parms that are negative numbers */
|
|
|
|
+ /* 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('w', "windows", OPT_FLAG, &windows, 0);
|
|
OPTENTRY('o', "os2", OPT_FLAG, &os2, 0);
|
|
OPTENTRY(0, "bpp", OPT_UINT, &bpp, 0);
|
|
+ option_def[option_def_index].type = OPT_END;
|
|
|
|
/* Set the defaults */
|
|
windows = os2 = FALSE;
|
|
bpp = -1;
|
|
|
|
- pm_optParseOptions2(&argc, argv, opt, 0);
|
|
+ optParseOptions2(&argc, argv, opt, 0);
|
|
/* Uses and sets argc, and argv */
|
|
|
|
if (argc - 1 == 0)
|