Commit 48c35b2d authored by Alexey Dobriyan's avatar Alexey Dobriyan Committed by Ralf Baechle

[MIPS] There is no __GNUC_MAJOR__

Gcc major version number is in __GNUC__. As side effect fix checking
with sparse if sparse was built with gcc 4.1 and mips cross-compiler
is 3.4.

Sparse will inherit version 4.1, __GNUC__ won't be filtered from
"-dM -E -xc" output, sparse will pick only new major, effectively becoming
gcc version 3.1 which is unsupported.
Signed-off-by: default avatarAlexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: default avatarRalf Baechle <ralf@linux-mips.org>
parent 419dd837
...@@ -623,7 +623,7 @@ LDFLAGS += -m $(ld-emul) ...@@ -623,7 +623,7 @@ LDFLAGS += -m $(ld-emul)
ifdef CONFIG_MIPS ifdef CONFIG_MIPS
CHECKFLAGS += $(shell $(CC) $(CFLAGS) -dM -E -xc /dev/null | \ CHECKFLAGS += $(shell $(CC) $(CFLAGS) -dM -E -xc /dev/null | \
egrep -vw '__GNUC_(MAJOR|MINOR|PATCHLEVEL)__' | \ egrep -vw '__GNUC_(|MINOR_|PATCHLEVEL_)_' | \
sed -e 's/^\#define /-D/' -e "s/ /='/" -e "s/$$/'/") sed -e 's/^\#define /-D/' -e "s/ /='/" -e "s/$$/'/")
ifdef CONFIG_64BIT ifdef CONFIG_64BIT
CHECKFLAGS += -m64 CHECKFLAGS += -m64
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment