Google

Back to the Main Page.

ac_prototype_getsockname

Download the M4 Source.

Synopsis

AC_PROTOTYPE_GETSOCKNAME

Version

1.1.1.1 (2001/07/26)     Miscellaneous @ ac-archive-0.5.39

Author

Loic Dachary <loic@senga.org>

Description

Requires the AC_PROTOTYPE macro.

Find the type of argument two and three of getsockname. User must include the following in acconfig.h:

/* Type of second argument of getsockname */ #undef GETSOCKNAME_ARG2

/* Type of third argument of getsockname */ #undef GETSOCKNAME_ARG3

M4 Source Code
AC_DEFUN([AC_PROTOTYPE_GETSOCKNAME],[
AC_PROTOTYPE(getsockname,
 [
  #include <sys/types.h>
  #include <sys/socket.h>
 ],
 [
  int a = 0;
  ARG2 * b = 0;
  ARG3 * c = 0;
  getsockname(a, b, c);
 ],
 ARG2, [struct sockaddr, void],
 ARG3, [socklen_t, size_t, int, unsigned int, long unsigned int])
])