From cee7b9cafe7b3be8880cf5b9a722ad8da930e45e Mon Sep 17 00:00:00 2001 From: Sunpoet Po-Chuan Hsieh Date: Tue, 19 Jun 2012 13:00:47 +0000 Subject: - Convert to new options framework - Rename option PERFTOOLS to GPERFTOOLS to match the project name --- databases/leveldb/Makefile | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'databases/leveldb') diff --git a/databases/leveldb/Makefile b/databases/leveldb/Makefile index fcad2bf74dd0..ed9e97dedc0f 100644 --- a/databases/leveldb/Makefile +++ b/databases/leveldb/Makefile @@ -13,8 +13,8 @@ MASTER_SITES= GOOGLE_CODE MAINTAINER= sunpoet@FreeBSD.org COMMENT= A fast and lightweight key/value database library by Google -OPTIONS= PERFTOOLS "Build with Google perftools" off \ - SNAPPY "Build with snappy" on +OPTIONS_DEFINE= GPERFTOOLS SNAPPY +OPTIONS_DEFAULT=SNAPPY LDFLAGS+= -L${LOCALBASE}/lib USE_GMAKE= yes @@ -31,11 +31,11 @@ SHLIB_MINOR= ${PORTVERSION:R:E} .include -.if defined(WITH_PERFTOOLS) +.if ${PORT_OPTIONS:MGPERFTOOLS} LIB_DEPENDS+= tcmalloc:${PORTSDIR}/devel/google-perftools .endif -.if !defined(WITHOUT_SNAPPY) +.if ${PORT_OPTIONS:MSNAPPY} LIB_DEPENDS+= snappy:${PORTSDIR}/archivers/snappy SNAPPY= 1 .else @@ -44,10 +44,10 @@ SNAPPY= 0 post-patch: @${REINPLACE_CMD} -e 's|-lpthread|${PTHREAD_LIBS}|' ${WRKSRC}/build_detect_platform -.if !defined(WITH_PERFTOOLS) +.if empty(PORT_OPTIONS:MGPERFTOOLS) @${REINPLACE_CMD} -e 's| -ltcmalloc||' ${WRKSRC}/build_detect_platform .endif -.if defined(WITHOUT_SNAPPY) +.if empty(PORT_OPTIONS:MSNAPPY) @${REINPLACE_CMD} -e 's| -DSNAPPY||; s| -lsnappy||' ${WRKSRC}/build_detect_platform .endif -- cgit v1.2.3