aboutsummaryrefslogtreecommitdiffstats
path: root/sysutils/conky/Makefile
blob: d36af48f57e1dae6302797e2c998e7230bd44b09 (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
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
# New ports collection makefile for:    conky
# Date created:             2005-08-27
# Whom:                 Roman Bogorodskiy <novel@FreeBSD.org>
#
# $FreeBSD$
#

PORTNAME=   conky
PORTVERSION=    1.4.2
PORTREVISION=   1
CATEGORIES= sysutils
MASTER_SITES=   ${MASTER_SITE_SOURCEFORGE}
MASTER_SITE_SUBDIR= ${PORTNAME}

MAINTAINER= novel@FreeBSD.org
COMMENT=    An advanced, highly configurable system monitor for X

USE_BZIP2=  yes
HAS_CONFIGURE=  yes
USE_ICONV=  yes
USE_X_PREFIX=   yes
CONFIGURE_ARGS+=    --disable-portmon --disable-proc-uptime
CONFIGURE_ENV+= CFLAGS="${CFLAGS} -I${X11BASE}/include -I${LOCALBASE}/include" \
        LDFLAGS="${LDFLAGS} -L${X11BASE}/lib -L${LOCALBASE}/lib"

MAN1=       conky.1

PORTDOCS=   README AUTHORS ChangeLog TODO \
        docs.html variables.html config_settings.html

.if defined(WITH_BMPX)
BUILD_DEPENDS+=     beep-media-player-2:${PORTSDIR}/multimedia/bmpx
RUN_DEPENDS+=       beep-media-player-2:${PORTSDIR}/multimedia/bmpx
LIB_DEPENDS+=       dbus-1.2:${PORTSDIR}/devel/dbus
CONFIGURE_ARGS+=    --enable-bmpx
.else
CONFIGURE_ARGS+=    --disable-bmpx
.endif

.if defined(WITH_XFT)
LIB_DEPENDS+=       Xft.2:${PORTSDIR}/x11-fonts/libXft
CONFIGURE_ARGS+=    --enable-xft
.else
CONFIGURE_ARGS+=    --disable-xft
.endif

.if !defined(WITHOUT_OWN_WINDOW)
CONFIGURE_ARGS+=    --enable-own-window
.else
CONFIGURE_ARGS+=    --disable-own-widnow
.endif

.if defined(WITH_MPD)
CONFIGURE_ARGS+=    --enable-mpd
.else
CONFIGURE_ARGS+=    --disable-mpd
.endif

.if defined(WITHOUT_DOUBLE_BUFFER)
CONFIGURE_ARGS+=    --disable-double-buffer
.endif

.if defined(WITHOUT_SETI)
CONFIGURE_ARGS+=    --disable-seti
.endif

pre-everything::
    @${ECHO_MSG} "You may specify the following on the command line:"
    @${ECHO_MSG} " "
    @${ECHO_MSG} "WITH_BMPX=yes to enable BMPx support"
    @${ECHO_MSG} "WITH_XFT=yes to enable XFT support"
    @${ECHO_MSG} "WITHOUT_OWN_WINDOW=yes to disable own window support"
    @${ECHO_MSG} "WITH_MPD=yes to enable MPD support"
    @${ECHO_MSG} "WITHOUT_DOUBLE_BUFFER=yes to disable double buffer support"
    @${ECHO_MSG} " "

post-configure:
    @${REINPLACE_CMD} -e 's|-lm|-lm -liconv|' ${WRKSRC}/src/Makefile

do-install:
    ${INSTALL_PROGRAM} ${WRKSRC}/src/conky ${PREFIX}/bin
    ${INSTALL_MAN} ${WRKSRC}/doc/conky.1 ${PREFIX}/man/man1

post-install:
    @${MKDIR} ${EXAMPLESDIR}
    @${INSTALL_DATA} ${WRKSRC}/doc/conkyrc.sample ${EXAMPLESDIR}

.if !defined(NOPORTDOCS)
    @${MKDIR} ${DOCSDIR}
.for i in README AUTHORS ChangeLog TODO
    ${INSTALL_DATA} ${WRKSRC}/${i} ${DOCSDIR}
.endfor
.for i in docs.html variables.html config_settings.html
    ${INSTALL_DATA} ${WRKSRC}/doc/${i} ${DOCSDIR}
.endfor
.endif

.include <bsd.port.pre.mk>

.if ${OSVERSION} < 500000
IGNORE=     not supported on 4.x
.endif

.include <bsd.port.post.mk>