Re: [PATCH] build: allow building with newer glibc-headers and -O0

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

 



On 06/07/2012 05:24 AM, Christophe Fergeau wrote:

Hello, and thanks for reviewing this.

> 
> This is not causing an actual issue while compiling libvirt, but
> __OPTIMIZE__ is not defined when using -O0, which causes a warning
> with -Wundef

Libvirt explicitly refuses to use -Wundef (see
m4/virt-compile-warnings.m4), since C99 guarantees that you can sanely
use an undefined macro as 0 in preprocessor evaluation.

> 
> Using a #ifdef would be more correct:

Only if you care about -Wundef, which we don't.  But I agree that if
other projects are copying this trick to work around glibc's braindead
choice of making this warning verbose, then those projects may have to
consider this fact.

-- 
Eric Blake   eblake@xxxxxxxxxx    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]