Tweak math/qtiplot version 0.9.8.9_8
[dports.git] / math / givaro / Makefile
1 # $FreeBSD$
2
3 PORTNAME=       givaro
4 PORTVERSION=    3.8.0
5 CATEGORIES=     math
6 MASTER_SITES=   https://forge.imag.fr/frs/download.php/592/ LOCAL/bf
7
8 MAINTAINER=     bf@FreeBSD.org
9 COMMENT=        C++ library for computer algebra
10
11 LICENSE=        CeCILL-Bv1-en.txt
12 LICENSE_NAME=   Ce[a] C[nrs] I[nria] L[ogiciel] L[ibre] B license, version 1
13 LICENSE_FILE=   ${WRKSRC}/Licence_CeCILL-B_V1-en.txt
14 LICENSE_PERMS=  auto-accept
15
16 LIB_DEPENDS=    libgmp.so.10:${PORTSDIR}/math/gmp
17
18 USES=           libtool
19 GNU_CONFIGURE=  yes
20 CONFIGURE_ARGS =        --with-gmp="${LOCALBASE}"
21 USE_LDCONFIG=   yes
22 INSTALL_TARGET= install-strip
23
24 OPTIONS_DEFINE= DOXYGEN
25
26 .include <bsd.port.options.mk>
27
28 .if ${PORT_OPTIONS:MDOXYGEN}
29 BUILD_DEPENDS +=        doxygen:${PORTSDIR}/devel/doxygen \
30                         dot:${PORTSDIR}/graphics/graphviz
31 CONFIGURE_ARGS+=        --enable-doc --with-docdir=${DOCSDIR}
32 PLIST_SUB+=     PORTDOCS=""
33 .else
34 PLIST_SUB+=     PORTDOCS="@comment "
35 .endif
36
37 CPPFLAGS+=      -I${LOCALBASE}/include
38 LDFLAGS+=       -L${LOCALBASE}/lib
39
40 post-patch:
41         @${REINPLACE_CMD} -e '/DEFAULT_CFLAGS=/{s/-O2 //;s/-pipe//;}' \
42                 -e '/DEBUG_CFLAGS=.*-DNDEBUG/s/$${DEBUG_CFLAGS} //' \
43                 -e '/^WARN_CFLAGS="-Wall"/d' \
44                 -e '/if test "x$$WARN" = "xyes"/s/$$/ WARN_CFLAGS="-Wall" ;/' \
45                 ${WRKSRC}/configure
46 .if ${PORT_OPTIONS:MDOXYGEN}
47         @${REINPLACE_CMD} -e 's/sed -i/& ""/' ${WRKSRC}/docs/Makefile.in
48 .endif
49
50 post-install:
51 .if ${PORT_OPTIONS:MDOXYGEN}
52         ${RMDIR} ${STAGEDIR}${DOCSDIR}/givaro-dev-html
53         ${FIND} ${WRKSRC}/docs/givaro-html -not -type d \
54                 | ${SED} -ne 's,^${WRKSRC}/docs/givaro-html,${DOCSDIR}/givaro-html,p' >> ${TMPPLIST}
55 .endif
56
57 check regression-test test: build
58         @cd ${WRKSRC}; ${SETENV} ${MAKE_ENV} ${MAKE} ${_MAKE_JOBS} \
59         ${MAKE_ARGS} check
60
61 .include <bsd.port.mk>