[46696] trunk/dports/www
Ryan Schmidt
ryandesign at macports.org
Tue Feb 10 17:15:38 PST 2009
On Feb 10, 2009, at 14:21, snc at macports.org wrote:
> Revision: 46696
> http://trac.macports.org/changeset/46696
> Author: snc at macports.org
> Date: 2009-02-10 12:21:26 -0800 (Tue, 10 Feb 2009)
> Log Message:
> -----------
> created wikkawiki, ticket #17724
>
> Added Paths:
> -----------
> trunk/dports/www/wikkawiki/
> trunk/dports/www/wikkawiki/Portfile
>
> Added: trunk/dports/www/wikkawiki/Portfile
> ===================================================================
> --- trunk/dports/www/wikkawiki/Portfile
> (rev 0)
> +++ trunk/dports/www/wikkawiki/Portfile 2009-02-10 20:21:26 UTC
> (rev 46696)
> @@ -0,0 +1,82 @@
> +# c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
If possible, please use the standard modeline defined in the Guide.
> +# $Id$
> +
> +PortSystem 1.0
> +
> +name wikkawiki
> +set major_version 1.1.6
> +version ${major_version}.5
> +categories www php
> +maintainers wikkawiki.org:brian
> +description WikkaWiki is a flexible, standards-compliant
> and lightweight wiki engine.
> +long_description WikkaWiki is a flexible, standards-compliant
> and \
> + lightweight wiki engine written in PHP, which
> uses MySQL \
> + to store pages. Forked from WakkaWiki.
> Designed for \
> + speed, extensibility, and security. For
> installation \
> + instructions, visit http://docs.wikkawiki.org/
> MacportInstall
> +homepage http://www.wikkawiki.org
> +distname Wikka-${version}
> +master_sites http://wikkawiki.org/downloads/
> +checksums md5 e1f3b98b98ff5fb6b22fa4848b54317b \
> + sha1 2d2e114d69223f759a5e0261887748112eba24b2
> +platforms darwin freebsd
> +
> +depends_lib \
> + port:php4 \
> + port:mysql4
> +
> +variant php5 description {Use php5 instead of php4 (not fully
> tested)} {
> + depends_lib-append port:php5
Dependency on php5 should be written "path:bin/php:php5" so that php5-
devel could satisfy the dependency.
> + depends_lib-delete port:php4
> +}
> +
> +variant mysql5 description {Use mysql5 instead of mysql4 (not
> fully tested)} {
> + depends_lib-append port:mysql5
Dependency on mysql5 should be written "path:bin/
mysql_config5:mysql5" so that mysql5-devel could satisfy the
dependency. However, does wikkawiki really require a MySQL server to
be present on the same computer? Is it not sufficient to access a
MySQL server on another computer? If so, no dependency on a MySQL
port should be stated.
> + depends_lib-delete port:mysql4
> +}
> +
> +variant nodeps description {Use existing php/mysql libs} {
> + depends_lib-delete port:php4
> + depends_lib-delete port:mysql4
> +}
> +
> +variant use_osx_docroot conflicts php5 mysql5 requires nodeps
> description {Create link to /Library/WebServer/Documents} {}
> +
> +use_configure no
> +build {}
> +
> +set wikkapath ${destroot}${prefix}/www/wikka
> +set osxdocpath /Library/WebServer/Documents
> +
> +destroot {
> + xinstall -d -m 0755 ${wikkapath}
> + eval file copy [glob ${worksrcpath}/*] ${wikkapath}
> + xinstall -m 0666 ${worksrcpath}/.htaccess ${wikkapath}
> + touch ${wikkapath}/wikka.config.php
> + file attributes ${wikkapath}/wikka.config.php -permissions 0666
> +
> + if {[variant_isset use_osx_docroot]} {
> + file delete -force ${osxdocpath}/wikka
> + ln -s ${prefix}/www/wikka ${osxdocpath}/wikka
> + }
> +}
The port should not be manipulating files outside of the destroot.
Please rework the destroot phase so that the symlink in the
osxdocpath is created inside the destroot.
It's also clearer if you put variant tasks in the variant itself. So
remove the "if {[variant_isset use_osx_docroot]}" section from the
global destroot proc, and change the use_osx_docroot variant to
something like this:
variant use_osx_docroot conflicts php5 mysql5 requires nodeps
description {Create link in /Library/WebServer/Documents} {
post-destroot {
xinstall -d ${destroot}/Library
xinstall -d ${destroot}/Library/WebServer
xinstall -d ${destroot}/Library/WebServer/Documents
ln -s ${prefix}/www/wikka ${destroot}/Library/WebServer/
Documents/wikka
}
}
More information about the macports-dev
mailing list