diff options
author | jperkin <jperkin> | 2012-06-27 13:36:08 +0000 |
---|---|---|
committer | jperkin <jperkin> | 2012-06-27 13:36:08 +0000 |
commit | 964b04ba173da3184213301721b41e6dc74e96f5 (patch) | |
tree | 7949bb7190ec0cd3c9d318605d0f3279b5654cea /mk/compiler.mk | |
parent | 7a0d07357eeefc89a7949a44fdd5e3372e7603a6 (diff) | |
download | pkgsrc-964b04ba173da3184213301721b41e6dc74e96f5.tar.gz |
Ensure the Solaris native linker is used by default, avoids conflicts
where GNU ld is picked up first via $PATH.
Diffstat (limited to 'mk/compiler.mk')
-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. # |