Ticket #34237: Portfile-dspam.diff

File Portfile-dspam.diff, 4.0 KB (added by compconsultant@…, 12 years ago)
  • Portfile

    old new  
    44PortSystem 1.0
    55
    66name            dspam
    7 version         3.9.0
     7version         3.10.2
    88categories      mail net
    99maintainers     yahoo.com:compconsultant
    1010description     Scalable, open-source statistical anti-spam filter
     
    1515platforms       darwin freebsd
    1616master_sites    sourceforge
    1717
    18 checksums       md5 10d092b57d628d8c91655fee5dc0d0cd \
    19                 sha1 b238f076f67866b5450ae9b8329857b4e2d83dd1 \
    20                 rmd160 cbde359e4e846e8be352c087c4af46148e685761
     18checksums       md5 0e0e405d3284485b2a43f47eaf6b09bb \
     19                sha1 21133e0ee1880f3e8c849365b7e27a73f6d0413a \
     20                rmd160 7e112981e45e483350b9afc056ebfa4c5561036c
    2121
    2222configure.args  --sysconfdir='${prefix}/etc' \
    2323                --mandir='${prefix}/share/man' \
     
    2626
    2727destroot.keepdirs       ${destroot}${prefix}/var/log/dspam
    2828
    29 variant vpopmail {
     29variant vpopmail description Configure dspam to work with vpopmail {
    3030                configure.args-append --with-dspam-home-owner=vpopmail \
    3131                                      --with-dspam-home-group=vchkpw \
    3232                                      --with-dspam-owner=vpopmail \
     
    3434                depends_lib     port:vpopmail
    3535}
    3636
    37 variant mysql5 conflicts postgres sqlite {
     37variant mysql5 conflicts postgres sqlite description Configure dspam to work with MySQL {
    3838                depends_lib     path:bin/mysql_config5:mysql5
    3939                configure.args-append --with-storage-driver=mysql_drv \
    4040                                      --with-mysql-includes=${prefix}/include/mysql5/mysql \
     
    4343                                      --enable-virtual-users
    4444}
    4545
    46 variant sqlite conflicts postgres mysql5 {
     46variant sqlite conflicts postgres mysql5 description Configure dspam to work with sqlite {
    4747                depends_lib     port:sqlite3
    4848                configure.args-append --with-sqlite-libaries=${prefix}/lib
    4949}
    50 variant postgres conflicts sqlite mysql5 {
     50variant postgres conflicts sqlite mysql5 description Configure dspam to work with postgres {
    5151                depends_lib     port:postgresql80
    5252                configure.args-append --with-storage-driver=pgsql_drv \
    5353                                      --with-pgsql-includes=${prefix}/include/pgsql8 \
     
    5555}
    5656
    5757post-destroot {
     58        file rename ${destroot}${prefix}/etc/dspam.conf ${destroot}${prefix}/etc/dspam.sample
    5859        file mkdir ${destroot}${prefix}/var/dspam/samples
    5960        file mkdir ${destroot}${prefix}/share/doc/dspam
    6061        file mkdir ${destroot}${prefix}/var/dspam/mysql
     
    6566        file mkdir ${destroot}${prefix}/var/dspam/webui/htdocs
    6667        file copy ${worksrcpath}/README ${destroot}${prefix}/share/doc/dspam/
    6768        file copy ${worksrcpath}/UPGRADING ${destroot}${prefix}/share/doc/dspam/
     69        file copy ${worksrcpath}/RELEASE.NOTES ${destroot}${prefix}/share/doc/dspam/
     70        file copy ${worksrcpath}/CHANGELOG ${destroot}${prefix}/share/doc/dspam/
    6871        system "cp -R ${worksrcpath}/webui/cgi-bin/* ${destroot}${prefix}/var/dspam/webui/cgi-bin/"
    6972        system "rm ${destroot}${prefix}/var/dspam/webui/cgi-bin/Make*"
    7073        system "cp -R ${worksrcpath}/webui/htdocs/* ${destroot}${prefix}/var/dspam/webui/htdocs/"
    7174        system "rm ${destroot}${prefix}/var/dspam/webui/htdocs/Make*"
    72         file copy ${worksrcpath}/scripts/train.pl ${destroot}${prefix}/var/dspam/samples/
    7375        system "cp ${worksrcpath}/txt/*.txt ${destroot}${prefix}/var/dspam/samples/"
    7476        system "cp ${worksrcpath}/doc/*.txt ${destroot}${prefix}/share/doc/dspam/"
    7577        system "cp -R ${worksrcpath}/src/tools.mysql_drv/*sql ${destroot}${prefix}/var/dspam/mysql"
     
    8082                system "chown -R vpopmail:vchkpw ${destroot}${prefix}/var/log/dspam"
    8183        }
    8284}
     85
     86post-install {
     87ui_msg "\n
     88Please create the dspam configuration file ${prefix}/etc/dspam.conf
     89by using the sample file ${prefix}/etc/dspam.sample as a reference
     90\n"
     91}
     92