From acce37229623179e602a10bf21d3098c6adc9a22 Mon Sep 17 00:00:00 2001 From: Nicola Vitale Date: Mon, 7 Jul 2014 02:42:22 +0000 Subject: - Update to 2.2.3 - Use options helpers - Build/install dynamic library instead of the static one - Add options DOCS and EXAMPLES - Set MAKE_JOBS_UNSAFE, otherwise the port fails to build when the option EXAMPLES is ON (it tries to compile/link example1 while the library is not yet built/deployed) - Remove build-dependency by devel/gmake - Add support for stage dir - Fix format of WWW line in pkg-descr Release Notes: http://muparser.beltoforion.de/mup_intro.html#idRelNote --- math/muparser/Makefile | 45 +++++++++++++++++++++++++-------------------- 1 file changed, 25 insertions(+), 20 deletions(-) (limited to 'math/muparser/Makefile') diff --git a/math/muparser/Makefile b/math/muparser/Makefile index af0838235f82..3e55217a5240 100644 --- a/math/muparser/Makefile +++ b/math/muparser/Makefile @@ -2,7 +2,7 @@ # $FreeBSD$ PORTNAME= muparser -PORTVERSION= 2.2.0 +PORTVERSION= 2.2.3 CATEGORIES= math devel MASTER_SITES= SF/${PORTNAME}/${PORTNAME}/Version%20${PORTVERSION} DISTNAME= ${PORTNAME}_v${PORTVERSION:S/./_/g} @@ -12,38 +12,43 @@ COMMENT= Mathematical expressions parser library written in C++ LICENSE= MIT -USES= pathfix gmake zip +ALL_TARGET= lib + +DOCS_CONFIGURE_ON= --docdir=${DOCSDIR} + +EXAMPLES_CONFIGURE_ENABLE= samples +EXAMPLES_ALL_TARGET= samples + GNU_CONFIGURE= yes -CONFIGURE_ARGS+= --enable-shared=no -.if defined(NOPORTEXAMPLES) -CONFIGURE_ARGS+= --enable-samples=no -.endif -.if !defined(NOPORTDOCS) -CONFIGURE_ARGS+= --docdir=${DOCSDIR} -.endif -NO_STAGE= yes +# otherwise it fails to build when the EXAMPLES option is ON +MAKE_JOBS_UNSAFE=yes + +OPTIONS_DEFINE= DOCS EXAMPLES + +USE_LDCONFIG= yes +USES= pathfix zip + .include .if ${ARCH} == "amd64" || ${ARCH} == "ia64" CFLAGS+= -fPIC .endif -# taken from audio/taglib post-patch: @${REINPLACE_CMD} -E 's,^(CXXFLAGS|LDFLAGS) = ,\1 ?= ,g' \ ${WRKSRC}/Makefile.in post-install: -.if !defined(NOPORTDOCS) - @${MKDIR} ${DOCSDIR} && \ - cd ${WRKSRC}/docs/html && \ - ${COPYTREE_SHARE} . ${DOCSDIR} -.endif -.if !defined(NOPORTEXAMPLES) - @${MKDIR} ${EXAMPLESDIR} && \ - cd ${WRKSRC}/samples && \ - ${COPYTREE_SHARE} . ${EXAMPLESDIR} + @${MKDIR} ${STAGEDIR}${DOCSDIR} + (cd ${WRKSRC}/docs/html && \ + ${COPYTREE_SHARE} . ${STAGEDIR}${DOCSDIR}) + +.if ${PORT_OPTIONS:MEXAMPLES} + @${MKDIR} ${STAGEDIR}${EXAMPLESDIR} + (cd ${WRKSRC}/samples/example1 && \ + ${INSTALL_PROGRAM} example1 ${STAGEDIR}${EXAMPLESDIR} && \ + ${INSTALL_DATA} example1.cpp ${STAGEDIR}${EXAMPLESDIR}) .endif .include -- cgit v1.2.3