View | Details | Raw Unified | Return to bug 55515 | Differences between
and this patch

Collapse All | Expand All

(-)bsd.port.mk (-158 / +17 lines)
Lines 208-240 Link Here
208
# USE_ICONV		- Says that the port uses libiconv.
208
# USE_ICONV		- Says that the port uses libiconv.
209
# USE_GETTEXT		- Says that the port uses GNU gettext (libintl).
209
# USE_GETTEXT		- Says that the port uses GNU gettext (libintl).
210
##
210
##
211
# USE_PERL5		- Says that the port uses perl5 in one or more of the extract,
212
#                         patch, build, install or run phases.
213
# USE_PERL5_BUILD	- Says that the port uses perl5 in one or more of the extract,
214
#                         patch, build or install phases.
215
# USE_PERL5_RUN		- Says that the port uses perl5 for running.
216
# PERL5			- Set to full path of perl5, either in the system or
217
#				  installed from a port.
218
# PERL			- Set to full path of perl5, either in the system or
219
#				  installed from a port, but without the version number.
220
#				  Use this if you need to replace "#!" lines in scripts.
221
# PERL_VERSION	- Full version of perl5 (see below for current value).
222
# PERL_VER		- Short version of perl5 (see below for current value).
223
# PERL_LEVEL	- Perl version as an integer of the form MNNNPP, where
224
#					M is major version, N is minor version, and P is
225
#					the patch level. E.g., PERL_VERSION=5.6.1 would give
226
#					a PERL_LEVEL of 500601. This can be used in comparisons
227
#					to determine if the version of perl is high enough,
228
#					whether a particular dependency is needed, etc.
229
# PERL_ARCH		- Directory name of architecture dependent libraries
230
#				  (value: ${ARCH}-freebsd).
231
# PERL_PORT		- Name of the perl port that is installed
232
#				  (value: perl5)
233
# SITE_PERL		- Directory name where site specific perl packages go.
234
#					This value is added to PLIST_SUB.
235
# PERL_MODBUILD		- Use Module::Build to configure, build and install
236
#			  port.
237
#
238
# USE_GHOSTSCRIPT	- Says that the port needs ghostscript to both
211
# USE_GHOSTSCRIPT	- Says that the port needs ghostscript to both
239
#					build and run.  Default: not set.
212
#					build and run.  Default: not set.
240
# USE_GHOSTSCRIPT_BUILD	- Says that the port needs ghostscript to build.
213
# USE_GHOSTSCRIPT_BUILD	- Says that the port needs ghostscript to build.
Lines 288-293 Link Here
288
#					See bsd.autotools.mk for more details.
261
#					See bsd.autotools.mk for more details.
289
#					XXX: not currently in active use - this is a placeholder.
262
#					XXX: not currently in active use - this is a placeholder.
290
##
263
##
264
# USE_PERL5_BUILD	- Says that the port uses perl5 in one or more of
265
# 					  the extract, patch, build or install phases.
266
# USE_PERL5_RUN	- Says that the port uses perl5 for running.
267
# USE_PERL5		- Implements both USE_PERL5_BUILD and USE_PERL5_RUN.
268
# 				  (See bsd.perl.mk for full list of variables and 
269
# 				  CONFIGURE_SCRIPT, CONFIGURE_ARGS defaults.)
270
##
291
# USE_JAVA		- Says that the port relies on the Java language.
271
# USE_JAVA		- Says that the port relies on the Java language.
292
#				  Implies inclusion of bsd.java.mk.  (Also see
272
#				  Implies inclusion of bsd.java.mk.  (Also see
293
#				  that file for more information on USE_JAVA_*).
273
#				  that file for more information on USE_JAVA_*).
Lines 667-685 Link Here
667
#				  configure stage will not do anything if this is not set.
647
#				  configure stage will not do anything if this is not set.
668
# GNU_CONFIGURE	- Set if you are using GNU configure (optional).  Implies
648
# GNU_CONFIGURE	- Set if you are using GNU configure (optional).  Implies
669
#				  HAS_CONFIGURE.
649
#				  HAS_CONFIGURE.
670
# PERL_CONFIGURE - Configure using Perl's MakeMaker.  Implies USE_PERL5.
671
# CONFIGURE_WRKSRC - Directory to run configure in (default: ${WRKSRC}).
650
# CONFIGURE_WRKSRC - Directory to run configure in (default: ${WRKSRC}).
672
# CONFIGURE_SCRIPT - Name of configure script, relative to ${CONFIGURE_WRKSRC}
651
# CONFIGURE_SCRIPT - Name of configure script, relative to ${CONFIGURE_WRKSRC}
673
#				  (default: "Makefile.PL" if PERL_CONFIGURE is set,
652
#				  (default: "configure").
674
#				  "configure" otherwise).
675
# CONFIGURE_TARGET - The name of target to call when GNU_CONFIGURE is
653
# CONFIGURE_TARGET - The name of target to call when GNU_CONFIGURE is
676
#				  defined (default: ${MACHINE_ARCH}-portbld-freebsd${OSREL}).
654
#				  defined (default: ${MACHINE_ARCH}-portbld-freebsd${OSREL}).
677
# CONFIGURE_ARGS - Pass these args to configure if ${HAS_CONFIGURE} is set
655
# CONFIGURE_ARGS - Pass these args to configure if ${HAS_CONFIGURE} is set
678
#				  (default: "--prefix=${PREFIX} ${CONFIGURE_TARGET}" if
656
#				  (default: "--prefix=${PREFIX} ${CONFIGURE_TARGET}" if
679
#				  GNU_CONFIGURE is set, "CC=${CC} CCFLAGS=${CFLAGS}
657
#				  GNU_CONFIGURE is set, empty otherwise).
680
#				  PREFIX=${PREFIX} INSTALLPRIVLIB=${PREFIX}/lib
681
#				  INSTALLARCHLIB=${PREFIX}/lib" if PERL_CONFIGURE is set,
682
#				  empty otherwise).
683
# CONFIGURE_ENV - Pass these env (shell-like) to configure if
658
# CONFIGURE_ENV - Pass these env (shell-like) to configure if
684
#				  ${HAS_CONFIGURE} is set.
659
#				  ${HAS_CONFIGURE} is set.
685
# CONFIGURE_LOG - The name of configure log file (default: config.log).
660
# CONFIGURE_LOG - The name of configure log file (default: config.log).
Lines 1062-1128 Link Here
1062
RUN_DEPENDS+=	${APXS}:${PORTSDIR}/${APACHE_PORT}
1037
RUN_DEPENDS+=	${APXS}:${PORTSDIR}/${APACHE_PORT}
1063
.endif
1038
.endif
1064
1039
1065
.if ${OSVERSION} >= 502100
1066
PERL_VERSION?=	5.8.4
1067
PERL_VER?=	5.8.4
1068
.else
1069
.if ${OSVERSION} >= 500032
1070
PERL_VERSION?=	5.6.1
1071
PERL_VER?=		5.6.1
1072
.else
1073
.if ${OSVERSION} >= 500007
1074
PERL_VERSION?=	5.6.0
1075
PERL_VER?=		5.6.0
1076
.else
1077
.if ${OSVERSION} >= 300000
1078
PERL_VERSION?=	5.00503
1079
.else
1080
PERL_VERSION?=	5.00502
1081
.endif
1082
PERL_VER?=		5.005
1083
.endif
1084
.endif
1085
.endif
1086
1087
.if !defined(PERL_LEVEL) && defined(PERL_VERSION)
1088
perl_major=		${PERL_VERSION:C|^([1-9]+).*|\1|}
1089
_perl_minor=	00${PERL_VERSION:C|^([1-9]+)\.([0-9]+).*|\2|}
1090
perl_minor=		${_perl_minor:C|^.*(...)|\1|}
1091
.if ${perl_minor} >= 100
1092
perl_minor=		${PERL_VERSION:C|^([1-9]+)\.([0-9][0-9][0-9]).*|\2|}
1093
perl_patch=		${PERL_VERSION:C|^.*(..)|\1|}
1094
.else # ${perl_minor} < 100
1095
_perl_patch=	0${PERL_VERSION:C|^([1-9]+)\.([0-9]+)\.*|0|}
1096
perl_patch=		${_perl_patch:C|^.*(..)|\1|}
1097
.endif # ${perl_minor} < 100
1098
PERL_LEVEL=	${perl_major}${perl_minor}${perl_patch}
1099
.else
1100
PERL_LEVEL=0
1101
.endif # !defined(PERL_LEVEL) && defined(PERL_VERSION)
1102
1103
.if ${PERL_LEVEL} >= 500600
1104
PERL_ARCH?=		mach
1105
.else
1106
PERL_ARCH?=		${ARCH}-freebsd
1107
.endif
1108
1109
.if ${PERL_LEVEL} >= 500800
1110
PERL_PORT?=	perl5.8
1111
.else
1112
PERL_PORT?=	perl5
1113
.endif
1114
1115
SITE_PERL_REL?=	lib/perl5/site_perl/${PERL_VER}
1116
SITE_PERL?=	${LOCALBASE}/${SITE_PERL_REL}
1117
1118
.if ${PERL_LEVEL} < 500600
1119
PERL5=		/usr/bin/perl${PERL_VERSION}
1120
PERL=		/usr/bin/perl
1121
.else
1122
PERL5=		${LOCALBASE}/bin/perl${PERL_VERSION}
1123
PERL=		${LOCALBASE}/bin/perl
1124
.endif
1125
1126
# XXX: (not yet): .if defined(USE_AUTOTOOLS)
1040
# XXX: (not yet): .if defined(USE_AUTOTOOLS)
1127
# .include "${PORTSDIR}/Mk/bsd.autotools.mk"
1041
# .include "${PORTSDIR}/Mk/bsd.autotools.mk"
1128
# XXX: (not yet): .endif
1042
# XXX: (not yet): .endif
Lines 1155-1160 Link Here
1155
.include "${PORTSDIR}/Mk/bsd.ruby.mk"
1069
.include "${PORTSDIR}/Mk/bsd.ruby.mk"
1156
.endif
1070
.endif
1157
1071
1072
.if defined(USE_PERL5) || defined(PERL_CONFIGURE) || defined(USE_PERL5_BUILD) || defined(USE_PERL5_RUN) || defined(PERL_MODBUILD) || ${PORTNAME} == "perl"
1073
.include "${PORTSDIR}/Mk/bsd.perl.mk"
1074
.endif
1075
1158
.if defined(USE_QT) || defined(USE_QT2) || defined(USE_QT_VER) || defined(USE_KDELIBS_VER) || defined(USE_KDEBASE_VER)
1076
.if defined(USE_QT) || defined(USE_QT2) || defined(USE_QT_VER) || defined(USE_KDELIBS_VER) || defined(USE_KDEBASE_VER)
1159
.include "${PORTSDIR}/Mk/bsd.kde.mk"
1077
.include "${PORTSDIR}/Mk/bsd.kde.mk"
1160
.endif
1078
.endif
Lines 1431-1474 Link Here
1431
.endif
1349
.endif
1432
.endif
1350
.endif
1433
1351
1434
PLIST_SUB+=		PERL_VERSION=${PERL_VERSION} \
1435
				PERL_VER=${PERL_VER} \
