summaryrefslogtreecommitdiff
path: root/mk/compiler
diff options
context:
space:
mode:
authorjlam <jlam>2004-02-09 05:50:03 +0000
committerjlam <jlam>2004-02-09 05:50:03 +0000
commit1ac7e939a7f623e01ae26095536fa5e98359f1b5 (patch)
tree20b9604b2d0b7d21e5e01ce82c27f0ee5780c70d /mk/compiler
parenta62f61fcd4d38758335420ecb9899f604270d20a (diff)
downloadpkgsrc-1ac7e939a7f623e01ae26095536fa5e98359f1b5.tar.gz
Apparently, GCC isn't the only compiler that tries to be clever by checking
with what path it was invoked. Copy the driver script trick from gcc.mk into mipspro.mk and sunpro.mk.
Diffstat (limited to 'mk/compiler')
-rw-r--r--mk/compiler/mipspro.mk9
-rw-r--r--mk/compiler/sunpro.mk9
2 files changed, 12 insertions, 6 deletions
diff --git a/mk/compiler/mipspro.mk b/mk/compiler/mipspro.mk
index bf3d1a3862f..e3471d2e12a 100644
--- a/mk/compiler/mipspro.mk
+++ b/mk/compiler/mipspro.mk
@@ -1,4 +1,4 @@
-# $NetBSD: mipspro.mk,v 1.15 2004/02/08 02:59:14 jlam Exp $
+# $NetBSD: mipspro.mk,v 1.16 2004/02/09 05:50:03 jlam Exp $
.if !defined(COMPILER_MIPSPRO_MK)
COMPILER_MIPSPRO_MK= one
@@ -55,14 +55,17 @@ PATH:= ${_MIPSPRO_DIR}/bin:${PATH}
. endif
. endif
-# Create symlinks for the compiler into ${WRKDIR}.
+# Create compiler driver scripts in ${WRKDIR}.
. for _target_ in ${_MIPSPRO_LINKS}
. if !target(${${_target_}})
override-tools: ${${_target_}}
${${_target_}}:
${_PKG_SILENT}${_PKG_DEBUG}${MKDIR} ${.TARGET:H}
${_PKG_SILENT}${_PKG_DEBUG} \
- ${LN} -fs ${MIPSPROBASE}/bin/${${_target_}:T} ${.TARGET}
+ (${ECHO} '#!${TOOLS_SHELL}'; \
+ ${ECHO} 'exec ${MIPSPROBASE}/bin/${${_target_}:T} "$$@"'; \
+ ) > ${.TARGET}
+ ${_PKG_SILENT}${_PKG_DEBUG}${CHMOD} +x ${.TARGET}
. endif
. endfor
. endif # COMPILER_MIPSPRO_MK
diff --git a/mk/compiler/sunpro.mk b/mk/compiler/sunpro.mk
index a17fa0c7a9c..aa83002e394 100644
--- a/mk/compiler/sunpro.mk
+++ b/mk/compiler/sunpro.mk
@@ -1,4 +1,4 @@
-# $NetBSD: sunpro.mk,v 1.12 2004/02/08 02:59:14 jlam Exp $
+# $NetBSD: sunpro.mk,v 1.13 2004/02/09 05:50:03 jlam Exp $
.if !defined(COMPILER_SUNPRO_MK)
COMPILER_SUNPRO_MK= one
@@ -56,14 +56,17 @@ PATH:= ${_SUNPRO_DIR}/bin:${PATH}
. endif
. endif
-# Create symlinks for the compiler into ${WRKDIR}.
+# Create compiler driver scripts in ${WRKDIR}.
. for _target_ in ${_SUNPRO_LINKS}
. if !target(${${_target_}})
override-tools: ${${_target_}}
${${_target_}}:
${_PKG_SILENT}${_PKG_DEBUG}${MKDIR} ${.TARGET:H}
${_PKG_SILENT}${_PKG_DEBUG} \
- ${LN} -fs ${SUNWSPROBASE}/bin/${${_target_}:T} ${.TARGET}
+ (${ECHO} '#!${TOOLS_SHELL}'; \
+ ${ECHO} 'exec ${SUNWSPROBASE}/bin/${${_target_}:T} "$$@"'; \
+ ) > ${.TARGET}
+ ${_PKG_SILENT}${_PKG_DEBUG}${CHMOD} +x ${.TARGET}
. endif
. endfor
. endif # COMPILER_SUNPRO_MK