5 CATEGORIES= math graphics
8 MAINTAINER= glewis@FreeBSD.org
9 COMMENT= Command-line driven graphing utility
13 LDFLAGS+= -L${LOCALBASE}/lib ${ICONV_LIB}
14 CONFIGURE_ARGS+=--with-lasergnu \
17 --without-lisp-files \
19 --with-bitmap-terminals
23 OPTIONS_DEFINE= CAIRO DOCS EXAMPLES GD GRIDBOX PDF PLOT TEX THINSPLINES WX X11
24 GRIDBOX_DESC= Use the gridbox optimization for hidden3d
25 PLOT_DESC= Enable plot support
26 TEX_DESC= Search kpsexpand at run-time
27 THINSPLINES_DESC= Enable thin plate splines for grids in dgrid3d
28 WX_DESC= wxWidgets (formerly wxWindows) support
30 OPTIONS_DEFAULT=CAIRO GD PLOT TEX WX X11
33 CAIRO_LIB_DEPENDS= libcairo.so:${PORTSDIR}/graphics/cairo
34 CAIRO_USE= GNOME=pango
35 CAIRO_CONFIGURE_WITH= cairo
37 GD_LIB_DEPENDS= libgd.so:${PORTSDIR}/graphics/gd
38 GD_CONFIGURE_ON= --with-gd=${LOCALBASE}
39 GD_CONFIGURE_OFF+= --without-gd
41 GRIDBOX_CONFIGURE_OFF= --disable-h3d-quadtree --enable-h3d-gridbox
43 PDF_LIB_DEPENDS= libpdf.so:${PORTSDIR}/print/pdflib
44 PDF_CONFIGURE_ON= --with-pdf=${LOCALBASE}
45 PDF_CONFIGURE_OFF= --without-pdf
47 PLOT_USE= XORG=xaw,xmu,xt,xext
48 PLOT_LIB_DEPENDS= libplot.so:${PORTSDIR}/graphics/plotutils
49 PLOT_CONFIGURE_ON= --with-plot=${LOCALBASE}
50 PLOT_CONFIGURE_OFF= --without-plot
52 TEX_USE= TEX=base,texmf,latex,dvipsk
53 TEX_CONFIGURE_ON= --with-kpsexpand \
54 --with-texdir=${LOCALBASE}/share/texmf/tex/latex/gnuplot
55 TEX_CONFIGURE_OFF= --without-kpexpand
57 THINSPLINES_CONFIGURE_ENABLE= thin-splines
61 .include <bsd.port.options.mk>
63 .if ${PORT_OPTIONS:MWX}
64 # Version 3.x of WX currently cause gnuplot to crash.
65 # Do not update without this without testing.
68 WX_CONF_ARGS= absolute
70 CONFIGURE_ARGS+= --disable-wxwidgets
74 .if ! ${PORT_OPTIONS:MTEX}
75 @${REINPLACE_CMD} -e \
76 '/^install:/s/install-am//' ${WRKSRC}/share/LaTeX/Makefile.in
78 @${REINPLACE_CMD} -e \
79 's|)/@PACKAGE@/@PKG_MAJOR@|)|g' ${WRKSRC}/src/Makefile.in
80 @${FIND} "${WRKSRC}" -name '*.orig' -delete
82 .if ${PORT_OPTIONS:MDOCS}
84 @cd ${WRKSRC}/docs && ${MAKE} groff
88 ${INSTALL_SCRIPT} ${WRKSRC}/src/lasergnu ${STAGEDIR}${PREFIX}/bin
89 @${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
90 cd ${WRKSRC}/demo && ${COPYTREE_SHARE} . ${STAGEDIR}${EXAMPLESDIR}
91 .if ${PORT_OPTIONS:MDOCS}
92 @${MKDIR} ${STAGEDIR}${DOCSDIR}/psdoc
93 cd ${WRKSRC}/docs && ${INSTALL_DATA} gnuplot.txt gnuplot.dvi \
94 gnuplot.ps ${STAGEDIR}${DOCSDIR}
95 cd ${WRKSRC}/docs/psdoc && ${INSTALL_DATA} README ps_* ${STAGEDIR}${DOCSDIR}/psdoc
99 @( cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} ${MAKE} ${MAKE_ARGS} check ; )
101 .include <bsd.port.mk>