blob: fd3bc75a890738a32469de9f7ca4450be1e9c198 [file] [log] [blame] [raw]
'gcc -v' output may contain string 'version' in multiple lines.
diff -ru --exclude-from freebsd-src-diff-exclude-names /var/archive3/public/freebsd-releng-10.4-src/sys/conf/newvers.sh freebsd-10.4/sys/conf/newvers.sh
--- /var/archive3/public/freebsd-releng-10.4-src/sys/conf/newvers.sh 2019-08-17 21:42:56.000000000 +0800
+++ freebsd-10.4/sys/conf/newvers.sh 2019-08-17 23:25:18.115374009 +0800
@@ -103,7 +103,7 @@
t=`date`
fi
i=`${MAKE:-make} -V KERN_IDENT`
-compiler_v=$($(${MAKE:-make} -V CC) -v 2>&1 | grep 'version')
+compiler_v=$($(${MAKE:-make} -V CC) -v 2>&1 | grep -m 1 -E ' version [0-9]+')
for dir in /usr/bin /usr/local/bin; do
if [ ! -z "${svnversion}" ] ; then