FreeBSD Bugzilla – Attachment 144181 Details for
Bug 190022
[patch] Add staging support to www/cakephp23
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Stage support to cakephp23
cakephp23-2-staging.patch.txt (text/plain), 7.58 KB, created by
joe
on 2014-06-27 00:36:28 UTC
(
hide
)
Description:
Stage support to cakephp23
Filename:
MIME Type:
Creator:
joe
Created:
2014-06-27 00:36:28 UTC
Size:
7.58 KB
patch
obsolete
>diff --git a/www/cakephp23/Makefile b/www/cakephp23/Makefile >index da9ac44..af1d042 100644 >--- a/www/cakephp23/Makefile >+++ b/www/cakephp23/Makefile >@@ -24,7 +24,7 @@ NO_BUILD= yes > USES= gettext > USE_PHP= ctype session > WANT_PHP_WEB= yes >-DEFAULT_PHP_VER=5 >+DEFAULT_VERSIONS= php=5 > > CAKE_CONF_FILES= \ > app/Config/acl.php \ >@@ -49,7 +49,6 @@ MEMCACHE_DESC= Enable Memcached caching engine client > CONFDIR= ${PREFIX}/${CONFDIR_REL} > CONFDIR_REL= ${APACHEETCDIR}/Includes > >-NO_STAGE= yes > .include <bsd.port.pre.mk> > > WITH_PHP_CGI?= /cgi-bin/php >@@ -133,49 +132,49 @@ post-patch: > # Rename config files so we don't overwrite those in an existing installation > @for i in ${CAKE_CONF_FILES}; do \ > if [ -f ${WRKSRC}/$$i ]; then \ >- ${MV} ${WRKSRC}/$$i ${WRKSRC}/$$i.default; \ >+ ${MV} ${WRKSRC}/$$i ${WRKSRC}/$$i.sample; \ > fi \ > done >+ ${MV} ${WRKSRC}/app/Config/database.php.default \ >+ ${WRKSRC}/app/Config/database.php.sample >+ ${MV} ${WRKSRC}/app/Config/email.php.default \ >+ ${WRKSRC}/app/Config/email.php.sample > > do-install: > @cd ${WRKSRC} && ${COPYTREE_SHARE} \ >- ".htaccess app lib index.php plugins vendors" ${WWWDIR} >+ ".htaccess app lib index.php plugins vendors" ${STAGEDIR}${WWWDIR} > > .if empty(PORT_OPTIONS:MPROD) > # If installed in development mode, get rid of .htaccess files, > # as noted by: > # http://book.cakephp.org/view/42/The-Configuration-Class#CakePHP-Core-Configuration-Variables-44 >- @${FIND} ${WWWDIR} -type f -name .htaccess -exec ${RM} {} \; >+ @${FIND} ${STAGEDIR}${WWWDIR} -type f -name .htaccess -exec ${RM} {} \; > @${ECHO_CMD} '@exec ${FIND} ${WWWDIR:S|^${PREFIX}/|%D/|} -type f -name .htaccess -exec ${RM} {} \;' >> ${TMPPLIST} > .endif > > # Get rid of the empty placeholder files >- @${FIND} ${WWWDIR} -type f -name empty -size 0 -exec ${RM} {} \; >+ @${FIND} ${STAGEDIR}${WWWDIR} -type f -name empty -size 0 -exec ${RM} {} \; > @${ECHO_CMD} '@exec ${FIND} ${WWWDIR:S|^${PREFIX}/|%D/|} -type f -name empty -size 0 -exec ${RM} {} \;' >> ${TMPPLIST} > >- @${CHOWN} -R ${WWWOWN}:${WWWGRP} ${WWWDIR} >+ @${CHOWN} -R ${WWWOWN}:${WWWGRP} ${STAGEDIR}${WWWDIR} > @${ECHO_CMD} '@exec ${CHOWN} -R ${WWWOWN}:${WWWGRP} \ > ${WWWDIR:S|^${PREFIX}/|%D/|}' >> ${TMPPLIST} >- @${FIND} ${WWWDIR} -type f -print0 | ${XARGS} -0 ${CHMOD} 644 >+ @${FIND} ${STAGEDIR}${WWWDIR} -type f -print0 | ${XARGS} -0 ${CHMOD} 644 > @${ECHO_CMD} '@exec ${FIND} ${WWWDIR} -type f -print0 | \ > ${XARGS} -0 ${CHMOD} 644' >> ${TMPPLIST} >- @${FIND} ${WWWDIR} -type d -print0 | ${XARGS} -0 ${CHMOD} 755 >+ @${FIND} ${STAGEDIR}${WWWDIR} -type d -print0 | ${XARGS} -0 ${CHMOD} 755 > @${ECHO_CMD} '@exec ${FIND} ${WWWDIR} -type d -print0 | \ > ${XARGS} -0 ${CHMOD} 755' >> ${TMPPLIST} > > # Fix the permissions of the Cake console script >- @${CHMOD} 755 ${WWWDIR}/${CAKE_CONSOLE} >+ @${CHMOD} 755 ${STAGEDIR}${WWWDIR}/${CAKE_CONSOLE} > @${ECHO_CMD} '@exec ${CHMOD} 755 ${WWWDIR}/${CAKE_CONSOLE}' >> ${TMPPLIST} > > post-install: >- @for i in ${CAKE_CONF_FILES}; do \ >- if [ ! -f ${WWWDIR}/$$i -a -f ${WRKSRC}/$$i.default ]; then \ >- ${INSTALL_DATA} ${WRKSRC}/$$i.default ${WWWDIR}/$$i; \ >- fi \ >- done > .if ${PORT_OPTIONS:MAP} >- @if [ -d "${CONFDIR}" ]; then \ >- ${CP} ${WRKDIR}/${CONF} ${CONFDIR}/cakephp.conf; \ >+ @${MKDIR} ${STAGEDIR}${CONFDIR} >+ @if [ -d "${STAGEDIR}${CONFDIR}" ]; then \ >+ ${CP} ${WRKDIR}/${CONF} ${STAGEDIR}${CONFDIR}/cakephp.conf; \ > else \ > ${ECHO_MSG} "" ; \ > ${ECHO_MSG} "Please check your Apache 2.x installation -" ; \ >@@ -185,11 +184,8 @@ post-install: > ${FALSE} ; \ > fi > .endif >-.if ${PORT_OPTIONS:MDOCS} >- @${INSTALL} -d ${DOCSDIR} >- @cd ${WRKSRC} && ${INSTALL_DATA} ${PORTDOCS} ${DOCSDIR} >-.endif >- @${CAT} ${PKGMESSAGE} >+ @${INSTALL} -d ${STAGEDIR}${DOCSDIR} >+ @cd ${WRKSRC} && ${INSTALL_DATA} ${PORTDOCS} ${STAGEDIR}${DOCSDIR} > .if ${CGI_EXT} == "-cgi" > @${ECHO_MSG} "" > @${ECHO_MSG} "Your CakePHP installation was configured to use the PHP CGI binary." >diff --git a/www/cakephp23/pkg-plist b/www/cakephp23/pkg-plist >index 2500759..5999f97 100644 >--- a/www/cakephp23/pkg-plist >+++ b/www/cakephp23/pkg-plist >@@ -1,26 +1,12 @@ > %%HTACCESS%%%%WWWDIR%%/.htaccess > %%HTACCESS%%%%WWWDIR%%/app/.htaccess >-@unexec if cmp -s %D/%%WWWDIR%%/app/Config/acl.php.default %D/%%WWWDIR%%/app/Config/acl.php; then rm -f %D/%%WWWDIR%%/app/Config/acl.php; else %%ECHO_MSG%% "===> Customized %D/%%WWWDIR%%/app/Config/acl.php has not been removed"; fi >-%%WWWDIR%%/app/Config/acl.php.default >-@exec if [ ! -f %B/acl.php ]; then cp -p %B/acl.php.default %B/acl.php; else %%ECHO_MSG%% "===> Customized %B/acl.php has not been overwritten"; fi >-@unexec if cmp -s %D/%%WWWDIR%%/app/Config/acl.ini.php.default %D/%%WWWDIR%%/app/Config/acl.ini.php; then rm -f %D/%%WWWDIR%%/app/Config/acl.ini.php; else %%ECHO_MSG%% "===> Customized %D/%%WWWDIR%%/app/Config/acl.ini.php has not been removed"; fi >-%%WWWDIR%%/app/Config/acl.ini.php.default >-@exec if [ ! -f %B/acl.ini.php ]; then cp -p %B/acl.ini.php.default %B/acl.ini.php; else %%ECHO_MSG%% "===> Customized %B/acl.ini.php has not been overwritten"; fi >-@unexec if cmp -s %D/%%WWWDIR%%/app/Config/bootstrap.php.default %D/%%WWWDIR%%/app/Config/bootstrap.php; then rm -f %D/%%WWWDIR%%/app/Config/bootstrap.php; else %%ECHO_MSG%% "===> Customized %D/%%WWWDIR%%/app/Config/bootstrap.php has not been removed"; fi >-%%WWWDIR%%/app/Config/bootstrap.php.default >-@exec if [ ! -f %B/bootstrap.php ]; then cp -p %B/bootstrap.php.default %B/bootstrap.php; else %%ECHO_MSG%% "===> Customized %B/bootstrap.php has not been overwritten"; fi >-@unexec if cmp -s %D/%%WWWDIR%%/app/Config/core.php.default %D/%%WWWDIR%%/app/Config/core.php; then rm -f %D/%%WWWDIR%%/app/Config/core.php; else %%ECHO_MSG%% "===> Customized %D/%%WWWDIR%%/app/Config/core.php has not been removed"; fi >-%%WWWDIR%%/app/Config/core.php.default >-@exec if [ ! -f %B/core.php ]; then cp -p %B/core.php.default %B/core.php; else %%ECHO_MSG%% "===> Customized %B/core.php has not been overwritten"; fi >-@unexec if cmp -s %D/%%WWWDIR%%/app/Config/database.php.default %D/%%WWWDIR%%/app/Config/database.php; then rm -f %D/%%WWWDIR%%/app/Config/database.php; else %%ECHO_MSG%% "===> Customized %D/%%WWWDIR%%/app/Config/database.php has not been removed"; fi >-%%WWWDIR%%/app/Config/database.php.default >-@exec if [ ! -f %B/database.php ]; then cp -p %B/database.php.default %B/database.php; else %%ECHO_MSG%% "===> Customized %B/database.php has not been overwritten"; fi >-@unexec if cmp -s %D/%%WWWDIR%%/app/Config/email.php.default %D/%%WWWDIR%%/app/Config/email.php; then rm -f %D/%%WWWDIR%%/app/Config/email.php; else %%ECHO_MSG%% "===> Customized %D/%%WWWDIR%%/app/Config/email.php has not been removed"; fi >-%%WWWDIR%%/app/Config/email.php.default >-@exec if [ ! -f %B/email.php ]; then cp -p %B/email.php.default %B/email.php; else %%ECHO_MSG%% "===> Customized %B/email.php has not been overwritten"; fi >-@unexec if cmp -s %D/%%WWWDIR%%/app/Config/routes.php.default %D/%%WWWDIR%%/app/Config/routes.php; then rm -f %D/%%WWWDIR%%/app/Config/routes.php; else %%ECHO_MSG%% "===> Customized %D/%%WWWDIR%%/app/Config/routes.php has not been removed"; fi >-%%WWWDIR%%/app/Config/routes.php.default >-@exec if [ ! -f %B/routes.php ]; then cp -p %B/routes.php.default %B/routes.php; else %%ECHO_MSG%% "===> Customized %B/routes.php has not been overwritten"; fi >+@sample %%WWWDIR%%/app/Config/acl.php.sample >+@sample %%WWWDIR%%/app/Config/acl.ini.php.sample >+@sample %%WWWDIR%%/app/Config/bootstrap.php.sample >+@sample %%WWWDIR%%/app/Config/core.php.sample >+@sample %%WWWDIR%%/app/Config/database.php.sample >+@sample %%WWWDIR%%/app/Config/email.php.sample >+@sample %%WWWDIR%%/app/Config/routes.php.sample > %%WWWDIR%%/app/Config/Schema/db_acl.php > %%WWWDIR%%/app/Config/Schema/db_acl.sql > %%WWWDIR%%/app/Config/Schema/i18n.php
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 190022
:
142918
| 144181