aboutsummaryrefslogtreecommitdiffstats
path: root/math/gnuplot/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'math/gnuplot/Makefile')
-rw-r--r--math/gnuplot/Makefile38
1 files changed, 30 insertions, 8 deletions
diff --git a/math/gnuplot/Makefile b/math/gnuplot/Makefile
index d82cd3108659..3028f31bc7b0 100644
--- a/math/gnuplot/Makefile
+++ b/math/gnuplot/Makefile
@@ -7,7 +7,7 @@
PORTNAME= gnuplot
PORTVERSION= 4.0.0
-PORTREVISION= 2
+PORTREVISION= 3
CATEGORIES= math graphics
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE}
MASTER_SITE_SUBDIR= ${PORTNAME}
@@ -18,11 +18,15 @@ COMMENT= A command-driven interactive function plotting program
USE_REINPLACE= yes
GNU_CONFIGURE= yes
CONFIGURE_TARGET= --build=${MACHINE_ARCH}-portbld-freebsd${OSREL}
-CONFIGURE_ARGS= --without-tutorial --without-linux-vga --with-lasergnu
+CONFIGURE_ARGS= --without-tutorial \
+ --without-linux-vga \
+ --with-lasergnu
-OPTIONS= GD "Enable GD support" on \
- PDF "Enable PDF support" on \
- PNG "Enable PNG support" on
+OPTIONS= GD "Enable GD support" on \
+ HISTOGRAMS "Enable stacked histograms" off \
+ PDF "Enable PDF support" on \
+ PNG "Enable PNG support" on \
+ READLINE "Enable readline support" on
MAN1= gnuplot.1 lasergnu.1
INFO= gnuplot
@@ -39,16 +43,21 @@ CONFIGURE_ARGS+= --without-lisp-files
.include <bsd.port.pre.mk>
-.if ${OSVERSION} >= 500018
+.if !defined(WITHOUT_READLINE)
+.if ${OSVERSION} < 500018
+LIB_DEPENDS+= readline.5:${PORTSDIR}/devel/readline
+CONFIGURE_ARGS+= --with-readline="${LOCALBASE}"
+.else
CONFIGURE_ARGS+= --with-readline=gnu
.endif
+.endif
.if !defined(WITHOUT_X11)
USE_XLIB= yes
-PLIST_SUB+= X11:=""
+PLIST_SUB+= X11=""
.else
CONFIGURE_ARGS+= --without-x
-PLIST_SUB+= X11:="@comment "
+PLIST_SUB+= X11="@comment "
.endif
.if defined(WITHOUT_GD)
@@ -72,9 +81,22 @@ LIB_DEPENDS+= png.5:${PORTSDIR}/graphics/png
CONFIGURE_ARGS+= --with-png=${LOCALBASE}
.endif
+.if defined(WITH_HISTOGRAMS)
+PATCH_SITES= http://www.bmsc.washington.edu/people/merritt/gnuplot/
+PATCHFILES= datastrings_4.0.patch histograms_4.0.patch
+PATCH_DIST_STRIP= -p1
+USE_AUTOCONF_VER= 259
+CONFIGURE_ARGS+= --enable-datastrings \
+ --enable-histograms
+PLIST_SUB+= HISTOGRAMS=""
+.else
+PLIST_SUB+= HISTOGRAMS="@comment "
+.endif
+
post-patch:
@${REINPLACE_CMD} -e \
's|)/@PACKAGE@/@PKG_MAJOR@|)|g' ${WRKSRC}/src/Makefile.in
+ @${FIND} "${WRKSRC}" -name '*.orig' -delete
post-install:
${INSTALL_SCRIPT} ${WRKSRC}/src/lasergnu ${PREFIX}/bin