aboutsummaryrefslogtreecommitdiffstats
path: root/devel/php-memoize/Makefile
blob: 54a8195972868f3000702c228a9c7b1c5ca99845 (plain) (blame)
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
# Created by: Gasol Wu <gasol.wu@gmail.com>
# $FreeBSD$

PORTNAME=   memoize
PORTVERSION=    0.2.0b1
PORTREVISION=   1
CATEGORIES= devel
PKGNAMEPREFIX=  php-

MAINTAINER= gasol.wu@gmail.com
COMMENT=    PHP extension which transparently caches PHP functions

USE_GITHUB= yes
GH_ACCOUNT= arraypad
GH_PROJECT= ${UNIQUENAME}
GH_TAGNAME= v${PORTVERSION}
GH_COMMIT=  cff0a58

USE_PHP=    yes
USE_PHPEXT= yes
USE_PHPIZE= yes
USE_PHP_BUILD=  yes
CONFIGURE_ARGS= --enable-memoize

OPTIONS_DEFINE= APC MEMCACHED MEMORY
OPTIONS_DEFAULT=    MEMORY
APC_DESC=   Enable memoize APC module
MEMCACHED_DESC= Enable memcached storage module
MEMORY_DESC=    Enable the memoize memory storage module

.include <bsd.port.pre.mk>

.if ${PORT_OPTIONS:MAPC}
CONFIGURE_ARGS+=    --enable-memoize-apc
BUILD_DEPENDS+= ${LOCALBASE}/lib/php/${PHP_EXT_DIR}/apc.so:${PORTSDIR}/www/pecl-APC
.endif

.if ${PORT_OPTIONS:MMEMCACHED}
CONFIGURE_ARGS+=    --with-memoize-memcached
BUILD_DEPENDS+=     libmemcached>0:${PORTSDIR}/databases/libmemcached
RUN_DEPENDS+=       libmemcached>0:${PORTSDIR}/databases/libmemcached
.endif

.if empty(PORT_OPTIONS:MMEMORY)
CONFIGURE_ARGS+=    --disable-memoize-memory
.endif

.include <bsd.port.post.mk>