1436
				PERL_ARCH=${PERL_ARCH} \
1437
				SITE_PERL=${SITE_PERL_REL}
1438
1439
.if defined(PERL_MODBUILD)
1440
PERL_CONFIGURE=		yes
1441
CONFIGURE_SCRIPT?=	Build.PL
1442
.if ${PORTNAME} != Module-Build
1443
BUILD_DEPENDS+=		${SITE_PERL}/Module/Build.pm:${PORTSDIR}/devel/p5-Module-Build
1444
.endif
1445
ALL_TARGET?=
1446
PL_BUILD?=		Build
1447
CONFIGURE_ARGS+= \
1448
	install_path=lib="${PREFIX}/${SITE_PERL_REL}" \
1449
	install_path=arch="${PREFIX}/${SITE_PERL_REL}/${PERL_ARCH}" \
1450
	install_path=script="${PREFIX}/bin" \
1451
	install_path=bin="${PREFIX}/bin" \
1452
	install_path=libdoc="${MAN3PREFIX}/man/man3" \
1453
	install_path=bindoc="${MAN1PREFIX}/man/man1"
1454
.endif
1455
1456
.if defined(PERL_CONFIGURE)
1457
USE_PERL5=	yes
1458
USE_REINPLACE=yes
1459
.endif
1460
1461
.if ${PERL_LEVEL} >= 500600
1462
.if defined(USE_PERL5) || defined(USE_PERL5_BUILD)
1463
EXTRACT_DEPENDS+=${PERL5}:${PORTSDIR}/lang/${PERL_PORT}
1464
PATCH_DEPENDS+=	${PERL5}:${PORTSDIR}/lang/${PERL_PORT}
1465
BUILD_DEPENDS+=	${PERL5}:${PORTSDIR}/lang/${PERL_PORT}
1466
.endif
1467
.if defined(USE_PERL5) || defined(USE_PERL5_RUN)
1468
RUN_DEPENDS+=	${PERL5}:${PORTSDIR}/lang/${PERL_PORT}
1469
.endif
1470
.endif
1471
1472
.if defined(USE_MYSQL)
1352
.if defined(USE_MYSQL)
1473
DEFAULT_MYSQL_VER?=	40
1353
DEFAULT_MYSQL_VER?=	40
1474
# MySQL client version currently supported.
1354
# MySQL client version currently supported.
Lines 1535-1540 Link Here
1535
.include "${PORTSDIR}/Mk/bsd.python.mk"
1415
.include "${PORTSDIR}/Mk/bsd.python.mk"
1536
.endif
1416
.endif
1537
1417
1418
.if defined(USE_PERL5_BUILD) || defined(USE_PERL5_RUN)
1419
.include "${PORTSDIR}/Mk/bsd.perl.mk"
1420
.endif
1421
1538
.if exists(${PORTSDIR}/../Makefile.inc)
1422
.if exists(${PORTSDIR}/../Makefile.inc)
1539
.include "${PORTSDIR}/../Makefile.inc"
1423
.include "${PORTSDIR}/../Makefile.inc"
1540
USE_SUBMAKE=	yes
1424
USE_SUBMAKE=	yes
Lines 2332-2345 Link Here
2332
LATEST_LINK?=		${PKGBASE}
2216
LATEST_LINK?=		${PKGBASE}
2333
PKGLATESTFILE=		${PKGLATESTREPOSITORY}/${LATEST_LINK}${PKG_SUFX}
2217
PKGLATESTFILE=		${PKGLATESTREPOSITORY}/${LATEST_LINK}${PKG_SUFX}
2334
2218
2335
.if defined(PERL_CONFIGURE)
2336
CONFIGURE_ARGS+=	CC="${CC}" CCFLAGS="${CFLAGS}" PREFIX="${PREFIX}" \
2337
			INSTALLPRIVLIB="${PREFIX}/lib" INSTALLARCHLIB="${PREFIX}/lib"
