svn commit: r313323 - head/Mk
Gerald Pfeifer
gerald at FreeBSD.org
Sun Mar 3 03:21:30 UTC 2013
Author: gerald
Date: Sun Mar 3 03:21:29 2013
New Revision: 313323
URL: http://svnweb.freebsd.org/changeset/ports/313323
Log:
Do not just rely on the version number of FreeBSD in deciding whether
a certain version of GCC is in the base, but also check the existence
of /usr/bin/gcc.
This unbreaks systems where GCC is not built as part of the world, and
instead relies on versions of GCC in the Ports Collection there.
PR: 175252
Submitted by: Yamaya Takashi <yamayan at kbh.biglobe.ne.jp>
Modified:
head/Mk/bsd.gcc.mk
Modified: head/Mk/bsd.gcc.mk
==============================================================================
--- head/Mk/bsd.gcc.mk Sun Mar 3 02:51:25 2013 (r313322)
+++ head/Mk/bsd.gcc.mk Sun Mar 3 03:21:29 2013 (r313323)
@@ -150,7 +150,9 @@ IGNORE= Unknown version of GCC specified
_GCC_FOUND${v}= port
. endif
. if ${OSVERSION} >= ${_GCCVERSION_${v}_L} && ${OSVERSION} < ${_GCCVERSION_${v}_R}
+. if exists(/usr/bin/gcc)
_GCC_FOUND${v}:= base
+. endif
. endif
.endfor
@@ -194,7 +196,7 @@ _USE_GCC:= ${GCC_DEFAULT_VERSION}
# dependencies, CC, CXX, CPP, and flags.
.for v in ${GCCVERSIONS}
. if ${_USE_GCC} == ${_GCCVERSION_${v}_V}
-. if ${OSVERSION} < ${_GCCVERSION_${v}_L} || ${OSVERSION} > ${_GCCVERSION_${v}_R}
+. if ${OSVERSION} < ${_GCCVERSION_${v}_L} || ${OSVERSION} > ${_GCCVERSION_${v}_R} || !exists(/usr/bin/gcc)
V:= ${_GCCVERSION_${v}_V:S/.//}
_GCC_PORT_DEPENDS:= gcc${V}
. if ${_USE_GCC} == ${GCC_DEFAULT_VERSION}
@@ -219,7 +221,7 @@ FFLAGS+= -Wl,-rpath=${_GCC_RUNTIME}
# ever telling us; to be fixed.
_GCC_BUILD_DEPENDS:= ${_GCC_PORT_DEPENDS}
. endif # ${_USE_GCC} != 3.4
-. else # ${OSVERSION} < ${_GCCVERSION_${v}_L} || ${OSVERSION} > ${_GCCVERSION_${v}_R}
+. else # Use GCC in base.
CC:= gcc
CXX:= g++
. if exists(/usr/bin/gcpp)
@@ -227,7 +229,7 @@ CPP:= gcpp
. else
CPP:= cpp
. endif
-. endif # ${OSVERSION} < ${_GCCVERSION_${v}_L} || ${OSVERSION} > ${_GCCVERSION_${v}_R}
+. endif # Use GCC in base.
. endif # ${_USE_GCC} == ${_GCCVERSION_${v}_V}
.endfor
.undef V
More information about the svn-ports-all
mailing list