[BK PATCH] kbuild: fix cc-version

From: Sam Ravnborg
Date: Tue Aug 24 2004 - 15:47:04 EST


When consolidating gcc version handling a bug were introduced.
It made make spit out

/bin/sh: line 1: [: too many arguments

when building the kernel.
As a side-effect all gcc version checks were failing.

Patch below.

Linus - please pull from
bk://linux-sam.bkbits.net/kbuild

[Only cset pushed since last update].

Sam

# This is a BitKeeper generated diff -Nru style patch.
#
# ChangeSet
# 2004/08/24 22:36:35+02:00 sam@xxxxxxxxxxxxxxxxx
# kbuild: fix cc-version
#
# cc-version needs to use $(shell to get the gcc version.
# Before if gave the following error when building the kernel:
#
# /bin/sh: line 1: [: too many arguments
#
# And all checks for gcc version were broken.
#
# Signed-off-by: Sam Ravnborg <sam@xxxxxxxxxxxx>
#
# Makefile
# 2004/08/24 22:34:30+02:00 sam@xxxxxxxxxxxxxxxxx +2 -2
# fix cc-version
#
diff -Nru a/Makefile b/Makefile
--- a/Makefile 2004-08-24 22:37:19 +02:00
+++ b/Makefile 2004-08-24 22:37:19 +02:00
@@ -279,8 +279,8 @@

# cc-version
# Usage gcc-ver := $(call cc-version $(CC))
-cc-version = $(CONFIG_SHELL) $(srctree)/scripts/gcc-version.sh \
- $(if $(1), $(1), $(CC))
+cc-version = $(shell $(CONFIG_SHELL) $(srctree)/scripts/gcc-version.sh \
+ $(if $(1), $(1), $(CC)))


# Look for make include files relative to root of kernel src
-
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/