[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Getting AC_PROG_CC_C99
From: |
Gary V. Vaughan |
Subject: |
Re: Getting AC_PROG_CC_C99 |
Date: |
Fri, 30 Sep 2011 10:26:54 +0700 |
Hi Bruno,
On 29 Sep 2011, at 16:14, Bruno Haible wrote:
> Gary V. Vaughan wrote:
>>> we're fine as-is, since it's normal practice
>>> to put the AC_PROG_CC_STDC before gl_EARLY.
>>
>> I discovered the multiple --std=gnu99 option problem because no
>> one told me that it's normal to to put AC_PROG_CC_STDC before
>> gl_EARLY, I just saw the instructions to invoke gl_EARLY as soon
>> as possible after AC_PROG_CC, so I did that and inserted gl_EARLY
>> immediately following AC_PROG_CC, and before the AC_PROG_CC_STDC
>> that came directly after.
>
> OK, let me update the documentation. Patch attached.
I don't think many users will find this before they are already bitten.
IMHO, the two main places in gnulib that people see instructions are in
the output of gnulib-tool itself:
...
Don't forget to
...
- invoke gl_EARLY in ./configure.ac, right after AC_PROG_CC,
...
Or the comment at the start of gnulib-comp.m4:
# This macro should be invoked from ./configure.ac, in the section
# "Checks for programs", right after AC_PROG_CC, and certainly before
# any checks for libraries, header files, types and library functions.
AC_DEFUN([gl_EARLY],
...
Although if you take my earlier patch, no need to fix either of those, or
the texi documentation as per your attached patch.
> 2011-09-29 Bruno Haible <address@hidden>
>
> doc: Improve doc about gl_EARLY.
> * doc/gnulib-tool.texi (Initial import): Mention where to place an
> AC_PROG_CC_STDC invocation.
> Reported by Gary V. Vaughan <address@hidden>.
>
> --- doc/gnulib-tool.texi.orig Thu Sep 29 10:50:25 2011
> +++ doc/gnulib-tool.texi Thu Sep 29 10:47:52 2011
> @@ -217,6 +217,17 @@
> ...
> @end example
>
> +If you are using @code{AC_PROG_CC_STDC}, the macro @code{gl_EARLY} must
> +be called after it, like this:
> +
> address@hidden
> +...
> +AC_PROG_CC
> +AC_PROG_CC_STDC
> +gl_EARLY
> +...
> address@hidden example
> +
> The core part of the gnulib checks are done by the macro
> @code{gl_INIT}. Place it further down in the file, typically where
> you normally check for header files or functions. It must come after
Cheers,
--
Gary V. Vaughan (gary AT gnu DOT org)
- Re: Getting AC_PROG_CC_C99, (continued)
- Re: Getting AC_PROG_CC_C99, Gary V. Vaughan, 2011/09/29
- Re: Getting AC_PROG_CC_C99, Bruno Haible, 2011/09/29
- Re: Getting AC_PROG_CC_C99, Paul Eggert, 2011/09/29
- Re: Getting AC_PROG_CC_C99, Bruno Haible, 2011/09/30
- Re: Getting AC_PROG_CC_C99, Paul Eggert, 2011/09/30
- Re: Getting AC_PROG_CC_C99, Andrew W. Nosenko, 2011/09/30
- Re: Getting AC_PROG_CC_C99, Paul Eggert, 2011/09/30
- Re: Getting AC_PROG_CC_C99, Gary V. Vaughan, 2011/09/29
- Re: Getting AC_PROG_CC_C99, Bruno Haible, 2011/09/30
- Re: Getting AC_PROG_CC_C99, Gary V. Vaughan, 2011/09/30
- Re: Getting AC_PROG_CC_C99,
Gary V. Vaughan <=
- Re: Getting AC_PROG_CC_C99, Bruno Haible, 2011/09/30
- Re: Getting AC_PROG_CC_C99, Gary V. Vaughan, 2011/09/29
- Re: Getting AC_PROG_CC_C99, Bruno Haible, 2011/09/30