summaryrefslogtreecommitdiff
path: root/mk
diff options
context:
space:
mode:
authorjlam <jlam@pkgsrc.org>2004-11-17 22:55:14 +0000
committerjlam <jlam@pkgsrc.org>2004-11-17 22:55:14 +0000
commit55ba984801225acce90bdd662fb480eb895c1ce7 (patch)
treefbf32f7ffe22f6860e17719dbbbd229fb4d4665a /mk
parent18efda262a546e61ba13d74669871d6ea9f25a06 (diff)
downloadpkgsrc-55ba984801225acce90bdd662fb480eb895c1ce7.tar.gz
Move selection of the default perl58 (whether it is threaded or not) into
bsd.pkg.mk. lang/perl58 now always builds perl58, while lang/perl58-thread builds perl58-thread (POLS). Fixes PR pkg/28343.
Diffstat (limited to 'mk')
-rw-r--r--mk/bsd.pkg.mk12
1 files changed, 11 insertions, 1 deletions
diff --git a/mk/bsd.pkg.mk b/mk/bsd.pkg.mk
index feeb6db91f6..cf47afa2595 100644
--- a/mk/bsd.pkg.mk
+++ b/mk/bsd.pkg.mk
@@ -1,4 +1,4 @@
-# $NetBSD: bsd.pkg.mk,v 1.1539 2004/11/16 18:04:00 tv Exp $
+# $NetBSD: bsd.pkg.mk,v 1.1540 2004/11/17 22:55:14 jlam Exp $
#
# This file is in the public domain.
#
@@ -306,7 +306,17 @@ USE_PERL5:= run
_PERL5_DEPMETHOD= DEPENDS
. endif
_PERL5_DEPENDS= {perl>=${_PERL5_REQD},perl-thread>=${_PERL5_REQD}}
+#
+# On platforms that have native pthreads, default to installing the
+# threaded perl. This can be overridden by explicitly setting
+# PERL5_USE_THREADS.
+#
+. if exists(/usr/include/pthread.h) && \
+ !empty(PREFER_NATIVE_PTHREADS:M[yY][eE][sS])
+PERL5_PKGSRCDIR?= ../../lang/perl58-thread
+. else
PERL5_PKGSRCDIR?= ../../lang/perl58
+. endif
. if !defined(BUILDLINK_DEPENDS.perl)
${_PERL5_DEPMETHOD}+= ${_PERL5_DEPENDS}:${PERL5_PKGSRCDIR}
. endif