autoconf-patches
[Top][All Lists]
Advanced

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

Re: [PATCH] AC_HEADER_MAJOR: port to glibc 2.25


From: Nick Bowler
Subject: Re: [PATCH] AC_HEADER_MAJOR: port to glibc 2.25
Date: Wed, 14 Sep 2016 11:18:08 -0400

Hi Eric,

On 2016-09-14, Eric Blake <address@hidden> wrote:
[...]
> * lib/autoconf/headers.m4 (AC_HEADER_MAJOR): Check for sysmacros.h
> first, rather than after determining if sys/types.h pollutes the
> namespace.
> * doc/autoconf.texi (Particular Headers) <AC_HEADER_MAJOR>: Expand
> details on usage, and on workarounds for non-updated projects.
[...]
> diff --git a/doc/autoconf.texi b/doc/autoconf.texi
> index 029ddd6..f2494d8 100644
> --- a/doc/autoconf.texi
> +++ b/doc/autoconf.texi
> @@ -5977,6 +5977,27 @@ Particular Headers
>  @code{makedev}, but @file{sys/mkdev.h} does, define
>  @code{MAJOR_IN_MKDEV}; otherwise, if @file{sys/sysmacros.h} does, define
>  @code{MAJOR_IN_SYSMACROS}.

I think this text above should also be updated for clarity.  From the
current text one might reasonably infer that the MAJOR_IN_xxx macros are
defined only if <sys/types.h> does not define major, minor and makedev,
which is true originally but no longer the case with this patch.

Perhaps something like this:

  If <sys/sysmacros.h> is required (possibly in addition to
  <sys/types.h>) for the definitions of major, minor and makedev,
  define MAJOR_IN_SYSMACROS.  Otherwise, if <sys/mkdev.h> is
  required, define MAJOR_IN_MKDEV.

Followed by the example usage.  I left it vague about <sys/types.h>
because I don't know whether any systems require explicitly including
<sys/types.h> in addition to either <sys/sysmacros.h> or <sys/mkdev.h>.

> +To properly use any of these three functions, your code should contain
> +something like:
[...]

Cheers,
  Nick



reply via email to

[Prev in Thread] Current Thread [Next in Thread]