This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Define __USE_KERNEL_IPV6_DEFS macro for non-Linux kernels


Aurelien Jarno, on Wed 06 Jul 2016 22:39:04 +0200, wrote:
> Commit 1c1e7fb6 changed the __USE_KERNEL_IPV6_DEFS tests from 'ifdef'
> to 'if'. As inet/netinet.in.h is a generic file, this causes a warning
> on non-Linux kernels (for example Hurd). To fix that define it in the
> generic bits/in.h file.
> 
> Changelog:
> 	* bits/in.h (__USE_KERNEL_IPV6_DEFS): Define to 0.

I confirm that this fixes loads of warnings in the Hurd build.

> ---
>  ChangeLog | 4 ++++
>  bits/in.h | 3 +++
>  2 files changed, 7 insertions(+)
> 
> diff --git a/ChangeLog b/ChangeLog
> index 690012c..6ffcee3 100644
> --- a/ChangeLog
> +++ b/ChangeLog
> @@ -1,3 +1,7 @@
> +2016-07-06  Aurelien Jarno  <aurelien@aurel32.net>
> +
> +	* bits/in.h (__USE_KERNEL_IPV6_DEFS): Define to 0.
> +
>  2016-07-06  Stefan Liebler  <stli@linux.vnet.ibm.com>
>  
>  	* sysdeps/s390/linkmap.h (struct link_map_machine):
> diff --git a/bits/in.h b/bits/in.h
> index d517115..7dc93c1 100644
> --- a/bits/in.h
> +++ b/bits/in.h
> @@ -21,6 +21,9 @@
>  # error "Never use <bits/in.h> directly; include <netinet/in.h> instead."
>  #endif
>  
> +/* This is the generic version, do not assume a linux-based kernel.  */
> +#define __USE_KERNEL_IPV6_DEFS 0
> +
>  /* To select the IP level.  */
>  #define SOL_IP		0
>  
> -- 
> 2.8.1
> 

-- 
Samuel
"2 + 2 = 5 pour d'assez grandes valeurs de 2"


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]