aboutsummaryrefslogtreecommitdiff
path: root/www/gallery3/Makefile
blob: 6d3138156420d6a94c605f8c57f5107eedca0da8 (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
# Created by: Bo-Yi Wu <appleboy.tw@gmail.com>
# $FreeBSD$

PORTNAME=	gallery3
PORTVERSION=	3.0.9
PORTREVISION=	1
CATEGORIES=	www
MASTER_SITES=	SF/gallery/${PORTNAME}/${PORTVERSION}
DISTNAME=	gallery-${PORTVERSION}

MAINTAINER=	appleboy.tw@gmail.com
COMMENT=	Web based photo album organizer written in PHP

USES=		zip

USE_PHP=	ctype filter iconv json mysql mbstring pcre \
		simplexml session spl tokenizer xml
WANT_PHP_WEB=	yes

WRKSRC=		${WRKDIR}/${PORTNAME}
NO_BUILD=	yes

PLIST_SUB=	WWWOWN="${WWWOWN}" WWWGRP="${WWWGRP}"
SUB_FILES=	pkg-message

OPTIONS_DEFINE=	DCRAW FFMPEG GD GRAPHMAGICK IMAGEMAGICK JHEAD \
		NETPBM NLS UNZIP X11
OPTIONS_DEFAULT=	IMAGEMAGICK JHEAD UNZIP

.include <bsd.port.options.mk>

.if defined(GALLERY3DIR)
# Continue to support legacy GALLERY3DIR variable
WWWDIR=		${GALLERY3DIR}
.endif

.if ${PORT_OPTIONS:MDCRAW}
RUN_DEPENDS+=	dcraw:${PORTSDIR}/graphics/dcraw
.endif

.if ${PORT_OPTIONS:MFFMPEG}
LIB_DEPENDS+=	libavcodec.so:${PORTSDIR}/multimedia/ffmpeg
.endif

.if ${PORT_OPTIONS:MGD}
USE_PHP+=	gd
RUN_DEPENDS+=	pngtogd:${PORTSDIR}/graphics/gd
.endif

.if ${PORT_OPTIONS:MGRAPHMAGICK}
RUN_DEPENDS+=	gm:${PORTSDIR}/graphics/GraphicsMagick
.endif

.if ${PORT_OPTIONS:MIMAGEMAGICK}
.if ${PORT_OPTIONS:MX11}
RUN_DEPENDS+=	convert:${PORTSDIR}/graphics/ImageMagick
.else
RUN_DEPENDS+=	convert:${PORTSDIR}/graphics/ImageMagick-nox11
.endif
.endif

.if ${PORT_OPTIONS:MJHEAD}
RUN_DEPENDS+=	jhead:${PORTSDIR}/graphics/jhead
.endif

.if ${PORT_OPTIONS:MNETPBM}
RUN_DEPENDS+=	giftopnm:${PORTSDIR}/graphics/netpbm
.endif

.if ${PORT_OPTIONS:MNLS}
USE_PHP+=	gettext
USES+=		gettext
.endif

.if ${PORT_OPTIONS:MUNZIP}
RUN_DEPENDS+=	unzip:${PORTSDIR}/archivers/unzip
.endif

do-install:
	@cd ${WRKSRC}/ && ${COPYTREE_SHARE} . ${STAGEDIR}${WWWDIR}/

.include <bsd.port.mk>