Re: [PATCH 2/5] Include net/if_var.h header only when needed

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Reviewed-by: Steven Dake <sdake@xxxxxxxxxx>


On 03/21/2012 09:23 AM, Jan Friesse wrote:
> Signed-off-by: Jan Friesse <jfriesse@xxxxxxxxxx>
> ---
>  configure.ac   |    6 +++++-
>  exec/totemip.c |    2 ++
>  2 files changed, 7 insertions(+), 1 deletions(-)
> 
> diff --git a/configure.ac b/configure.ac
> index fd4200b..9999fca 100644
> --- a/configure.ac
> +++ b/configure.ac
> @@ -78,7 +78,7 @@ AC_HEADER_SYS_WAIT
>  AC_CHECK_HEADERS([arpa/inet.h fcntl.h limits.h netdb.h netinet/in.h stdint.h \
>  		  stdlib.h string.h sys/ioctl.h sys/param.h sys/socket.h \
>  		  sys/time.h syslog.h unistd.h sys/types.h getopt.h malloc.h \
> -		  sys/sockio.h])
> +		  sys/sockio.h net/if_var.h])
>  
>  # Checks for typedefs, structures, and compiler characteristics.
>  AC_C_CONST
> @@ -319,6 +319,10 @@ case "$host_os" in
>  				AC_DEFINE_UNQUOTED([COROSYNC_FREEBSD_GE_8], [1],
>  					   [Compiling for FreeBSD >= 8 platform])
>  			;;
> +			*netbsd*)
> +				AC_DEFINE_UNQUOTED([_SEM_SEMUN_UNDEFINED], [1],
> +					   [The semun structure is undefined])
> +			;;
>  		esac
>  	;;
>  	*solaris*)
> diff --git a/exec/totemip.c b/exec/totemip.c
> index aceafdb..31dd61e 100644
> --- a/exec/totemip.c
> +++ b/exec/totemip.c
> @@ -50,7 +50,9 @@
>  #if defined(COROSYNC_BSD) || defined(COROSYNC_DARWIN)
>  #include <sys/sockio.h>
>  #include <net/if.h>
> +#ifdef HAVE_NET_IF_VAR_H
>  #include <net/if_var.h>
> +#endif
>  #include <netinet/in_var.h>
>  #include <netinet/in.h>
>  #include <ifaddrs.h>

_______________________________________________
discuss mailing list
discuss@xxxxxxxxxxxx
http://lists.corosync.org/mailman/listinfo/discuss


[Index of Archives]     [Linux Clusters]     [Corosync Project]     [Linux USB Devel]     [Linux Audio Users]     [Photo]     [Yosemite News]    [Yosemite Photos]    [Linux Kernel]     [Linux SCSI]     [X.Org]

  Powered by Linux