diff options
author | bapt <bapt@FreeBSD.org> | 2012-06-02 00:59:20 +0800 |
---|---|---|
committer | bapt <bapt@FreeBSD.org> | 2012-06-02 00:59:20 +0800 |
commit | d11c41d1ad3012decf213f15c52bcac9c1b58ccb (patch) | |
tree | e28089e70f941c688810dcf42b54dd8b8bf6ed55 /databases/cassandra | |
parent | a3fd2744caf5940808c561315a2f854d6a243196 (diff) | |
download | freebsd-ports-gnome-d11c41d1ad3012decf213f15c52bcac9c1b58ccb.tar.gz freebsd-ports-gnome-d11c41d1ad3012decf213f15c52bcac9c1b58ccb.tar.zst freebsd-ports-gnome-d11c41d1ad3012decf213f15c52bcac9c1b58ccb.zip |
Convert to new options framework
Diffstat (limited to 'databases/cassandra')
-rw-r--r-- | databases/cassandra/Makefile | 25 |
1 files changed, 13 insertions, 12 deletions
diff --git a/databases/cassandra/Makefile b/databases/cassandra/Makefile index 920c49a111ca..ac03c44f4eba 100644 --- a/databases/cassandra/Makefile +++ b/databases/cassandra/Makefile @@ -36,27 +36,28 @@ SCRIPTS= cassandra \ sstablekeys \ sstableloader -OPTIONS= MX4J "Enable HTTP interface for JMX" Off \ - JNA "Use JNA native access" Off \ - CQL "Install cqlsh" Off +OPTIONS_DEFINE= MX4J JNA CQL +MX4J_DESC= Enable HTTP interface for JMX +JNA_DESC= Use JNA native access +CQL_DESC= Install cqlsh SUB_FILES= repaircluster .include <bsd.port.options.mk> -.if defined(WITH_MX4J) +.if ${PORT_OPTIONS:MMX4J} RUN_DEPENDS+= ${JAVAJARDIR}/mx4j-tools.jar:${PORTSDIR}/java/mx4j PLIST_SUB+= MX4J="" .else PLIST_SUB+= MX4J="@comment " .endif -.if defined(WITH_JNA) +.if ${PORT_OPTIONS:MJNA} RUN_DEPENDS+= ${JAVAJARDIR}/jna.jar:${PORTSDIR}/devel/jna PLIST_SUB+= JNA="" .else PLIST_SUB+= JNA="@comment " .endif -.if defined(WITH_CQL) +.if ${PORT_OPTIONS:MCQL} USE_PYTHON= yes RUN_DEPENDS+= ${PYTHON_PKGNAMEPREFIX}cql>=0:${PORTSDIR}/databases/py-cql PLIST_SUB+= CQL="" @@ -71,7 +72,7 @@ post-extract: @${MV} ${WRKSRC}/conf/${i} ${WRKSRC}/conf/${i}.sample .endfor @${MV} ${WRKSRC}/bin/cqlshrc.sample ${WRKSRC}/conf -.if !defined(WITH_CQL) +.if empty(PORT_OPTIONS:MCQL) @${RM} -r ${WRKSRC}/pylib @${RM} ${WRKSRC}/bin/cqlsh .endif @@ -87,13 +88,13 @@ post-patch: @${REINPLACE_CMD} -e 's|\`dirname \$$\0\`/..|${DATADIR}|' \ ${WRKSRC}/bin/cassandra.in.sh @${RM} -f ${WRKSRC}/conf/*.orig -.if defined(WITH_CQL) +.if ${PORT_OPTIONS:MCQL} @${REINPLACE_CMD} -e 's|os.path.dirname(__file__)|"${DATADIR}/bin"|' \ ${WRKSRC}/bin/cqlsh .endif do-build: -.if defined(WITH_CQL) +.if ${PORT_OPTIONS:MCQL} @${PYTHON_CMD} -m compileall ${WRKSRC}/pylib .endif @@ -110,13 +111,13 @@ do-install: @${LN} -s ${DATADIR}/bin/sstable2json ${PREFIX}/bin/sstable2json @${LN} -s ${DATADIR}/bin/sstablekeys ${PREFIX}/bin/sstablekeys -.if defined(WITH_CQL) +.if ${PORT_OPTIONS:MCQL} @${LN} -s ${DATADIR}/bin/cqlsh ${PREFIX}/bin/cqlsh .endif -.if defined(WITH_MX4J) +.if ${PORT_OPTIONS:MMX4J} @${LN} -s ${LOCALBASE}/share/java/classes/mx4j-tools.jar ${DATADIR}/lib/mx4j-tools.jar .endif -.if defined(WITH_JNA) +.if ${PORT_OPTIONS:MJNA} @${LN} -s ${LOCALBASE}/share/java/classes/jna.jar ${DATADIR}/lib/jna.jar @${LN} -s ${LOCALBASE}/share/java/classes/jna-platform.jar ${DATADIR}/lib/jna-platform.jar .endif |