summaryrefslogtreecommitdiff
path: root/pkgtools/perl-mk/pkg/INSTALL
blob: 46a0e5793f3da94a5a5a3676a5131bc61fc72c77 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#!/bin/sh
#
# $NetBSD: INSTALL,v 1.1 2001/04/22 06:25:19 jlam Exp $

PKGNAME=$1
STAGE=$2

PERL5="@PERL5@"
RM="@RM@"

BSD_PERL_MK=${PKG_PREFIX}/share/mk/bsd.perl.mk

case ${STAGE} in
PRE-INSTALL)
	;;

POST-INSTALL)
	# Generate bsd.perl.mk with hardcoded values for PERL5_* make
	# variables for optimization purposes.
	#
	${RM} -f ${BSD_PERL_MK}
	eval `${PERL5} -V:installsitelib 2>/dev/null`
	echo PERL5_SITELIB=${installsitelib} >> ${BSD_PERL_MK}
	eval `${PERL5} -V:installsitearch 2>/dev/null`
	echo PERL5_SITEARCH=${installsitearch} >> ${BSD_PERL_MK}
	eval `${PERL5} -V:installarchlib 2>/dev/null`
	echo PERL5_ARCHLIB=${installarchlib} >> ${BSD_PERL_MK}
	;;

*)
	echo "Unexpected argument: ${STAGE}"
	exit 1
	;;
esac
exit 0