Re: Problems compiling scotty-2.1.5 on RedHat Linux 4.1

Rob van Nieuwkerk (robn@verdi.et.tudelft.nl)
Sun, 11 May 1997 01:35:46 +0200

>
> I am attempting to compile/install scotty-2.1.5 on RedHat Linux 4.1 and am
> experiencing some compile errors. After running "./configure" and doing a
> "make", I get the following error (after many files compile):
>
> cc -c -O -fPIC -I. -I./../tnm/generic -I/usr/include ether_xdr.c
> ether_xdr.c: In function `xdr_etherstat':
> ether_xdr.c:34: parse error before `int'
> ether_xdr.c:64: `i' undeclared (first use this function)
> ether_xdr.c:64: (Each undeclared identifier is reported only once
> ether_xdr.c:64: for each function it appears in.)
> ether_xdr.c: In function `xdr_etheraddrs':
> ether_xdr.c:181: parse error before `int'
>
> Looking at this source file on line 34, I see the following (which is
> obviously in error):
>
> bool_t
> xdr_etherstat(XDR *xdrs, etherstat *objp)
> {
>
> register long *buf;
> (void)buf;
>
> int i;
>
> Notice the strange "(void)buf" declaration... what should this be (if
> anything)? I assume it means a bad/broken rpcgen, but I'm no expert.

Yep, It's a bug in the rpcgen of NetKit-0.09. The maintainer (David
Holland) allready knows about it. It'll be fixed in NetKit-0.10.

Here is a piece of the mail I sent him:

-------------------------------------------------------------------------
I think that the following in NetKit-0.09/rpcgen/rpc_cout.c:
(I couldn't find a newer version)

/* dholland 12/29/96 add (void)buf to avoid gcc warnings if buf unused */
f_print(fout, "\t register long *buf;\n(void)buf;\n\n");

instead of this in NetKit-B-0.08/rpcgen/rpc_cout.c:

f_print(fout, "\t register long *buf;\n\n");

causes that wrong code is generated for the file "ether.x" from the
scotty Network Management package.
-------------------------------------------------------------------------

Greetings,
Rob van Nieuwkerk

--
!! This message is brought to you via the `tkined & scotty' mailing list.
!! Please do not reply to this message to unsubscribe. To subscribe or
!! unsubscribe, send a mail message to <tkined-request@ibr.cs.tu-bs.de>.
!! See http://wwwsnmp.cs.utwente.nl/~schoenw/scotty/ for more information.