autoconf-patches
[Top][All Lists]
Advanced

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

Re: Allow inspecting AC_PREPROC_IFELSE output in true branch.


From: Ben Pfaff
Subject: Re: Allow inspecting AC_PREPROC_IFELSE output in true branch.
Date: Mon, 19 Jul 2010 12:39:06 -0700
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.2 (gnu/linux)

Eric Blake <address@hidden> writes:

> On 07/19/2010 11:43 AM, Ralf Wildenhues wrote:
>> +++ b/tests/compile.at
>> @@ -295,7 +295,7 @@ AT_DATA([configure.ac],
>>  AC_PROG_CC
>>  
>>  AC_PREPROC_IFELSE([AC_LANG_PROGRAM([int ok;], [])],
>> -              [test -f conftest.err || AS_EXIT([1])],
>> +              [{ test -f conftest.err && grep ok conftest.i; } || 
>> AS_EXIT([1])],
>
> This should use a longer string, more likely to be unique to our
> compilation (what if a system header declares a function named choke(),
> for instance), so as to avoid false positives.

As a real-life example, glibc <stdio.h> has fopencookie().
-- 
"A computer is a state machine.
 Threads are for people who cant [sic] program state machines."
--Alan Cox




reply via email to

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