summaryrefslogtreecommitdiff
path: root/lang
diff options
context:
space:
mode:
authorjlam <jlam@pkgsrc.org>2003-11-25 19:30:21 +0000
committerjlam <jlam@pkgsrc.org>2003-11-25 19:30:21 +0000
commit5859da67ecbf46a8247aa496659812c2d08074ec (patch)
treeb5c238a71bb293fd47efde132d48e6303398b674 /lang
parent87dbaa95f1c13ae2371ef1ed76ce58797d50872e (diff)
downloadpkgsrc-5859da67ecbf46a8247aa496659812c2d08074ec.tar.gz
Make PERL5_SUB_* public so that they may be used in buildlink2.mk files
and also in package Makefiles.
Diffstat (limited to 'lang')
-rw-r--r--lang/perl5/buildlink2.mk39
-rw-r--r--lang/perl5/module.mk41
2 files changed, 40 insertions, 40 deletions
diff --git a/lang/perl5/buildlink2.mk b/lang/perl5/buildlink2.mk
index c724be3642e..dea8712be75 100644
--- a/lang/perl5/buildlink2.mk
+++ b/lang/perl5/buildlink2.mk
@@ -1,4 +1,4 @@
-# $NetBSD: buildlink2.mk,v 1.6 2003/09/13 08:22:07 jlam Exp $
+# $NetBSD: buildlink2.mk,v 1.7 2003/11/25 19:30:21 jlam Exp $
.if !defined(PERL5_BUILDLINK2_MK)
PERL5_BUILDLINK2_MK= # defined
@@ -20,6 +20,43 @@ EVAL_PREFIX+= BUILDLINK_PREFIX.perl=perl
BUILDLINK_PREFIX.perl_DEFAULT= ${LOCALBASE}
PERL5?= ${BUILDLINK_PREFIX.perl}/bin/perl
+_PERL5_SITEVARS= \
+ INSTALLSITEBIN INSTALLSITELIB INSTALLSITEARCH \
+ INSTALLSITEMAN1DIR INSTALLSITEMAN3DIR \
+ SITELIBEXP SITEARCHEXP
+
+_PERL5_SITEVAR.INSTALLSITEBIN= installsitebin
+_PERL5_SITEVAR.INSTALLSITELIB= installsitelib
+_PERL5_SITEVAR.INSTALLSITEARCH= installsitearch
+_PERL5_SITEVAR.INSTALLSITEMAN1DIR= installsiteman1dir
+_PERL5_SITEVAR.INSTALLSITEMAN3DIR= installsiteman3dir
+_PERL5_SITEVAR.SITELIBEXP= sitelibexp
+_PERL5_SITEVAR.SITEARCHEXP= sitearchexp
+
+.if !defined(_PERL5_SITEPREFIX)
+. if exists(${PERL5})
+_PERL5_PREFIX!= \
+ eval `${PERL5} -V:prefix 2>/dev/null`; ${ECHO} $$prefix
+_PERL5_SITEPREFIX!= \
+ eval `${PERL5} -V:siteprefix 2>/dev/null`; ${ECHO} $$siteprefix
+MAKEFLAGS+= _PERL5_PREFIX="${_PERL5_PREFIX}"
+MAKEFLAGS+= _PERL5_SITEPREFIX="${_PERL5_SITEPREFIX}"
+
+. for _var_ in ${_PERL5_SITEVARS}
+PERL5_SUB_${_var_}!= \
+ eval `${PERL5} -V:${_PERL5_SITEVAR.${_var_}} 2>/dev/null`; \
+ ${ECHO} $${${_PERL5_SITEVAR.${_var_}}} | \
+ ${SED} -e "s,^${_PERL5_SITEPREFIX}/,,"
+MAKEFLAGS+= PERL5_SUB_${_var_}="${PERL5_SUB_${_var_}}"
+. endfor
+PERL5_SUB_INSTALLSCRIPT!= \
+ eval `${PERL5} -V:installscript 2>/dev/null`; \
+ ${ECHO} $$installscript | \
+ ${SED} -e "s,^${_PERL5_PREFIX}/,,"
+MAKEFLAGS+= PERL5_SUB_INSTALLSCRIPT="${PERL5_SUB_INSTALLSCRIPT}"
+. endif
+.endif
+
BUILDLINK_FILES.perl= \
${PERL5_ARCHLIB:S/^${BUILDLINK_PREFIX.perl}\///}/CORE/* \
${PERL5_ARCHLIB:S/^${BUILDLINK_PREFIX.perl}\///}/auto/DynaLoader/DynaLoader.a
diff --git a/lang/perl5/module.mk b/lang/perl5/module.mk
index 3f46f4859be..49ef848b7e6 100644
--- a/lang/perl5/module.mk
+++ b/lang/perl5/module.mk
@@ -1,4 +1,4 @@
-# $NetBSD: module.mk,v 1.24 2003/11/25 17:45:56 jlam Exp $
+# $NetBSD: module.mk,v 1.25 2003/11/25 19:30:21 jlam Exp $
#
# This Makefile fragment is intended to be included by packages that build
# and install perl5 modules.
@@ -68,48 +68,11 @@ do-configure: perl5-configure
. endif
.endif
-_PERL5_SITEVARS= \
- INSTALLSITEBIN INSTALLSITELIB INSTALLSITEARCH \
- INSTALLSITEMAN1DIR INSTALLSITEMAN3DIR \
- SITELIBEXP SITEARCHEXP
-
-_PERL5_SITEVAR.INSTALLSITEBIN= installsitebin
-_PERL5_SITEVAR.INSTALLSITELIB= installsitelib
-_PERL5_SITEVAR.INSTALLSITEARCH= installsitearch
-_PERL5_SITEVAR.INSTALLSITEMAN1DIR= installsiteman1dir
-_PERL5_SITEVAR.INSTALLSITEMAN3DIR= installsiteman3dir
-_PERL5_SITEVAR.SITELIBEXP= sitelibexp
-_PERL5_SITEVAR.SITEARCHEXP= sitearchexp
-
-.if !defined(_PERL5_SITEPREFIX)
-. if exists(${PERL5})
-_PERL5_PREFIX!= \
- eval `${PERL5} -V:prefix 2>/dev/null`; ${ECHO} $$prefix
-_PERL5_SITEPREFIX!= \
- eval `${PERL5} -V:siteprefix 2>/dev/null`; ${ECHO} $$siteprefix
-MAKEFLAGS+= _PERL5_PREFIX="${_PERL5_PREFIX}"
-MAKEFLAGS+= _PERL5_SITEPREFIX="${_PERL5_SITEPREFIX}"
-
-. for _var_ in ${_PERL5_SITEVARS}
-_PERL5_SUB_${_var_}!= \
- eval `${PERL5} -V:${_PERL5_SITEVAR.${_var_}} 2>/dev/null`; \
- ${ECHO} $${${_PERL5_SITEVAR.${_var_}}} | \
- ${SED} -e "s,^${_PERL5_SITEPREFIX}/,,"
-MAKEFLAGS+= _PERL5_SUB_${_var_}="${_PERL5_SUB_${_var_}}"
-. endfor
-_PERL5_SUB_INSTALLSCRIPT!= \
- eval `${PERL5} -V:installscript 2>/dev/null`; \
- ${ECHO} $$installscript | \
- ${SED} -e "s,^${_PERL5_PREFIX}/,,"
-MAKEFLAGS+= _PERL5_SUB_INSTALLSCRIPT="${_PERL5_SUB_INSTALLSCRIPT}"
-. endif
-.endif
-#
# Repoint all of the site-specific variables to be under the perl5
# module's ${PREFIX}.
#
.for _var_ in ${_PERL5_SITEVARS} INSTALLSCRIPT
-PERL5_${_var_}= ${PREFIX}/${_PERL5_SUB_${_var_}}
+PERL5_${_var_}= ${PREFIX}/${PERL5_SUB_${_var_}}
MAKE_FLAGS+= ${_var_}="${PERL5_${_var_}}"
.endfor
#