diff options
author | jperkin <jperkin@pkgsrc.org> | 2012-06-27 13:36:08 +0000 |
---|---|---|
committer | jperkin <jperkin@pkgsrc.org> | 2012-06-27 13:36:08 +0000 |
commit | 3cea6a2923f006b8d2262dc7810db89bd5c5c7c5 (patch) | |
tree | 7949bb7190ec0cd3c9d318605d0f3279b5654cea | |
parent | 91deaf10f45f248ca369ed754ea7598e203905ec (diff) | |
download | pkgsrc-3cea6a2923f006b8d2262dc7810db89bd5c5c7c5.tar.gz |
Ensure the Solaris native linker is used by default, avoids conflicts
where GNU ld is picked up first via $PATH.
-rw-r--r-- | mk/compiler.mk | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/mk/compiler.mk b/mk/compiler.mk index b7074d982e6..c8a28c4972c 100644 --- a/mk/compiler.mk +++ b/mk/compiler.mk @@ -1,4 +1,4 @@ -# $NetBSD: compiler.mk,v 1.75 2012/04/13 03:03:36 sbd Exp $ +# $NetBSD: compiler.mk,v 1.76 2012/06/27 13:36:08 jperkin Exp $ # # This Makefile fragment implements handling for supported C/C++/Fortran # compilers. @@ -131,6 +131,15 @@ _COMPILER_STRIP_VARS= # empty PKG_CPP:=${CPP} .endif +# Ensure the Solaris linker is used by default. +.if ${OPSYS} == "SunOS" +. if exists(/usr/ccs/bin/ld) +PKG_LD?= /usr/ccs/bin/ld +. elif exists(/usr/bin/ld) +PKG_LD?= /usr/bin/ld +. endif +.endif + # Strip the leading paths from the toolchain variables since we manipulate # the PATH to use the correct executable. # |