Re: cc-version not available to change EXTRA_CFLAGS

From: Sam Ravnborg
Date: Sat Jan 21 2006 - 17:11:28 EST


On Sat, Jan 21, 2006 at 07:08:05PM +0100, Olaf Hering wrote:
>
> I want to add a gcc version check for reiserfs, on akpms request.
> This one doesnt work with 2.6.16rc1, havent checked if it ever worked.
...
> Index: linux-2.6.16-rc1-olh/fs/reiserfs/Makefile
> ===================================================================
> --- linux-2.6.16-rc1-olh.orig/fs/reiserfs/Makefile
> +++ linux-2.6.16-rc1-olh/fs/reiserfs/Makefile
> @@ -28,7 +28,7 @@ endif
> # will work around it. If any other architecture displays this behavior,
> # add it here.
> ifeq ($(CONFIG_PPC32),y)
> -EXTRA_CFLAGS := -O1
> +EXTRA_CFLAGS := $(shell set -x ; if [ $(call cc-version) -lt 0402 ] ; then echo $(call cc-option,-O1); fi ;)
> endif

cc-option is only available from main Makefile as of today.
I can try to move them to Kbuild.include - that should fix this usecase.

Sam
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/