Subject: Re: rpcgen generates wrong server code
To: None <tech-userlevel@netbsd.org>
From: Ian Zagorskih <ianzag@megasignal.com>
List: tech-userlevel
Date: 05/12/2004 23:28:09
=F7 =D3=CF=CF=C2=DD=C5=CE=C9=C9 =CF=D4 11 =ED=C1=CA 2004 19:15 Christos Zou=
las =CE=C1=D0=C9=D3=C1=CC(a):
> In article <200405111021.23195.ianzag@megasignal.com>,
>
> Ian Zagorskih <ianzag@megasignal.com> wrote:
> >uname -a
> >NetBSD IANZAG 2.0_BETA NetBSD 2.0_BETA (IANZAG) #0: Fri May  7 17:55:29
> > NOVST 2004
> >
> >I'm trying to build some simple RPC examples from "UNIX IPC" by Stevens
> > like listed below:
> >
> >--- square.x---
> >struct square_in {              /* input (argument) */
> >  long  arg1;
> >};
> >
> >struct square_out {             /* output (result) */
> >  long  res1;
> >};
> >
> >program SQUARE_PROG {
> >    version SQUARE_VERS {
> >        square_out      SQUAREPROC(square_in) =3D 1; /* procedure number=
 =3D 1
> > */ } =3D 1;                              /* version number */
> >} =3D 0x31230000;                 /* program number */
> >--- square.x---
> >
> >While building the client side seems to be fine but there's some problems
> > with server:
> >
> >---cut---
> >rpcgen -C square.x
>
> use rpcgen -C -b square.x
>

Thanks Christos, looks like it works fine now.

Just a quesion - why there's no define like RPC_CNTFILES in bsd.rpc.mk ? As=
 =20
So I could generate foo_cnt.c on stand alone client side from foo.x=20
RPC_SVCFILES does for server side. I guess for this i can use RPC_SVCFILES=
=20
with ptoper RPC_SVCFLAGS but IMHO it adds some little confision.

AFAIU it's not used in NetBSD build tree but having such target would be ni=
ce.=20

// wbr