diff options
author | adamw <adamw@FreeBSD.org> | 2013-12-16 04:51:37 +0800 |
---|---|---|
committer | adamw <adamw@FreeBSD.org> | 2013-12-16 04:51:37 +0800 |
commit | 57f03acfae8d0c5d1f423475ca6e64bd62b442fb (patch) | |
tree | 4a0a1591ff227f255eff206bd067a338c2bba0f6 /mail | |
parent | e86e13f3f2488a53bd7dc7ff1e093e9120fcf5d7 (diff) | |
download | freebsd-ports-gnome-57f03acfae8d0c5d1f423475ca6e64bd62b442fb.tar.gz freebsd-ports-gnome-57f03acfae8d0c5d1f423475ca6e64bd62b442fb.tar.zst freebsd-ports-gnome-57f03acfae8d0c5d1f423475ca6e64bd62b442fb.zip |
Use OPTIONS instead of WITH_XYZ's
Default to PBL as the data store (per the author's recommendations)
Use OPTIONS helpers where possible
Fix with clang
PR: ports/184579
Approved by: stefan (maintainer)
Diffstat (limited to 'mail')
-rw-r--r-- | mail/spamprobe/Makefile | 69 | ||||
-rw-r--r-- | mail/spamprobe/files/patch-src_includes_Ref.h | 20 |
2 files changed, 50 insertions, 39 deletions
diff --git a/mail/spamprobe/Makefile b/mail/spamprobe/Makefile index 7d38f52a6e89..c94fbc170fbd 100644 --- a/mail/spamprobe/Makefile +++ b/mail/spamprobe/Makefile @@ -1,10 +1,10 @@ # Created by: Matthew N. Dodd <mdodd@FreeBSD.org> # $FreeBSD$ -PORTNAME= spamprobe +PORTNAME= spamprobe PORTVERSION= 1.4d PORTREVISION= 7 -CATEGORIES= mail +CATEGORIES= mail MASTER_SITES= SF MAINTAINER= stefan@FreeBSD.org @@ -15,53 +15,44 @@ CONFIGURE_ARGS= --enable-default-8bit PLIST_FILES= bin/spamprobe man/man1/spamprobe.1.gz -.include <bsd.port.pre.mk> +OPTIONS_DEFINE= GIF JPEG PNG +OPTIONS_MULTI= DATABASE +OPTIONS_MULTI_DATABASE= PBL BDB +OPTIONS_DEFAULT=PBL GIF JPEG PNG +PBL_DESC= PBL database support (author's recommended data store) -.if ${OSVERSION} >= 1000024 -USE_GCC= yes -.endif +CPPFLAGS+= -I${LOCALBASE}/include +LDFLAGS+= -L${LOCALBASE}/lib # PBL support -.if !defined(WITHOUT_PBL) -BUILD_DEPENDS+= ${LOCALBASE}/include/pbl.h:${PORTSDIR}/databases/libpbl -CONFIGURE_ARGS+= --with-pbl=${LOCALBASE} -CPPFLAGS+= -I${LOCALBASE}/include -LDFLAGS+= -L${LOCALBASE}/lib -lpbl -.endif +PBL_BUILD_DEPENDS= ${LOCALBASE}/lib/libpbl.a:${PORTSDIR}/databases/libpbl +PBL_RUN_DEPENDS+= ${PBL_BUILD_DEPENDS} +PBL_CONFIGURE_WITH= pbl +PBL_LDFLAGS= -lpbl # BerkleyDB support -.if !defined(WITHOUT_BDB) -USE_BDB= 40+ -CONFIGURE_ARGS+= --enable-cdb -CPPFLAGS+= -I${BDB_INCLUDE_DIR} -DUSE_DB=1 -LDFLAGS+= -L${LOCALBASE}/lib -l${BDB_LIB_NAME} -.endif +BDB_CONFIGURE_ENABLE= cdb +BDB_CONFIGURE_WITH= db +BDB_CPPFLAGS= -DUSE_DB=1 # giflib support -.if defined(WITHOUT_UNGIF) -CONFIGURE_ARGS+= --without-gif -.else -LIB_DEPENDS+= gif.5:${PORTSDIR}/graphics/giflib -CPPFLAGS+= -I${LOCALBASE}/include -LDFLAGS+= -L${LOCALBASE}/lib -.endif +GIF_CONFIGURE_WITH= gif +GIF_LIB_DEPENDS= libgif.so:${PORTSDIR}/graphics/giflib # PNG support -.if defined(WITHOUT_PNG) -CONFIGURE_ARGS+= --without-png -.else -LIB_DEPENDS+= png15:${PORTSDIR}/graphics/png -CPPFLAGS+= -I${LOCALBASE}/include -LDFLAGS+= -L${LOCALBASE}/lib -.endif +PNG_CONFIGURE_WITH= png +PNG_LIB_DEPENDS= libpng15.so:${PORTSDIR}/graphics/png # JPEG support -.if defined(WITHOUT_JPEG) -CONFIGURE_ARGS+= --without-jpeg -.else -LIB_DEPENDS+= jpeg.11:${PORTSDIR}/graphics/jpeg -CPPFLAGS+= -I${LOCALBASE}/include -LDFLAGS+= -L${LOCALBASE}/lib +JPEG_CONFIGURE_WITH=jpeg +JPEG_LIB_DEPENDS= libjpeg.so:${PORTSDIR}/graphics/jpeg + +.include <bsd.port.options.mk> + +.if ${PORT_OPTIONS:MBDB} +USE_BDB= 40+ +CPPFLAGS+= -I${BDB_INCLUDE_DIR} +LDFLAGS+= -l${BDB_LIB_NAME} .endif -.include <bsd.port.post.mk> +.include <bsd.port.mk> diff --git a/mail/spamprobe/files/patch-src_includes_Ref.h b/mail/spamprobe/files/patch-src_includes_Ref.h new file mode 100644 index 000000000000..11e4690e5358 --- /dev/null +++ b/mail/spamprobe/files/patch-src_includes_Ref.h @@ -0,0 +1,20 @@ +--- src/includes/Ref.h.orig 2013-12-07 13:41:33.000000000 -0500 ++++ src/includes/Ref.h 2013-12-07 13:41:49.000000000 -0500 +@@ -189,7 +189,7 @@ + + CRef<T> &operator=(const CRef<T> &other) + { +- assign(other); ++ this->assign(other); + return *this; + } + +@@ -245,7 +245,7 @@ + + Ref<T> &operator=(const Ref<T> &other) + { +- assign(other); ++ this->assign(other); + return *this; + } + |