From: Gabriel C Date: Wed, 21 May 2008 18:36:19 +0000 (+0200) Subject: scripts/ver_linux use 'gcc -dumpversion' X-Git-Tag: v2.6.26-rc4~8^2~2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=656a3f797889dafcce2f5b8b222ad66e9974b6f7;p=platform%2Fkernel%2Flinux-exynos.git scripts/ver_linux use 'gcc -dumpversion' These magic greps and hacks in ver_linux to get the gcc version always break after some gcc releases. Since now gcc >4.3 allows compiling with '--with-pkgversion' ( which can be everything 'My Cool Gcc' or something ) ver_linux will report random junk for these. Simply use 'gcc -dumpversion' to get the gcc version which should always work. Signed-off-by: Gabriel C Signed-off-by: Andrew Morton Signed-off-by: Sam Ravnborg --- diff --git a/scripts/ver_linux b/scripts/ver_linux index ab69ecefedbd..7ac0e309be09 100755 --- a/scripts/ver_linux +++ b/scripts/ver_linux @@ -12,12 +12,9 @@ echo ' ' uname -a echo ' ' -gcc --version 2>&1| head -n 1 | grep -v gcc | awk \ +gcc -dumpversion 2>&1| awk \ 'NR==1{print "Gnu C ", $1}' -gcc --version 2>&1| grep gcc | awk \ -'NR==1{print "Gnu C ", $3}' - make --version 2>&1 | awk -F, '{print $1}' | awk \ '/GNU Make/{print "Gnu make ",$NF}'