summaryrefslogtreecommitdiff
path: root/mk/compiler
diff options
context:
space:
mode:
authorjlam <jlam@pkgsrc.org>2005-01-12 17:27:50 +0000
committerjlam <jlam@pkgsrc.org>2005-01-12 17:27:50 +0000
commit9d72ec198565f9ee13e76f47cb52a19e8230d783 (patch)
treea1aa1a621394b6654f141fb5b55d1d71679ed971 /mk/compiler
parent4a31c315e7d76a06617fa263458cf03cdc9afa36 (diff)
downloadpkgsrc-9d72ec198565f9ee13e76f47cb52a19e8230d783.tar.gz
Remove explicit overrides for CC and CXX that prevented using the
definitions supplied in /etc/mk.conf. It should now be possible to pass optimization flags directly using CC and CXX when using CCC and xlC compilers.
Diffstat (limited to 'mk/compiler')
-rw-r--r--mk/compiler/ccc.mk8
-rw-r--r--mk/compiler/mipspro.mk25
-rw-r--r--mk/compiler/sunpro.mk43
-rw-r--r--mk/compiler/xlc.mk8
4 files changed, 41 insertions, 43 deletions
diff --git a/mk/compiler/ccc.mk b/mk/compiler/ccc.mk
index 7ae44d3d3a2..bbeacc00eac 100644
--- a/mk/compiler/ccc.mk
+++ b/mk/compiler/ccc.mk
@@ -1,4 +1,4 @@
-# $NetBSD: ccc.mk,v 1.7 2005/01/12 15:32:01 jlam Exp $
+# $NetBSD: ccc.mk,v 1.8 2005/01/12 17:27:50 jlam Exp $
.if !defined(COMPILER_CCC_MK)
COMPILER_CCC_MK= defined
@@ -27,9 +27,6 @@ _CCC_CC= ${_CCC_DIR}/cc
_ALIASES.CC= cc
CCPATH= /usr/bin/cc
PKG_CC:= ${_CCC_CC}
-. if !empty(CC:M*gcc)
-CC:= ${PKG_CC:T} # ${CC} should be named "cc".
-. endif
.endif
.if exists(/usr/bin/cxx)
_CCC_VARS+= CXX
@@ -37,9 +34,6 @@ _CCC_CXX= ${_CCC_DIR}/cxx
_ALIASES.CXX= c++ cxx
CXXPATH= /usr/bin/cxx
PKG_CXX:= ${_CCC_CXX}
-. if !empty(CXX:M*g++)
-CXX:= ${PKG_CXX:T} # ${CXX} should be named "cxx"
-. endif
.endif
_COMPILER_STRIP_VARS+= ${_CCC_VARS}
diff --git a/mk/compiler/mipspro.mk b/mk/compiler/mipspro.mk
index e0e81c2bd7d..b37f746d618 100644
--- a/mk/compiler/mipspro.mk
+++ b/mk/compiler/mipspro.mk
@@ -1,4 +1,4 @@
-# $NetBSD: mipspro.mk,v 1.31 2005/01/12 16:41:14 jlam Exp $
+# $NetBSD: mipspro.mk,v 1.32 2005/01/12 17:27:50 jlam Exp $
.if !defined(COMPILER_MIPSPRO_MK)
COMPILER_MIPSPRO_MK= defined
@@ -7,19 +7,15 @@ COMPILER_MIPSPRO_MK= defined
MIPSPROBASE?= /usr
-# LANGUAGES.<compiler> is the list of supported languages by the compiler.
-# _LANGUAGES.<compiler> is ${LANGUAGES.<compiler>} restricted to the ones
-# requested by the package in USE_LANGUAGES.
-#
-LANGUAGES.mipspro= c c++
-_LANGUAGES.mipspro= # empty
-.for _lang_ in ${USE_LANGUAGES}
-_LANGUAGES.mipspro+= ${LANGUAGES.mipspro:M${_lang_}}
-.endfor
+# LANGUAGES.<compiler> is the list of supported languages by the
+# compiler.
+#
+LANGUAGES.mipspro= # empty
_MIPSPRO_DIR= ${WRKDIR}/.mipspro
_MIPSPRO_VARS= # empty
.if exists(${MIPSPROBASE}/bin/cc)
+LANGUAGES.mipspro+= c
_MIPSPRO_VARS+= CC
_MIPSPRO_CC= ${_MIPSPRO_DIR}/bin/cc
_ALIASES.CC= cc
@@ -27,6 +23,7 @@ CCPATH= ${MIPSPROBASE}/bin/cc
PKG_CC:= ${_MIPSPRO_CC}
.endif
.if exists(${MIPSPROBASE}/bin/CC)
+LANGUAGES.mipspro+= c++
_MIPSPRO_VARS+= CXX
_MIPSPRO_CXX= ${_MIPSPRO_DIR}/bin/CC
_ALIASES.CXX= CC c++
@@ -58,6 +55,14 @@ _COMPILER_ABI_FLAG.o32= # empty
_COMPILER_ABI_FLAG.n32= -n32
_COMPILER_ABI_FLAG.64= -64
+# _LANGUAGES.<compiler> is ${LANGUAGES.<compiler>} restricted to the ones
+# requested by the package in USE_LANGUAGES.
+#
+_LANGUAGES.mipspro= # empty
+.for _lang_ in ${USE_LANGUAGES}
+_LANGUAGES.mipspro+= ${LANGUAGES.mipspro:M${_lang_}}
+.endfor
+
# Prepend the path to the compiler to the PATH.
.if !empty(_LANGUAGES.mipspro)
PREPEND_PATH+= ${_MIPSPRO_DIR}/bin
diff --git a/mk/compiler/sunpro.mk b/mk/compiler/sunpro.mk
index 3f92a37cf69..94f30e92f1a 100644
--- a/mk/compiler/sunpro.mk
+++ b/mk/compiler/sunpro.mk
@@ -1,4 +1,4 @@
-# $NetBSD: sunpro.mk,v 1.27 2005/01/12 16:41:14 jlam Exp $
+# $NetBSD: sunpro.mk,v 1.28 2005/01/12 17:27:50 jlam Exp $
.if !defined(COMPILER_SUNPRO_MK)
COMPILER_SUNPRO_MK= defined
@@ -7,31 +7,28 @@ COMPILER_SUNPRO_MK= defined
SUNWSPROBASE?= /opt/SUNWspro
-# LANGUAGES.<compiler> is the list of supported languages by the compiler.
-# _LANGUAGES.<compiler> is ${LANGUAGES.<compiler>} restricted to the ones
-# requested by the package in USE_LANGUAGES.
+# LANGUAGES.<compiler> is the list of supported languages by the
+# compiler.
#
-LANGUAGES.sunpro= c c++
-_LANGUAGES.sunpro= # empty
-.for _lang_ in ${USE_LANGUAGES}
-_LANGUAGES.sunpro+= ${LANGUAGES.sunpro:M${_lang_}}
-.endfor
+LANGUAGES.sunpro= # empty
_SUNPRO_DIR= ${WRKDIR}/.sunpro
_SUNPRO_VARS= # empty
.if exists(${SUNWSPROBASE}/bin/cc)
-_SUNPRO_VARS+= CC
-_SUNPRO_CC= ${_SUNPRO_DIR}/bin/cc
-_ALIASES.CC= cc
-CCPATH= ${SUNWSPROBASE}/bin/cc
-PKG_CC:= ${_SUNPRO_CC}
+LANGUAGES.sunpro+= c
+_SUNPRO_VARS+= CC
+_SUNPRO_CC= ${_SUNPRO_DIR}/bin/cc
+_ALIASES.CC= cc
+CCPATH= ${SUNWSPROBASE}/bin/cc
+PKG_CC:= ${_SUNPRO_CC}
.endif
.if exists(${SUNWSPROBASE}/bin/CC)
-_SUNPRO_VARS+= CXX
-_SUNPRO_CXX= ${_SUNPRO_DIR}/bin/CC
-_ALIASES.CXX= CC c++
-CXXPATH= ${SUNWSPROBASE}/bin/CC
-PKG_CXX:= ${_SUNPRO_CXX}
+LANGUAGES.sunpro+= c++
+_SUNPRO_VARS+= CXX
+_SUNPRO_CXX= ${_SUNPRO_DIR}/bin/CC
+_ALIASES.CXX= CC c++
+CXXPATH= ${SUNWSPROBASE}/bin/CC
+PKG_CXX:= ${_SUNPRO_CXX}
.endif
_COMPILER_STRIP_VARS+= ${_SUNPRO_VARS}
@@ -52,6 +49,14 @@ CC_VERSION_STRING?= ${CC_VERSION}
CC_VERSION?= cc: Sun C
.endif
+# _LANGUAGES.<compiler> is ${LANGUAGES.<compiler>} restricted to the
+# ones requested by the package in USE_LANGUAGES.
+#
+_LANGUAGES.sunpro= # empty
+.for _lang_ in ${USE_LANGUAGES}
+_LANGUAGES.sunpro+= ${LANGUAGES.sunpro:M${_lang_}}
+.endfor
+
# Prepend the path to the compiler to the PATH.
.if !empty(_LANGUAGES.sunpro)
PREPEND_PATH+= ${_SUNPRO_DIR}/bin
diff --git a/mk/compiler/xlc.mk b/mk/compiler/xlc.mk
index 9b0aa91f277..acb75386696 100644
--- a/mk/compiler/xlc.mk
+++ b/mk/compiler/xlc.mk
@@ -1,4 +1,4 @@
-# $NetBSD: xlc.mk,v 1.8 2005/01/12 15:32:01 jlam Exp $
+# $NetBSD: xlc.mk,v 1.9 2005/01/12 17:27:50 jlam Exp $
.if !defined(COMPILER_XLC_MK)
COMPILER_XLC_MK= defined
@@ -25,9 +25,6 @@ _XLC_CC= ${_XLC_DIR}/bin/xlc
_ALIASES.CC= cc xlc
CCPATH= ${XLCBASE}/bin/xlc
PKG_CC:= ${_XLC_CC}
-. if !empty(CC:M*gcc)
-CC:= ${PKG_CC:T} # ${CC} should be named "xlc".
-. endif
.endif
.if exists(${XLCBASE}/bin/xlc++)
_XLC_VARS+= CXX
@@ -35,9 +32,6 @@ _XLC_CXX= ${_XLC_DIR}/bin/xlc++
_ALIASES.CXX= c++ xlc++
CXXPATH= ${XLCBASE}/bin/xlc++
PKG_CXX:= ${_XLC_CXX}
-. if !empty(CXX:M*g++)
-CXX:= ${PKG_CXX:T} # ${CXX} should be named "xlc++".
-. endif
.endif
_COMPILER_STRIP_VARS+= ${_XLC_VARS}