aboutsummaryrefslogtreecommitdiffstats
path: root/Mk
diff options
context:
space:
mode:
authorbdrewery <bdrewery@FreeBSD.org>2016-01-09 07:41:25 +0800
committerbdrewery <bdrewery@FreeBSD.org>2016-01-09 07:41:25 +0800
commit7dd66dcc16c3042b2de0ab13cbcf174afbd3f991 (patch)
tree6cfd40d305efd19b5a4afaa78bd1f3992b8d0ccb /Mk
parentc8ce04652f5639619f57166c8975c98be7785d6b (diff)
downloadfreebsd-ports-gnome-7dd66dcc16c3042b2de0ab13cbcf174afbd3f991.tar.gz
freebsd-ports-gnome-7dd66dcc16c3042b2de0ab13cbcf174afbd3f991.tar.zst
freebsd-ports-gnome-7dd66dcc16c3042b2de0ab13cbcf174afbd3f991.zip
Make COMPILER_VERSION more compatible with clang 3.8 trunk.
"clang version 3.8.0 (trunk 256945) (based on LLVM 3.8.0svn)" was giving "38 38" was a result. Now duplicates for fmake are trimmed and only the first version found is used for bmake using its :tW. With hat: portmgr In collaboration with: dim
Diffstat (limited to 'Mk')
-rw-r--r--Mk/Uses/compiler.mk6
1 files changed, 5 insertions, 1 deletions
diff --git a/Mk/Uses/compiler.mk b/Mk/Uses/compiler.mk
index 3d539cdea8ae..c0949e1ce36e 100644
--- a/Mk/Uses/compiler.mk
+++ b/Mk/Uses/compiler.mk
@@ -67,7 +67,11 @@ _COMPILER_ARGS+= features
.endif
_CCVERSION!= ${CC} --version
-COMPILER_VERSION= ${_CCVERSION:M[0-9].[0-9]*:C/([0-9]).([0-9]).*/\1\2/g}
+.if defined(.PARSEDIR)
+COMPILER_VERSION= ${_CCVERSION:M[0-9].[0-9]*:tW:C/([0-9]).([0-9]).*/\1\2/g}
+.else
+COMPILER_VERSION= ${_CCVERSION:M[0-9].[0-9]*:C/([0-9]).([0-9]).*/\1\2/g:u}
+.endif
.if ${_CCVERSION:Mclang}
COMPILER_TYPE= clang
.else