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
105
106
107
108
109
110
111
112
113
114
|
# $NetBSD: Makefile,v 1.9 2006/07/17 02:03:30 taca Exp $
#
DISTNAME= geeklog-${VER}
PKGNAME= geeklog-${VER:S/sr/./}
CATEGORIES= www
MASTER_SITES= http://www.geeklog.net/filemgmt/upload_dir/
MAINTAINER= taca@NetBSD.org
HOMEPAGE= http://www.geeklog.net/
COMMENT= PHP/MySQL based application for managing dynamic web content
DEPENDS+= ${APACHE_PKG_PREFIX}-${PHP_PKG_PREFIX}>=4.3.3:../../www/ap-php
DEPENDS+= ${PHP_PKG_PREFIX}-mysql>=4.3.0:../../databases/php-mysql
VER= 1.4.0sr5
NO_BUILD= YES
GEEKLOG_SYS= emailgeeklogstories language plugins readme sql system
GEEKLOG_TMPL_SUB= backend images/articles images/library \
images/topics images/userphotos
GEEKLOG_CONF_FILES= config.php plugins/links/config.php \
plugins/polls/config.php plugins/spamx/config.php \
plugins/staticpages/config.php \
system/lib-custom.php
CONF_FILES+= ${GEEKLOG_EXAMPLESDIR}/geeklog.conf \
${PKG_SYSCONFDIR}/geeklog.conf
.for f in ${GEEKLOG_CONF_FILES}
CONF_FILES_PERMS+= ${GEEKLOG_EXAMPLESDIR}/${f} \
${GEEKLOG_DIR}/${f} \
${BINOWN} ${APACHE_GROUP} 0640
.endfor
OWN_DIRS_PERMS+= ${GEEKLOG_DIR}/backups ${BINOWN} ${APACHE_GROUP} 0770 \
${GEEKLOG_DIR}/data ${BINOWN} ${APACHE_GROUP} 0770 \
${GEEKLOG_DIR}/logs ${BINOWN} ${APACHE_GROUP} 0775
FILES_SUBST+= APACHE_GROUP=${APACHE_GROUP:Q} \
GEEKLOG_DIR=${GEEKLOG_DIR:Q} \
GEEKLOG_EXAMPLESDIR=${GEEKLOG_EXAMPLESDIR:Q} \
GEEKLOG_PUBDIR=${GEEKLOG_PUBDIR:Q} \
GEEKLOG_TMPL_SUB=${GEEKLOG_TMPL_SUB:Q} \
GEEKLOG_TMPL_DIR=${GEEKLOG_TMPL_DIR:Q}
PLIST_SUBST+= GEEKLOG_BASE=${GEEKLOG_BASE:Q} \
GEEKLOG_PUB=${GEEKLOG_PUB:Q} \
GEEKLOG_TMPL=${GEEKLOG_TMPL:Q}
SUBST_CLASSES+= paths
SUBST_FILES.paths+= ${WRKDIR}/README ${WRKDIR}/createdb.php
SUBST_FILES.paths+= ${WRKSRC}/config.php ${WRKSRC}/emailgeeklogstories
SUBST_FILES.paths+= ${WRKSRC}/public_html/lib-common.php
SUBST_SED.paths+= -e 's,@GEEKLOG_DIR@,${GEEKLOG_DIR:Q},g'
SUBST_SED.paths+= -e 's,@GEEKLOG_EXAMPLESDIR@,${GEEKLOG_EXAMPLESDIR:Q},g'
SUBST_SED.paths+= -e 's,@GEEKLOG_PUBDIR@,${GEEKLOG_PUBDIR:Q},g'
SUBST_SED.paths+= -e 's,@GEEKLOG_SITESUBDIR@,${GEEKLOG_SITESUBDIR:Q},g'
SUBST_SED.paths+= -e 's,@PKG_SYSCONFDIR@,${PKG_SYSCONFDIR:Q},g'
SUBST_SED.paths+= -e 's,@PREFIX@,${PREFIX:Q},g'
SUBST_STAGE.paths= post-configure
SUBST_CLASSES+= conf
SUBST_FILES.conf+= ${WRKDIR}/geeklog.conf
SUBST_SED.conf+= -e 's,@GEEKLOG_DIR@,${GEEKLOG_DIR:Q},g'
SUBST_SED.conf+= -e 's,@GEEKLOG_PUBDIR@,${GEEKLOG_PUBDIR:Q},g'
SUBST_STAGE.conf= post-configure
INSTALLATION_DIRS= ${GEEKLOG_BASE} ${GEEKLOG_PUB} ${GEEKLOG_TMPL}/images \
share/examples/geeklog
.include "../../www/geeklog/Makefile.common"
PKG_SYSCONFSUBDIR?= geeklog
.if empty(GEEKLOG_SITEBASE)
SUBST_SED.conf+= -e '/^Alias/s,^,\#,'
.endif
post-extract:
${CP} ${FILESDIR}/README ${FILESDIR}/createdb.php \
${FILESDIR}/geeklog.conf ${WRKDIR}
pre-install:
${FIND} ${WRKSRC:Q} -name "*.orig*" -exec ${RM} -f {} \;
cd ${WRKSRC}/public_html; \
${FIND} ${GEEKLOG_TMPL_SUB} -type f -exec ${CHMOD} -x {} \;
cd ${WRKSRC}/system; \
${FIND} pear -type f -exec ${CHMOD} 0644 {} \;
do-install:
${INSTALL_DATA_DIR} ${GEEKLOG_DOCDIR}
${INSTALL_DATA} ${WRKDIR}/README ${GEEKLOG_DOCDIR}
.for f in ${GEEKLOG_CONF_FILES}
${INSTALL_DATA_DIR} ${GEEKLOG_EXAMPLESDIR}/${f:H}
${INSTALL_DATA} ${WRKSRC}/${f} ${GEEKLOG_EXAMPLESDIR}/${f}
${RM} ${WRKSRC}/${f}
.endfor
${INSTALL_DATA} ${WRKDIR}/createdb.php ${GEEKLOG_EXAMPLESDIR}
${INSTALL_DATA} ${WRKDIR}/geeklog.conf ${GEEKLOG_EXAMPLESDIR}
cd ${WRKSRC}; ${CP} -R ${GEEKLOG_SYS} ${GEEKLOG_DIR}
.for d in ${GEEKLOG_TMPL_SUB}
cd ${WRKSRC}/public_html; \
if [ -d ${d} ]; then \
${PAX} -rw ${d} ${GEEKLOG_TMPL_DIR}; \
${RM} -rf ${d}; \
fi
.endfor
cd ${WRKSRC}/public_html; ${PAX} -rw . ${GEEKLOG_PUBDIR}
.include "../../mk/apachever.mk"
.include "../../lang/php/phpversion.mk"
.include "../../mk/bsd.pkg.mk"
|