#include <afsconfig.h>
#include <afs/param.h>
+#include <roken.h>
#include <limits.h>
-#include <stdio.h>
-#include <stdlib.h>
#include <ctype.h>
-#include <string.h>
-#ifdef HAVE_SIGNAL_H
-#include <signal.h>
-#endif
-#ifdef HAVE_SYS_FILE_H
-#include <sys/file.h>
-#endif
-#ifdef HAVE_UNISTD_H
-#include <unistd.h>
-#endif
+
#include "rpc_scan.h"
#include "rpc_parse.h"
#include "rpc_util.h"
struct commandline {
int ansic_flag;
+ int brief_flag;
int cflag;
int hflag;
int lflag;
char OutFile[256];
char Sflag = 0, Cflag = 0, hflag = 0, cflag = 0, kflag = 0, uflag = 0;
char ansic_flag = 0; /* If set, build ANSI C style prototypes */
+char brief_flag = 0; /* If set, shorten names */
char zflag = 0; /* If set, abort server stub if rpc call returns non-zero */
char xflag = 0; /* if set, add stats code to stubs */
char yflag = 0; /* if set, only emit function name arrays to xdr file */
if (!parseargs(argc, argv, &cmd)) {
f_print(stderr, "usage: %s infile\n", cmdname);
f_print(stderr,
- " %s [-c | -h | -l | -m | -C | -S | -r | -k | -R | -p | -d | -z | -u] [-Pprefix] [-Idir] [-o outfile] [infile]\n",
+ " %s [-c | -h | -l | -m | -C | -S | -r | -b | -k | -R | -p | -d | -z | -u] [-Pprefix] [-Idir] [-o outfile] [infile]\n",
cmdname);
f_print(stderr, " %s [-s udp|tcp]* [-o outfile] [infile]\n",
cmdname);
}
}
+
f_print(fout, "\n};\n");
}
+ er_Proc_CodeGeneration();
}
if (extend && tell == ftell(fout)) {
if (xflag) {
f_print(fout, "#include \"rx/rx_globals.h\"\n");
}
+ if (brief_flag) {
+ f_print(fout, "#include \"rx/rx_opaque.h\"\n");
+ }
if (uflag)
f_print(fout, "#include <ubik.h>\n");
f_print(fout, "#else /* UKERNEL */\n");
if (xflag) {
f_print(fout, "#include \"rx/rx_globals.h\"\n");
}
+ if (brief_flag) {
+ f_print(fout, "#include \"rx/rx_opaque.h\"\n");
+ }
f_print(fout, "#else /* KERNEL */\n");
f_print(fout, "#include <afs/param.h>\n");
f_print(fout, "#include <afs/stds.h>\n");
if (xflag) {
f_print(fout, "#include <rx/rx_globals.h>\n");
}
+ if (brief_flag) {
+ f_print(fout, "#include <rx/rx_opaque.h>\n");
+ }
f_print(fout, "#include <afs/rxgen_consts.h>\n");
if (uflag)
f_print(fout, "#include <ubik.h>\n");
if (xflag) {
f_print(fout, "#include \"rx/rx_globals.h\"\n");
}
+ if (brief_flag) {
+ f_print(fout, "#include \"rx/rx_opaque.h\"\n");
+ }
} else {
f_print(fout, "#include <sys/types.h>\n");
f_print(fout, "#include <rx/xdr.h>\n");
if (xflag) {
f_print(fout, "#include <rx/rx_globals.h>\n");
}
+ if (brief_flag) {
+ f_print(fout, "#include <rx/rx_opaque.h\"\n");
+ }
f_print(fout, "#include <afs/rxgen_consts.h>\n");
}
}
if (xflag) {
f_print(fout, "#include \"rx/rx_globals.h\"\n");
}
+ if (brief_flag) {
+ f_print(fout, "#include \"rx/rx_opaque.h\"\n");
+ }
} else {
f_print(fout, "#include <sys/types.h>\n");
f_print(fout, "#include <rx/xdr.h>\n");
if (xflag) {
f_print(fout, "#include <rx/rx_globals.h>\n");
}
+ if (brief_flag) {
+ f_print(fout, "#include <rx/rx_opaque.h>\n");
+ }
f_print(fout, "#include <afs/rxgen_consts.h>\n");
}
}
case 'm':
case 'C':
case 'S':
+ case 'b':
case 'r':
case 'R':
case 'k':
}
}
cmd->ansic_flag = ansic_flag = flag['A'];
+ cmd->brief_flag = brief_flag = flag['b'];
cmd->cflag = cflag = flag['c'];
cmd->hflag = hflag = flag['h'];
cmd->sflag = flag['s'];