1 # Created by: Sean Chittenden <seanc@FreeBSD.org>
7 MASTER_SITES= http://www.memcached.org/files/ \
10 MAINTAINER= swills@FreeBSD.org
11 COMMENT= High-performance distributed memory object cache system
14 LICENSE_FILE= ${WRKSRC}/COPYING
16 BROKEN_mips= fails to link: failed to merge target specific data of file /usr/lib/dtrace/drti.o
17 BROKEN_mips64= fails to link: failed to merge target specific data of file /usr/lib/dtrace/drti.o
19 LIB_DEPENDS= libevent.so:devel/libevent
21 CONFLICTS= memcached-1.2*
23 USES= cpe shebangfix autoreconf
24 SHEBANG_FILES= scripts/memcached-tool
26 USE_RC_SUBR= memcached
27 SUB_LIST+= RC_SUBR_SUFFIX=${RC_SUBR_SUFFIX}
31 CONFIGURE_ARGS= --with-libevent=${LOCALBASE} \
35 # Dtrace option disabled until it is fixed upstream
36 OPTIONS_DEFINE= SASL DOCS DTRACE
37 OPTIONS_DEFAULT= SASL DTRACE
39 .if !exists(/usr/sbin/dtrace)
40 OPTIONS_EXCLUDE+= DTRACE
43 OPTIONS_EXCLUDE_i386= DTRACE
44 # ld(1) fails to link probes: Relocations in generic ELF (EM: 0)
45 OPTIONS_EXCLUDE_aarch64= DTRACE
46 OPTIONS_EXCLUDE_armv6= DTRACE
47 OPTIONS_EXCLUDE_armv7= DTRACE
48 # /tmp/conftest-4d18ad.s:2: Error: unknown pseudo-op: `.abiversion'
49 OPTIONS_EXCLUDE_powerpc64= DTRACE
51 DTRACE_DESC= Enable dtrace probes
52 SASL_DESC= Enable SASL Authentication
54 DOCS_BUILD_DEPENDS= xml2rfc:textproc/xml2rfc
55 DOCS_CONFIGURE_ENABLE= docs
57 DTRACE_CONFIGURE_ENABLE= dtrace
59 SASL_LIB_DEPENDS= libsasl2.so:security/cyrus-sasl2
60 SASL_CONFIGURE_ENABLE= sasl
61 SASL_CFLAGS= -I${LOCALBASE}/include
62 SASL_CPPFLAGS+= ${CFLAGS}
63 SASL_LDFLAGS= -L${LOCALBASE}/lib
67 .include <bsd.port.pre.mk>
70 CONFIGURE_ARGS+= --enable-64bit
73 # avoid triggering a bug in libdtrace, see illumos issue 6653
74 .if ${PORT_OPTIONS:MDTRACE}
75 CFLAGS+= -no-integrated-as
79 ${INSTALL_SCRIPT} ${WRKSRC}/scripts/memcached-tool ${STAGEDIR}${PREFIX}/bin
82 ${MKDIR} ${STAGEDIR}${DOCSDIR}
83 .for i in protocol-binary-range.txt protocol-binary.txt protocol.txt \
84 readme.txt threads.txt
85 ${INSTALL_DATA} ${WRKSRC}/doc/${i} ${STAGEDIR}${DOCSDIR}
90 ${MAKE} -C ${WRKSRC} test
92 .include <bsd.port.post.mk>