summaryrefslogtreecommitdiff
path: root/www/php4/Makefile.common
blob: d3f4558bd3fd2939c9e65d30f0c60512fe16deab (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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
# $NetBSD: Makefile.common,v 1.15 2001/06/13 06:20:28 explorer Exp $

DISTNAME=		php-${PHP_DIST_VERS}
PHP_DIST_VERS=		4.0.5
PHP_BASE_VERS=		${PHP_DIST_VERS}
PHP_VERS=		${PHP_BASE_VERS}
CATEGORIES+=		www php4
MASTER_SITES=		http://www.php.net/distributions/ \
			http://php3.de/distributions/ \
			ftp://ftp.php.net/pub/distributions/

MAINTAINER=		jlam@netbsd.org
HOMEPAGE=		http://www.php.net/

# Put this dependency here to compile in dbm support for all PHP4 modules.
DEPENDS+=               gdbm>=1.7.3:../../databases/gdbm

DISTINFO_FILE=		${.CURDIR}/../../www/php4/distinfo
FILESDIR=		${.CURDIR}/../../www/php4/files
PATCHDIR=		${.CURDIR}/../../www/php4/patches

# Location of installed PHP4 loadable modules under ${PREFIX}.
# This is derived from the value of `php-config --extension-dir`.
#
PHP_EXTENSION_DIR=	lib/php/extensions/no-debug-non-zts-20001222
PLIST_SUBST+=		PHP_EXTENSION_DIR=${PHP_EXTENSION_DIR}

USE_LIBTOOL=		# defined
LTCONFIG_OVERRIDE=	${WRKSRC}/ltconfig

.include "../../mk/bsd.prefs.mk"

PHP_CONFDIR?=		${LOCALBASE}/etc
MESSAGE_SUBST+=		PHP_CONFDIR=${PHP_CONFDIR}

.if ${OPSYS} == "SunOS"
DEPENDS+=		zlib-*:../../devel/zlib
.endif

# Here we configure only for what NetBSD ships.  We add the rest via modules.
#
GNU_CONFIGURE=		# defined

USE_LIBINTL=		# defined
.if exists(/usr/include/libintl.h)
GETTEXTDIR=		/usr
.else
GETTEXTDIR=		${LOCALBASE}
.endif

CONFIGURE_ARGS+=	--without-gd
CONFIGURE_ARGS+=	--without-mysql
CONFIGURE_ARGS+=	--without-pcre-regex
CONFIGURE_ARGS+=	--with-gdbm=${LOCALBASE}
CONFIGURE_ARGS+=	--with-gettext=${GETTEXTDIR}
CONFIGURE_ARGS+=	--with-yp
CONFIGURE_ARGS+=	--with-zlib
CONFIGURE_ARGS+=	--with-config-file-path=${PHP_CONFDIR}
CONFIGURE_ARGS+=	--with-system-regex
CONFIGURE_ARGS+=	--with-exec-dir=${PREFIX}/libexec/php4
CONFIGURE_ARGS+=	--enable-track-vars
CONFIGURE_ARGS+=	--enable-force-cgi-redirect
CONFIGURE_ARGS+=	--enable-discard-path
CONFIGURE_ARGS+=	--enable-memory-limit
CONFIGURE_ARGS+=	--enable-sysvsem
CONFIGURE_ARGS+=	--enable-sysvshm
CONFIGURE_ARGS+=	--enable-wddx
CONFIGURE_ARGS+=	--enable-sockets

# The following two modules are bogus to include, but we need it to maintain
# version/capability compatibility with older binary packages of ap-php4.
#
CONFIGURE_ARGS+=	--with-dbase
CONFIGURE_ARGS+=	--with-filepro

pre-configure: pre-common-configure

pre-common-configure:
	${LN} -sf ${WRKSRC}/libtool ${WRKSRC}/shlibtool