2338
CONFIGURE_SCRIPT?=	Makefile.PL
2339
MAN3PREFIX?=		${PREFIX}/lib/perl5/${PERL_VERSION}
2340
.undef HAS_CONFIGURE
2341
.endif
2342
2343
CONFIGURE_SCRIPT?=	configure
2219
CONFIGURE_SCRIPT?=	configure
2344
CONFIGURE_TARGET?=	${MACHINE_ARCH}-portbld-freebsd${OSREL}
2220
CONFIGURE_TARGET?=	${MACHINE_ARCH}-portbld-freebsd${OSREL}
2345
CONFIGURE_LOG?=		config.log
2221
CONFIGURE_LOG?=		config.log
Lines 3047-3061 Link Here
3047
			 ${FALSE}; \
2923
			 ${FALSE}; \
3048
		fi)
2924
		fi)
3049
.endif
2925
.endif
3050
.if defined(PERL_CONFIGURE)
3051
	@cd ${CONFIGURE_WRKSRC} && \
3052
		${SETENV} ${CONFIGURE_ENV} \
3053
		${PERL5} ./${CONFIGURE_SCRIPT} ${CONFIGURE_ARGS}
3054
.if !defined(PERL_MODBUILD)
3055
	@cd ${CONFIGURE_WRKSRC} && \
