Subject: bin/1106: make rpcgen emit prototypes in header files
To: None <gnats-admin@sun-lamp.cs.berkeley.edu>
From: Thorsten Lockert <tholo@SigmaSoft.COM>
List: netbsd-bugs
Date: 06/03/1995 23:05:07
>Number: 1106
>Category: bin
>Synopsis: make rpcgen emit prototypes in header files
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: bin-bug-people (Utility Bug People)
>State: open
>Class: change-request
>Submitter-Id: net
>Arrival-Date: Sat Jun 3 23:05:02 1995
>Originator: Thorsten Lockert
>Organization:
SigmaSoft, Th. Lockert
>Release: May 28, 1995
>Environment:
System: NetBSD gandalf.sigmasoft.com 1.0A NetBSD 1.0A (GANDALF) #1: Sun May 7 21:49:27 PDT 1995 tholo@gandalf.sigmasoft.com:/usr/src/sys/arch/i386/compile/GANDALF i386
>Description:
Minor patch to rpcgen(1) to make it emit NetBSD-style prototypes
in generated header files
>How-To-Repeat:
Do you want to?
>Fix:
Apply the following patch:
*** src/usr.bin/rpcgen/rpc_hout.c.orig Sat Jun 3 22:09:11 1995
--- src/usr.bin/rpcgen/rpc_hout.c Sat Jun 3 22:27:31 1995
***************
*** 76,82 ****
break;
}
if (def->def_kind != DEF_PROGRAM && def->def_kind != DEF_CONST) {
! f_print(fout, "bool_t xdr_%s();\n", def->def_name);
}
if (def->def_kind != DEF_CONST) {
f_print(fout, "\n");
--- 76,88 ----
break;
}
if (def->def_kind != DEF_PROGRAM && def->def_kind != DEF_CONST) {
! f_print(fout, "bool_t xdr_%s __P((XDR *,", def->def_name);
! f_print(fout, "%s ", def->def_name);
! if (def->def_kind != DEF_TYPEDEF ||
! !isvectordef(def->def.ty.old_type, def->def.ty.rel)) {
! f_print(fout, "*");
! }
! f_print(fout, "));\n");
}
if (def->def_kind != DEF_CONST) {
f_print(fout, "\n");
***************
*** 213,219 ****
f_print(fout, "%s *", fixtype(proc->res_type));
}
pvname(proc->proc_name, vp->vers_num);
! f_print(fout, "();\n");
}
static
--- 219,227 ----
f_print(fout, "%s *", fixtype(proc->res_type));
}
pvname(proc->proc_name, vp->vers_num);
! f_print(fout, " __P((");
! ptype(proc->arg_prefix, proc->arg_type, 1);
! f_print(fout, "*, CLIENT *));\n");
}
static
>Audit-Trail:
>Unformatted: