Date: Sat, 7 Dec 2013 13:47:00 -0500 From: Adam Weinberger <adamw@FreeBSD.org> To: FreeBSD-gnats-submit@FreeBSD.org, freebsd-ports-bugs@FreeBSD.org Cc: Adam Weinberger <adamw@FreeBSD.org> Subject: Re: ports/184579: Use OPTIONS and mandate GCC for mail/spamprobe [patch] Message-ID: <20131207184700.GA4727@apnoea.adamw.org> In-Reply-To: <201312071730.rB7HU0wU038362@freefall.freebsd.org> References: <20131207162759.959D011FDB5@apnoea.adamw.org> <201312071730.rB7HU0wU038362@freefall.freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
--2oS5YaxWCcQjTEyO Content-Type: text/plain; charset=us-ascii Content-Disposition: inline The attached patch also fixes clang compatibility. -- Adam Weinberger adamw@adamw.org http://www.adamw.org --2oS5YaxWCcQjTEyO Content-Type: text/x-diff; charset=us-ascii Content-Disposition: attachment; filename="spamprobe-clang.patch" Index: Makefile =================================================================== --- Makefile (revision 335833) +++ Makefile (working copy) @@ -12,56 +12,48 @@ GNU_CONFIGURE= yes CONFIGURE_ARGS= --enable-default-8bit +#USE_GCC= any 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> Index: files/patch-src_includes_Ref.h =================================================================== --- files/patch-src_includes_Ref.h (revision 0) +++ files/patch-src_includes_Ref.h (working copy) @@ -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; + } + Property changes on: files/patch-src_includes_Ref.h ___________________________________________________________________ Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property --2oS5YaxWCcQjTEyO--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20131207184700.GA4727>