2010/4/26 Eric Blake <eblake(a)redhat.com>:
On 04/25/2010 05:31 AM, Matthias Bolte wrote:
> Cygwin's XDR implementation defines xdr_u_int64_t instead of
> xdr_uint64_t and lacks IXDR_PUT_INT32/IXDR_GET_INT32.
Would you mind reporting this upstream? Charles Wilson on the cygwin
list can probably fix that.
xdr_uint64_t/xdr_u_int64_t seems not to be part of the original XDR
specification. If you goggle for it you'll find both version.
IXDR_PUT_INT32/IXDR_GET_INT32 is just missing.
>
> Alter the IXDR_GET_LONG regex in rpcgen_fix.pl so it doesn't destroy
> the #define IXDR_GET_INT32 IXDR_GET_LONG in remote_protocol.x.
>
> Also fix the remote_protocol.h regex in rpcgen_fix.pl.
> -#include "./remote/remote_protocol.h"
> +#include "remote_protocol.h"
> #include "internal.h"
> #include <arpa/inet.h>
> +#ifdef HAVE_XDR_U_INT64_T
> +# define xdr_uint64_t xdr_u_int64_t
> +#endif
> +#ifndef IXDR_PUT_INT32
> +# define IXDR_PUT_INT32 IXDR_PUT_LONG
Is this ever going to bite us if cygwin adds support for 64-bit windows?
Then again, if we report the missing defines upstream, cygwin's xdr
implementation may be fixed before a 64-bit port.
But no problem in addressing things in parallel - ACK to this patch, so
we aren't sitting around waiting for an upstream patch.
I'm going to report this upstream later today.
Thanks, pushed.
Matthias