blob: a4706a3107a8f52d8b5574af9ac1c4e60683c888 (
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
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
|
# New ports collection makefile for: prado
# Date created: 04 January 2008
# Whom: Greg Larkin <glarkin@FreeBSD.org>
#
# $FreeBSD$
#
PORTNAME= prado
PORTVERSION= 3.1.2.r2448
CATEGORIES= www
MASTER_SITES= SF
MAINTAINER= glarkin@FreeBSD.org
COMMENT= A framework for developing PHP web applications
USE_ZIP= yes
USE_APACHE= 2.0+
NO_BUILD= yes
USE_PHP= session
WANT_PHP_WEB= yes
SUB_FILES= pkg-message
OPTIONS= PROD "Install for production server (see: make confighelp)" Off \
REQPHP "Install required PHP dependencies" On \
OPTPHP "Install optional PHP dependencies" Off
PLIST_SUB+= CONFDIR=${CONFDIR_REL}
CONFDIR= ${PREFIX}/${CONFDIR_REL}
CONFDIR_REL= ${APACHEETCDIR}/Includes
.include <bsd.port.pre.mk>
WITH_PHP_CGI?= /cgi-bin/php
.if ${PHP_SAPI:Mcgi} == "cgi" && ${PHP_SAPI:Mmod} == ""
CGI_EXT= -cgi
.else
CGI_EXT=
.endif
DEFAULT_PHP_VER=5
IGNORE_WITH_PHP=4
SUB_LIST+= PHPCGI=${WITH_PHP_CGI}
.if defined(WITH_PROD)
PROD= production
.else
PROD= development
.endif
.if defined(NOPORTDOCS)
SUB_LIST+= HASHMARK=\#
.else
SUB_LIST+= HASHMARK=
.endif
CONF= prado-${PROD}${CGI_EXT}.conf
SUB_FILES+= ${CONF}
.if defined(WITH_REQPHP)
USE_PHP+= dom spl ctype pcre
.endif
.if defined(WITH_OPTPHP)
USE_PHP+= pdo iconv zlib sqlite memcache mcrypt xsl soap
RUN_DEPENDS+= ${LOCALBASE}/lib/php/${PHP_EXT_DIR}/apc.so:${PORTSDIR}/www/pecl-APC
.endif
confighelp:
@${ECHO_MSG} ""
@${ECHO_MSG} "On a production server, the Apache DocumentRoot is"
@${ECHO_MSG} "updated to point to the Prado webroot directory."
@${ECHO_MSG} "In this configuration, the Prado application is"
@${ECHO_MSG} "accessed at http://www.myservername.com/."
@${ECHO_MSG} ""
@${ECHO_MSG} "A non-production server, Prado is installed at"
@${ECHO_MSG} "the /prado URL, and the Prado application is"
@${ECHO_MSG} "accessed at http://www.myservername.com/prado/."
@${ECHO_MSG} ""
@${ECHO_MSG} "For more information, please see:"
@${ECHO_MSG} "http://www.pradosoft.com/wiki/index.php/Installation"
@${ECHO_MSG} ""
post-configure:
@cd ${WRKSRC} && ${MV} "HISTORY" "UPGRADE" docs/
do-install:
@cd ${WRKSRC} && ${COPYTREE_SHARE} "index.html demos editors \
framework requirements tests" ${WWWDIR}
@${CHOWN} -R ${WWWOWN}:${WWWGRP} ${WWWDIR}
@${FIND} ${WWWDIR} -type f -print0 | ${XARGS} -0 ${CHMOD} 644
@${FIND} ${WWWDIR} -type d -print0 | ${XARGS} -0 ${CHMOD} 755
@${ECHO_CMD} '@exec ${CHOWN} -R ${WWWOWN}:${WWWGRP} \
${WWWDIR}' >> ${TMPPLIST}
@${ECHO_CMD} '@exec ${FIND} ${WWWDIR} -type f -print0 | \
${XARGS} -0 ${CHMOD} 644' >> ${TMPPLIST}
@${ECHO_CMD} '@exec ${FIND} ${WWWDIR} -type d -print0 | \
${XARGS} -0 ${CHMOD} 755' >> ${TMPPLIST}
post-install:
@if [ -d "${CONFDIR}" ]; then \
${CP} ${WRKDIR}/${CONF} ${CONFDIR}/prado.conf; \
else \
${ECHO_MSG} "" ; \
${ECHO_MSG} "Please check your Apache 2.x installation -" ; \
${ECHO_MSG} "${CONFDIR} doesn't exist," ; \
${ECHO_MSG} "so I cannot install prado.conf there!" ; \
${ECHO_MSG} "" ; \
${FALSE} ; \
fi
.if !defined(NOPORTDOCS)
@cd ${WRKSRC}/docs && ${COPYTREE_SHARE} . ${DOCSDIR}
.endif
@${CAT} ${PKGMESSAGE}
.if ${CGI_EXT} == "-cgi"
@${ECHO_MSG} ""
@${ECHO_MSG} "Your Prado installation was configured to use the PHP CGI binary."
@${ECHO_MSG} "The PHP CGI binary is expected to be referenced by the URL:"
@${ECHO_MSG} ""
@${ECHO_MSG} " ${WITH_PHP_CGI}"
@${ECHO_MSG} ""
@${ECHO_MSG} "If this is incorrect, reinstall the port with the WITH_PHP_CGI knob"
@${ECHO_MSG} "set to the correct URL."
.endif
@${ECHO_MSG} "*********************************************************************"
.include <bsd.port.post.mk>
|