aboutsummaryrefslogtreecommitdiff
path: root/math/gnuplot/Makefile
blob: 9d6d139bc4ac8d5441c13e62e72e6b1ffa069f1a (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
# New ports collection makefile for:    gnuplot
# Date created:         19 April 1998
# Whom:                 chuckr
#
# $FreeBSD$
#

PORTNAME=	gnuplot
PORTVERSION=	3.7.2
CATEGORIES=	math graphics
MASTER_SITES=	${MASTER_SITE_SOURCEFORGE}
MASTER_SITE_SUBDIR=	${PORTNAME}

MAINTAINER=	chuckr@FreeBSD.org
COMMENT=	A command-driven interactive function plotting program

LIB_DPEENDS=
.if !defined(WITHOUT_PNG)
LIB_DEPENDS+=	png.5:${PORTSDIR}/graphics/png
.endif
.if !defined(WITHOUT_PDF)
LIB_DEPENDS+=	pdf.4:${PORTSDIR}/print/pdflib
.endif

.if !defined(WITHOUT_X11)
USE_XLIB=	yes
.endif

GNU_CONFIGURE=	yes
CONFIGURE_ENV=	CPPFLAGS="-I${LOCALBASE}/include"
CONFIGURE_ARGS=	--exec-prefix=${PREFIX} \
		--includedir=${LOCALBASE}/include/ \
		--libdir=${LOCALBASE}/lib \
		--without-linux-vga --without-gd \
		--with-readline=gnu --with-lasergnu 
.if !defined(WITHOUT_PNG)
CONFIGURE_ARGS+=--with-png=${LOCALBASE}
.else
CONFIGURE_ARGS+=--without-png
.endif
.if !defined(WITHOUT_PDF)
CONFIGURE_ARGS+=--with-pdf=${LOCALBASE}
.else
CONFIGURE_ARGS+=--without-pdf
.endif

.if defined(WITHOUT_X11)
CONFIGURE_ARGS+=	--without-x
PLIST_SUB+=		X11:="@comment "
.else
CONFIGURE_ARGS+=	--with-x
PLIST_SUB+=		X11:=""
.endif

post-install:
	${MKDIR} ${PREFIX}/share/doc/gnuplot
	(cd ${WRKSRC}/demo;for EXAMPLES in ${WRKSRC}/demo/*; do ${INSTALL_DATA} $${EXAMPLES} ${PREFIX}/share/doc/gnuplot;done)
	${INSTALL_DATA} ${FILESDIR}/README ${PREFIX}/share/doc/gnuplot

MAN1=		gnuplot.1 lasergnu.1

.include <bsd.port.mk>