2000-05-21 08:41:19 +00:00
|
|
|
--- pbmplus.h.orig Mon May 8 05:00:47 2000
|
|
|
|
+++ pbmplus.h Sat May 20 00:00:00 2000
|
2000-05-19 08:34:13 +00:00
|
|
|
@@ -25,6 +25,9 @@
|
1999-01-07 11:12:30 +00:00
|
|
|
#include <errno.h>
|
|
|
|
#endif
|
2000-04-01 23:57:38 +00:00
|
|
|
#endif
|
1999-01-07 11:12:30 +00:00
|
|
|
+#if (defined(__unix__) || defined(unix)) && !defined(USG)
|
|
|
|
+#include <sys/param.h>
|
|
|
|
+#endif
|
|
|
|
|
2000-04-01 23:57:38 +00:00
|
|
|
#if defined(USG) || defined(SVR4) || defined(VMS) || defined(__SVR4)
|
1999-01-07 11:12:30 +00:00
|
|
|
#define SYSV
|
2000-05-19 08:34:13 +00:00
|
|
|
@@ -35,7 +38,7 @@
|
1999-01-07 11:12:30 +00:00
|
|
|
** and if you run on an Amiga, set AMIGA. If your compiler is ANSI C, you're
|
|
|
|
** probably better off setting SYSV - all it affects is string handling.
|
|
|
|
*/
|
|
|
|
-#define BSD
|
2000-04-01 23:57:38 +00:00
|
|
|
+/* #define BSD */
|
1999-01-07 11:12:30 +00:00
|
|
|
/* #define SYSV */
|
|
|
|
/* #define MSDOS */
|
|
|
|
/* #define AMIGA */
|
2000-05-21 08:41:19 +00:00
|
|
|
@@ -54,7 +57,7 @@
|
|
|
|
#define RGB_DB1 "PBMplus_Dir:RGB.TXT"
|
|
|
|
#define RGB_DB2 "PBMplus_Dir:RGB.TXT"
|
|
|
|
#else
|
2000-05-19 08:34:13 +00:00
|
|
|
-#define RGB_DB1 "/usr/lib/X11/rgb.txt"
|
|
|
|
+#define RGB_DB1 "%%X11BASE%%/lib/X11/rgb.txt"
|
|
|
|
#define RGB_DB2 "/usr/openwin/lib/rgb.txt"
|
2000-05-21 08:41:19 +00:00
|
|
|
#endif
|
|
|
|
|
|
|
|
@@ -285,37 +288,6 @@
|
2000-05-19 08:34:13 +00:00
|
|
|
int pm_writelittleshort ARGS(( FILE* out, short s ));
|
2000-04-27 11:28:19 +00:00
|
|
|
int pm_readlittlelong ARGS(( FILE* in, long* lP ));
|
|
|
|
int pm_writelittlelong ARGS(( FILE* out, long l ));
|
|
|
|
-
|
2000-05-19 08:34:13 +00:00
|
|
|
-/* By making this <> instead of "", we avoid making shhopt.h a dependency
|
|
|
|
- of every program in the package when we do make dep.
|
2000-04-27 11:28:19 +00:00
|
|
|
-*/
|
2000-05-19 08:34:13 +00:00
|
|
|
-#include <shhopt.h>
|
2000-04-27 11:28:19 +00:00
|
|
|
-
|
|
|
|
-void pm_optParseOptions(int *argc, char *argv[],
|
|
|
|
- optStruct opt[], int allowNegNum);
|
|
|
|
-/* Use pm_optParseOptions instead of optParseOptions in order to use the
|
|
|
|
- shared Netpbm libraries
|
|
|
|
-*/
|
|
|
|
-
|
|
|
|
-/* You can use OPTENTRY to assign a value to a dynamically or automatically
|
|
|
|
- allocated optStruct structure with minimal typing and easy readability.
|
|
|
|
-
|
|
|
|
- Here is an example:
|
|
|
|
-
|
|
|
|
- unsigned int option_def_index = 0;
|
|
|
|
- optStruct *option_def = malloc(100*sizeof(optStruct));
|
|
|
|
- OPTENTRY('h', "help", OPT_FLAG, &help_flag, 0);
|
|
|
|
- OPTENTRY(0, "alphaout", OPT_STRING, &alpha_filename, 0);
|
|
|
|
-*/
|
|
|
|
-
|
|
|
|
-#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[++option_def_index].type = OPT_END; \
|
|
|
|
- }
|
|
|
|
|
|
|
|
/* Compatibility stuff */
|
1999-01-07 11:12:30 +00:00
|
|
|
|