diff options
author | John Mark Bell <jmb@netsurf-browser.org> | 2009-08-02 09:25:30 +0000 |
---|---|---|
committer | John Mark Bell <jmb@netsurf-browser.org> | 2009-08-02 09:25:30 +0000 |
commit | 06213738db7592e4e7fed9f7afad6b120416b27f (patch) | |
tree | 737d608e4e6c957508c1d9cbfcab780be73cd824 /makefiles/Makefile.tools | |
parent | 9785ccc2e942ebd0951a2104dd249f88a59d3700 (diff) | |
download | buildsystem-06213738db7592e4e7fed9f7afad6b120416b27f.tar.gz buildsystem-06213738db7592e4e7fed9f7afad6b120416b27f.tar.bz2 |
Attempt to detect old GCC versions.
svn path=/trunk/tools/buildsystem/; revision=8983
Diffstat (limited to 'makefiles/Makefile.tools')
-rw-r--r-- | makefiles/Makefile.tools | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/makefiles/Makefile.tools b/makefiles/Makefile.tools index e47f48e..467ca5d 100644 --- a/makefiles/Makefile.tools +++ b/makefiles/Makefile.tools @@ -327,7 +327,16 @@ ifeq ($(word 2,$(ccvsn)),(GCC)) CC_CAN_BUILD_AND_DEP ?= yes endif else - # Not GCC -- assume inability to dep - CC_CANNOT_DEP ?= yes + # Older versions of GCC just output the version number, so examine the + # binary name in the hope of detecting more GCC. + ifeq ($(findstring gcc,$(CC)),gcc) + GCCVER := $(word 1,$(subst ., ,$(ccvsn))) + ifneq ($(GCCVER),2) + CC_CAN_BUILD_AND_DEP ?= yes + endif + else + # Not GCC -- assume inability to dep + CC_CANNOT_DEP ?= yes + endif endif |