[cairo] [PATCH 2/2] configure : fix unrecognized -Wno option
chris at chris-wilson.co.uk
Sun Oct 21 09:34:42 PDT 2012
On Sun, 21 Oct 2012 12:59:06 +0200 (CEST), g.esp at free.fr wrote:
> This behavior is described in gcc-4.4 announce http://gcc.gnu.org/gcc-4.4/changes.html
> and on later versions in the manual
> A new option has even be added after gcc-4.4 to control that behavior with -Wunknown-warning/-Wno-unknown-warning but as this new option is not know on gcc-4.4, the new option can't be used there unless using the same trick aka test if -Wunknown-warning is supported and use -Wno-unknown-warning. So there is actually no gain with that option until the last supported compiler know this new option.
> Detection was made in a similar way in openssh(portable) or using makefile in linux/scripts/Kbuild.include with
> # cc-disable-warning
> # Usage: cflags-y += $(call cc-disable-warning,unused-but-set-variable)
> cc-disable-warning = $(call try-run,\
> $(CC) $(KBUILD_CPPFLAGS) $(KBUILD_CFLAGS) -W$(strip $(1)) -c -x c /dev/null -o "$$TMP",-Wno-$(strip $(1)))
Thanks for the information. So my conclusion is that this patch looks
to be the lesser evil, and so I've applied it.
Chris Wilson, Intel Open Source Technology Centre
More information about the cairo