summaryrefslogtreecommitdiff
path: root/mk
diff options
context:
space:
mode:
Diffstat (limited to 'mk')
-rw-r--r--mk/compiler/gcc.mk8
1 files changed, 4 insertions, 4 deletions
diff --git a/mk/compiler/gcc.mk b/mk/compiler/gcc.mk
index a83dddc2b39..9454375862c 100644
--- a/mk/compiler/gcc.mk
+++ b/mk/compiler/gcc.mk
@@ -1,4 +1,4 @@
-# $NetBSD: gcc.mk,v 1.204 2019/09/08 09:24:52 rillig Exp $
+# $NetBSD: gcc.mk,v 1.205 2019/09/18 06:15:13 rillig Exp $
#
# This is the compiler definition for the GNU Compiler Collection.
#
@@ -187,14 +187,14 @@ _GCC_AUX_PATTERNS= 20[1-2][0-9][0-1][0-9][0-3][0-9]*
# _CC is the full path to the compiler named by ${CC} if it can be found.
.if !defined(_CC)
-_CC:= ${CC:C/^/_asdf_/1:M_asdf_*:S/^_asdf_//}
+_CC:= ${CC:[1]}
. if !empty(GCCBASE) && exists(${GCCBASE}/bin)
_EXTRA_CC_DIRS= ${GCCBASE}/bin
. endif
. for _dir_ in ${_EXTRA_CC_DIRS} ${PATH:C/\:/ /g}
. if empty(_CC:M/*)
-. if exists(${_dir_}/${CC:C/^/_asdf_/1:M_asdf_*:S/^_asdf_//})
-_CC:= ${_dir_}/${CC:C/^/_asdf_/1:M_asdf_*:S/^_asdf_//}
+. if exists(${_dir_}/${CC:[1]})
+_CC:= ${_dir_}/${CC:[1]}
. endif
. endif
. endfor