Ticket #19507: Portfile.diff

File Portfile.diff, 3.5 KB (added by usx303@…, 16 years ago)

Portfile diff

  • Portfile

     
     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
    12# $Id$
    23
    34PortSystem 1.0
     
    34
    45name             snort
    5 version          2.6.1.5
     6version          2.8.4
    67categories       net
    78maintainers      markd
     
    1819platforms        darwin freebsd
    1920master_sites     ${homepage}dl/current/ \
    2021                 ${homepage}dl/old/
    21 checksums        sha1 14e65990f70dab4e740e0b8116c671364d3ca8c4
    22 patchfiles       patch-etc-snort.conf
    23 depends_lib      port:pcre
    24 configure.args   --mandir=${prefix}/share/man --disable-dynamicplugin
     22checksums        md5 193179da8db8aac5ee6b0a751ce7b76d\
     23                 sha1 2e400f34728613f0e285f28dc38a0ae38733ea22\
     24                 rmd160 3fae1b0a472a5ae73eea323f312364bc9d7e1e2a
     25       
     26#patchfiles       patch-etc-snort.conf
     27depends_lib      port:pcre port:libpcap
     28#configure.args   --mandir=${prefix}/share/man --disable-dynamicplugin
    2529
    26 variant mysql5 {
     30variant mysql5 description {mysql 5 support} {
    2731        depends_lib-append    port:mysql5
    2832        configure.args-append --with-mysql=${prefix}
    2933        patchfiles-append       patch-configure
    3034}
    3135
    32 variant mysql4 {
     36variant mysql4 description {mysql 4 support} {
    3337        depends_lib-append    port:mysql4
    3438        configure.args-append --with-mysql=${prefix}
    3539}
    3640
    37 variant server {
     41variant server description {startupitem} {
    3842    startupitem.create    yes
    3943    startupitem.start "${prefix}/share/${name}/snort.sh"
    4044    startupitem.stop  "/bin/kill \$(cat /var/run/snort_*.pid)"
     
    4852# Copy Snort's etc/ files
    4953        xinstall -d -m 755 ${destroot}${prefix}/etc/${name}
    5054        eval xinstall [glob ${worksrcpath}/etc/*.map] ${destroot}${prefix}/etc/${name}
    51         eval xinstall [glob ${worksrcpath}/etc/*.conf] ${destroot}${prefix}/etc/${name}
     55        eval xinstall [glob ${worksrcpath}/etc/*.conf*] ${destroot}${prefix}/etc/${name}
    5256        file rename ${destroot}${prefix}/etc/${name}/snort.conf ${destroot}${prefix}/etc/${name}/snort.conf.dist
    5357
     58# fix snort.conf.dist
     59        reinplace "s|dynamicpreprocessor directory /usr/local/lib/snort_dynamicpreprocessor/|dynamicpreprocessor directory ${prefix}/lib/snort_dynamicpreprocessor/|g" ${destroot}${prefix}/etc/${name}/snort.conf.dist
     60        reinplace "s|dynamicengine /usr/local/lib/snort_dynamicengine/libsf_engine.so|dynamicengine ${prefix}/lib/snort_dynamicengine/libsf_engine.dylib|g" ${destroot}${prefix}/etc/${name}/snort.conf.dist
     61        reinplace "s|dynamicdetection directory /usr/local/lib/snort_dynamicrule/|dynamicdetection directory ${prefix}/lib/snort_dynamicrule/|g" ${destroot}${prefix}/etc/${name}/snort.conf.dist
     62        reinplace "s|dynamicdetection file /usr/local/lib/snort_dynamicrule/libdynamicexamplerule.so|dynamicdetection file ${prefix}/lib/snort_dynamicrule/libdynamicexamplerule.dylib|g" ${destroot}${prefix}/etc/${name}/snort.conf.dist
     63
     64
    5465        if { [variant_isset server] } {
    5566                xinstall -m 755 ${portpath}/${filesdir}/snort.sh \
    5667                        ${destroot}${prefix}/share/${name}/snort.sh
     
    6576                ***** File locations *****
    6677
    6778        The Snort database schemas -> ${prefix}/share/${name}/schemas
    68         The snort.conf sample file -> ${prefix}/etc/${name}/snort.conf.sample (rename to snort.conf)
     79        The snort.conf sample file -> ${prefix}/etc/${name}/snort.conf.dist (rename to snort.conf)
    6980
    7081NOTE:   If you installed Snort using the +server variant, make sure you do not
    7182        change the location of the snort.conf file or the startup scripts