<div dir="ltr"><div>FYI: I just pushed the NIR patches with Connor's R-B so as soon as we're done with <a href="http://configure.ac">configure.ac</a>, we should be building on RHEL6 again.<br></div>--Jason<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Jan 21, 2015 at 5:37 PM, Ian Romanick <span dir="ltr"><<a href="mailto:idr@freedesktop.org" target="_blank">idr@freedesktop.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb"><div class="h5">On 01/21/2015 05:35 PM, Matt Turner wrote:<br>
> On Wed, Jan 21, 2015 at 5:28 PM, Dave Airlie <<a href="mailto:airlied@gmail.com">airlied@gmail.com</a>> wrote:<br>
>> From: Dave Airlie <<a href="mailto:airlied@redhat.com">airlied@redhat.com</a>><br>
>><br>
>> anonymous structs/union don't work with c99 but do work with gnu99<br>
>> on gcc 4.4.<br>
>><br>
>> This on top of Jason's designated initialisers changes, make<br>
>> Mesa build on RHEL6 again.<br>
>><br>
>> Signed-off-by: Dave Airlie <<a href="mailto:airlied@redhat.com">airlied@redhat.com</a>><br>
>> ---<br>
>>  <a href="http://configure.ac" target="_blank">configure.ac</a> |   12 +++++++++++-<br>
>>  1 files changed, 11 insertions(+), 1 deletions(-)<br>
>><br>
>> diff --git a/<a href="http://configure.ac" target="_blank">configure.ac</a> b/<a href="http://configure.ac" target="_blank">configure.ac</a><br>
>> index a4c5c74..9420a90 100644<br>
>> --- a/<a href="http://configure.ac" target="_blank">configure.ac</a><br>
>> +++ b/<a href="http://configure.ac" target="_blank">configure.ac</a><br>
>> @@ -145,6 +145,7 @@ AC_MSG_RESULT([$acv_mesa_CLANG])<br>
>>  dnl If we're using GCC, make sure that it is at least version 4.2.0.  Older<br>
>>  dnl versions are explictly not supported.<br>
>>  GEN_ASM_OFFSETS=no<br>
>> +USE_GNU99=no<br>
>>  if test "x$GCC" = xyes -a "x$acv_mesa_CLANG" = xno; then<br>
>>      AC_MSG_CHECKING([whether gcc version is sufficient])<br>
>>      major=0<br>
>> @@ -163,6 +164,9 @@ if test "x$GCC" = xyes -a "x$acv_mesa_CLANG" = xno; then<br>
>>          AC_MSG_RESULT([yes])<br>
>>      fi<br>
>><br>
>> +    if test $GCC_VERSION_MAJOR -lt 4 -o $GCC_VERSION_MAJOR -eq 4 -a $GCC_VERSION_MINOR -lt 6 ; then<br>
><br>
> Can't we just do this test...<br>
><br>
>> +        USE_GNU99=yes<br>
>> +    fi<br>
>>      if test "x$cross_compiling" = xyes; then<br>
>>          GEN_ASM_OFFSETS=yes<br>
>>      fi<br>
>> @@ -221,7 +225,13 @@ esac<br>
>><br>
>>  dnl Add flags for gcc and g++<br>
>>  if test "x$GCC" = xyes; then<br>
>> -    CFLAGS="$CFLAGS -Wall -std=c99"<br>
>> +    CFLAGS="$CFLAGS -Wall"<br>
>> +<br>
>> +    if test "x$USE_GNU99" = xyes; then<br>
><br>
> ... right here?<br>
<br>
</div></div>It would happen on clang if we did.  Above, it's inside a block of "am I<br>
GCC and definitely not clang".  That said, I don't know how important<br>
that is...<br>
<div class="HOEnZb"><div class="h5"><br>
>> +       CFLAGS="$CFLAGS -std=gnu99"<br>
>> +    else<br>
>> +       CFLAGS="$CFLAGS -std=c99"<br>
>> +    fi<br>
>><br>
>>      # Enable -Werror=implicit-function-declaration and<br>
>>      # -Werror=missing-prototypes, if available, or otherwise, just<br>
>> --<br>
>> 1.7.1<br>
>><br>
>> _______________________________________________<br>
>> mesa-dev mailing list<br>
>> <a href="mailto:mesa-dev@lists.freedesktop.org">mesa-dev@lists.freedesktop.org</a><br>
>> <a href="http://lists.freedesktop.org/mailman/listinfo/mesa-dev" target="_blank">http://lists.freedesktop.org/mailman/listinfo/mesa-dev</a><br>
> _______________________________________________<br>
> mesa-dev mailing list<br>
> <a href="mailto:mesa-dev@lists.freedesktop.org">mesa-dev@lists.freedesktop.org</a><br>
> <a href="http://lists.freedesktop.org/mailman/listinfo/mesa-dev" target="_blank">http://lists.freedesktop.org/mailman/listinfo/mesa-dev</a><br>
><br>
<br>
_______________________________________________<br>
mesa-dev mailing list<br>
<a href="mailto:mesa-dev@lists.freedesktop.org">mesa-dev@lists.freedesktop.org</a><br>
<a href="http://lists.freedesktop.org/mailman/listinfo/mesa-dev" target="_blank">http://lists.freedesktop.org/mailman/listinfo/mesa-dev</a><br>
</div></div></blockquote></div><br></div>