libportablexdr_la_SOURCES = xdr_array.c xdr_float.c xdr_mem.c xdr_reference.c \
xdr.c xdr_intXX_t.c xdr_rec.c xdr_stdio.c \
rpc/rpc.h rpc/types.h rpc/xdr.h
-libportablexdr_la_CFLAGS = -Wall -Werror
\ No newline at end of file
+libportablexdr_la_CFLAGS = -Wall -Werror
+libportablexdr_la_LDFLAGS = @MINGW_EXTRA_LDFLAGS@
AC_CONFIG_HEADERS([config.h])
+AC_CANONICAL_HOST
AC_PROG_CC
AC_CHECK_PROGS(AR, ar)
AC_PROG_INSTALL
AC_PROG_LIBTOOL
+MINGW_EXTRA_LDFLAGS=
+case "$host" in
+ *-*-mingw*)
+ MINGW_EXTRA_LDFLAGS="-no-undefined -lws2_32"
+ ;;
+esac
+AC_SUBST(MINGW_EXTRA_LDFLAGS)
+
AC_CHECK_HEADERS([arpa/inet.h winsock2.h])
AC_OUTPUT(Makefile)
is.mantissa = (vs.mantissa1 << 16) | vs.mantissa2;
shipit:
is.sign = vs.sign;
- return (XDR_PUTLONG(xdrs, (long *)&is));
+ return (XDR_PUTLONG(xdrs, (long *)(void *)&is));
#endif
case XDR_DECODE:
return (XDR_GETLONG(xdrs, (long *)fp));
#else
vsp = (struct vax_single *)fp;
- if (!XDR_GETLONG(xdrs, (long *)&is))
+ if (!XDR_GETLONG(xdrs, (long *)(void *)&is))
return (FALSE);
for (i = 0, lim = sgl_limits;
i < sizeof(sgl_limits)/sizeof(struct sgl_limits);
((vd.mantissa4 >> 3) & MASK(13));
shipit:
id.sign = vd.sign;
- lp = (long *)&id;
+ lp = (long *)(void *)&id;
#endif
#if defined(__CYGWIN32__) || defined(__MINGW32__)
return (XDR_PUTLONG(xdrs, lp+1) && XDR_PUTLONG(xdrs, lp));
return (XDR_GETLONG(xdrs, lp++) && XDR_GETLONG(xdrs, lp));
#endif
#else
- lp = (long *)&id;
+ lp = (long *)(void *)&id;
if (!XDR_GETLONG(xdrs, lp++) || !XDR_GETLONG(xdrs, lp))
return (FALSE);
for (i = 0, lim = dbl_limits;
vd.mantissa4 = (id.mantissa2 << 3);
doneit:
vd.sign = id.sign;
- *dp = *((double *)&vd);
+ *dp = *((double *)(void *)&vd);
return (TRUE);
#endif