Re: [PATCH libdrm] xf86drm: fix compile error for declare i in for loop

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

 



Hi Qiang Yu,

On 17 May 2017 at 10:26, Qiang Yu <Qiang.Yu@xxxxxxx> wrote:
> error log:
> xf86drm.c: In function 'parse_separate_sysfs_files':
> xf86drm.c:3104:5: error: 'for' loop initial declarations are only allowed in C99 mode
>      for (unsigned i = ignore_revision ? 1 : 0; i < ARRAY_SIZE(attrs); i++) {
>      ^
> xf86drm.c:3104:5: note: use option -std=c99 or -std=gnu99 to compile your code
> make[4]: *** [libdrm_la-xf86drm.lo] Error 1
>
configure should error out if the compiler does not support C99. Are
you explicitly patching that out?
Why can't we use a C99 in 2017 - gcc and clang has supported it for 10+ years.

Thanks
Emil
_______________________________________________
dri-devel mailing list
dri-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/dri-devel




[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux