source: trunk/dports/www/awstats/Portfile

Last change on this file was 143933, checked in by ryandesign@…, 23 months ago

awstats: avoid redirects; remove unnecessary distname directive

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 4.0 KB
Line 
1# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
2# $Id: Portfile 143933 2015-12-28 04:18:32Z ryandesign@macports.org $
3
4PortSystem          1.0
5
6name                awstats
7version             7.0
8categories          www
9platforms           darwin freebsd
10maintainers         guydavis.ca:davis
11
12description         Free real-time logfile analyzer to get advanced web statistics
13
14long_description    AWStats is short for Advanced Web Statistics. It's a free \
15                    tool that generates advanced web (but also ftp or mail) \
16                    server statistics, graphically. \
17                    \
18                    \n\nThis log analyzer works as a CGI or from command line \
19                    and shows you all possible information that your logs \
20                    contain, in a few graphical web pages. It uses a partial \
21                    information file to be able to process large log files, \
22                    often and quickly. \
23                    \
24                    \n\nIt can analyze log files from IIS (W3C log format), \
25                    Apache log files (NCSA combined/XLF/ELF log format or \
26                    common/CLF log format), WebStar and most of all web, \
27                    proxy, WAP, and streaming servers (and FTP servers or \
28                    mail logs).
29
30homepage            http://www.awstats.org
31master_sites        sourceforge:project/awstats/AWStats/${version}/
32
33checksums           md5     3e8e09b9ebe74513bb34290dbcd37b45 \
34                    sha1    733fa7d6a540f4a54f52c69a5f271c789472b0b7 \
35                    rmd160  0bd46afbd3159cf5f3e517b37a43b7d0852fc2a3
36
37depends_lib         path:bin/perl:perl5 port:apache2
38
39patch {
40    reinplace -W ${worksrcpath} -locale C "s|/usr/local|${prefix}|g" \
41        tools/awstats_buildstaticpages.pl \
42        tools/awstats_configure.pl \
43        tools/awstats_updateall.pl \
44        tools/httpd_conf \
45        tools/webmin/awstats-1.9.wbm \
46        wwwroot/cgi-bin/awstats.model.conf \
47        wwwroot/cgi-bin/awstats.pl
48    reinplace -W ${worksrcpath} "s|/usr/bin/perl|${prefix}/bin/perl|g" \
49        tools/awstats_buildstaticpages.pl \
50        tools/awstats_configure.pl \
51        tools/awstats_exportlib.pl \
52        tools/awstats_updateall.pl \
53        tools/logresolvemerge.pl \
54        tools/maillogconvert.pl \
55        tools/urlaliasbuilder.pl \
56        wwwroot/cgi-bin/awstats.pl
57}
58
59use_configure       no
60
61build {}
62
63set docpath         ${prefix}/www/awstats
64
65destroot {
66    xinstall -m 755 -d \
67        ${destroot}${prefix}/share/doc \
68        ${destroot}${prefix}/etc/awstats
69    copy ${worksrcpath}/wwwroot ${destroot}${docpath}
70    copy ${worksrcpath}/tools ${destroot}${docpath}
71    copy ${worksrcpath}/docs ${destroot}${prefix}/share/doc/awstats
72    xinstall -m 755 -W ${worksrcpath} wwwroot/cgi-bin/awstats.model.conf ${destroot}${prefix}/etc/awstats
73}
74
75variant apache description "use apache instead of apache2" {
76    depends_lib-append  port:apache
77    depends_lib-delete  port:apache2
78}
79
80post-install {
81    ui_msg "**********************************************************************"
82    ui_msg "Add the following to your Apache httpd.conf, save, and restart Apache:"
83    ui_msg ""
84    ui_msg "Alias /awstatsclasses \"${docpath}/classes/\""
85    ui_msg "Alias /awstatscss \"${docpath}/css/\""
86    ui_msg "Alias /awstatsicons \"${docpath}/icons/\""
87    ui_msg "ScriptAlias /awstats/ \"${docpath}/cgi-bin/\""
88    ui_msg ""
89    ui_msg "<Directory \"${docpath}/\">"
90    ui_msg "    Options None"
91    ui_msg "    AllowOverride None"
92    ui_msg "    Order allow,deny"
93    ui_msg "        Allow from all"
94    ui_msg "</Directory>"
95    ui_msg ""
96    ui_msg "Find your sample config file in ${prefix}/etc/awstats, rename it to"
97    ui_msg "\"awstats.domain_name.conf\", and edit it to configure Awstats. You"
98    ui_msg "can then access Awstats by pointing your browser to:"
99    ui_msg ""
100    ui_msg "http://yourdomain/awstats/awstats.pl"
101}
102
103livecheck.regex     /${name}-(\[0-9.\]+)${extract.suffix}
104
Note: See TracBrowser for help on using the repository browser.