3056
		${PERL5} -pi -e 's/ doc_(perl|site|\$$\(INSTALLDIRS\))_install$$//' Makefile
3057
.endif
3058
.endif
3059
.if defined(USE_IMAKE)
2926
.if defined(USE_IMAKE)
3060
	@(cd ${CONFIGURE_WRKSRC}; ${SETENV} ${MAKE_ENV} ${XMKMF})
2927
	@(cd ${CONFIGURE_WRKSRC}; ${SETENV} ${MAKE_ENV} ${XMKMF})
3061
.endif
2928
.endif
Lines 3068-3080 Link Here
3068
.if defined(USE_GMAKE)
2935
.if defined(USE_GMAKE)
3069
	@(cd ${BUILD_WRKSRC}; ${SETENV} ${MAKE_ENV} ${GMAKE} ${MAKE_FLAGS} ${MAKEFILE} ${MAKE_ARGS} ${ALL_TARGET})
2936
	@(cd ${BUILD_WRKSRC}; ${SETENV} ${MAKE_ENV} ${GMAKE} ${MAKE_FLAGS} ${MAKEFILE} ${MAKE_ARGS} ${ALL_TARGET})
3070
.else
2937
.else
3071
.if defined(PERL_MODBUILD)
3072
	@(cd ${BUILD_WRKSRC}; ${SETENV} ${MAKE_ENV} ${PERL5} ${PL_BUILD} ${MAKE_ARGS} ${ALL_TARGET})
