On Nov 29, 2012, at 2:22 PM, Charles Davis wrote:
On Nov 29, 2012, at 11:47 AM, Alexandre Julliard wrote:
Charles Davis cdavis5x@gmail.com writes:
From: Charles Davis cdavis@mymail.mines.edu
Autoconf checks for a field of a struct by using it in an if() expression. Of course, you can't do this for an aggregate field, so you must instead check a field of that aggregate instead. Up until now, the conftests for the st_?tim fields were all failing, even on systems that had them, because of this.
It does a sizeof, which should work just fine.
No it doesn't. This is the conftest.c template that it uses (ac_fn_c_check_member() function, at line 2036 in configure):
<contents of confdefs.h> /* end confdefs.h. */ $5 int main () { static $2 ac_aggr; if (ac_aggr.$3) return 0; ; return 0; }
I see no sizeof in there.
Oh wait... there's the second conftest later on in that function, that does use sizeof. Sorry for the noise. (But I have to wonder why they don't just have one test using sizeof... Autoconf is just one, big horrible hack.)
Chip