3073
.else
3074
	@(cd ${BUILD_WRKSRC}; ${SETENV} ${MAKE_ENV} ${MAKE} ${MAKE_FLAGS} ${MAKEFILE} ${MAKE_ARGS} ${ALL_TARGET})
2938
	@(cd ${BUILD_WRKSRC}; ${SETENV} ${MAKE_ENV} ${MAKE} ${MAKE_FLAGS} ${MAKEFILE} ${MAKE_ARGS} ${ALL_TARGET})
3075
.endif
2939
.endif
3076
.endif
2940
.endif
3077
.endif
3078
2941
3079
# Check conflicts
2942
# Check conflicts
3080
2943
Lines 3126-3140 Link Here
3126
.endif
2989
.endif
3127
.endif
2990
.endif
3128
.else # !defined(USE_GMAKE)
2991
.else # !defined(USE_GMAKE)
3129
.if defined(PERL_MODBUILD)
3130
	@(cd ${BUILD_WRKSRC}; ${SETENV} ${MAKE_ENV} ${PERL5} ${PL_BUILD} ${MAKE_ARGS} ${INSTALL_TARGET})
3131
.else
3132
	@(cd ${INSTALL_WRKSRC} && ${SETENV} ${MAKE_ENV} ${MAKE} ${MAKE_FLAGS} ${MAKEFILE} ${MAKE_ARGS} ${INSTALL_TARGET})
2992
	@(cd ${INSTALL_WRKSRC} && ${SETENV} ${MAKE_ENV} ${MAKE} ${MAKE_FLAGS} ${MAKEFILE} ${MAKE_ARGS} ${INSTALL_TARGET})
3133
.if defined(USE_IMAKE) && !defined(NO_INSTALL_MANPAGES)
2993
.if defined(USE_IMAKE) && !defined(NO_INSTALL_MANPAGES)
3134
	@(cd ${INSTALL_WRKSRC} && ${SETENV} ${MAKE_ENV} ${MAKE} ${MAKE_FLAGS} ${MAKEFILE} ${MAKE_ARGS} install.man)
2994
	@(cd ${INSTALL_WRKSRC} && ${SETENV} ${MAKE_ENV} ${MAKE} ${MAKE_FLAGS} ${MAKEFILE} ${MAKE_ARGS} install.man)
3135
.if ${XFREE86_HTML_MAN:L} == yes
2995
.if ${XFREE86_HTML_MAN:L} == yes
3136
	@${MKHTMLINDEX} ${PREFIX}/lib/X11/doc/html
2996
	@${MKHTMLINDEX} ${PREFIX}/lib/X11/doc/html
3137
.endif
3138
.endif
2997
.endif
3139
.endif
2998
.endif
3140
.endif
2999
.endif

Return to bug 55515