Ticket #34899: Portfile-p0f.diff

File Portfile-p0f.diff, 4.0 KB (added by nonstop.server@…, 12 years ago)

proposed patch

  • Portfile

    old new  
     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: Portfile 94315 2012-06-15 02:24:31Z ryandesign@macports.org $
    23
    3 PortSystem 1.0
     4PortSystem       1.0
    45
    5 name              p0f
    6 version           2.0.8
    7 categories        net security
    8 platforms         darwin
    9 maintainers       nomaintainer
    10 description       versatile passive OS fingerprinting, masquerade detection tool
    11 long_description  p0f is a versatile passive OS fingerprinting and \
    12                         masquerade detection utility, to be used for evidence or \
    13                         information gathering on servers, firewalls, IDSes, and \
    14                         honeypots, for pen-testing, or just for the fun of it.
    15 
    16 homepage          http://lcamtuf.coredump.cx/p0f.shtml
    17 master_sites      http://lcamtuf.coredump.cx/p0f/
    18 extract.suffix    .tgz
    19 checksums         sha1 7b4d5b2f24af4b5a299979134bc7f6d7b1eaf875 \
    20                   rmd160 87d5b30d2d5e156b9fdcb026160155f413ce13d3
     6name             p0f
     7version          3.05b
     8categories       net security
     9platforms        darwin
     10license          GNU LGPLv2.1
     11maintainers      nomaintainer
     12description      versatile passive OS fingerprinting, masquerade detection tool
    2113
    22 depends_build     port:gmake
     14long_description \
     15    p0f is a versatile passive OS fingerprinting and masquerade detection \
     16    utility, to be used for evidence or information gathering on servers, \
     17    firewalls, IDSes, and honeypots, for pen-testing, or just for the fun of it.
    2318
    24 worksrcdir        ${name}
    25 patchfiles        p0f.c.patch p0fq.c.patch
     19homepage         http://lcamtuf.coredump.cx/p0f3/
     20master_sites     http://lcamtuf.coredump.cx/p0f3/releases/
    2621
    27 post-patch      {
    28         reinplace "s|/etc/p0f|${prefix}/share/p0f|g" ${worksrcpath}/config.h
     22extract.suffix   .tgz
     23
     24checksums        sha1    e6f39c3811e681272e772f33588aa46b75975708 \
     25                 rmd160  9cafc9668bee3e358f1f1775210cc9855e6a2946
     26
     27depends_build    port:gmake
     28
     29worksrcdir       ${distname}
     30
     31post-patch {
     32    reinplace "s|\"p0f.fp\"|\"${prefix}/share/${name}/p0f.fp\"|g" \
     33        ${worksrcpath}/config.h
    2934}
    3035
    31 use_configure   no
     36use_configure    no
     37
     38build.args       CC=${configure.cc}
    3239
    33 build.args      CC=${configure.cc}
     40post-build {
     41    # build tools not handled by the build.sh script separately
     42    system "cd ${worksrcpath}/tools && make"
     43}
    3444
    35 destroot        {
    36         xinstall -m 755 -s ${worksrcpath}/p0f ${destroot}${prefix}/bin
    37         xinstall -m 644 ${worksrcpath}/p0f.1 ${destroot}${prefix}/share/man/man1
    38         xinstall -m 755 -d ${destroot}${prefix}/share/doc/${name} \
    39                 ${destroot}${prefix}/share/${name}
    40         xinstall -m 644 -W ${worksrcpath} p0f.fp p0fa.fp p0fr.fp p0fo.fp \
    41                 ${destroot}${prefix}/share/${name}
    42         xinstall -m 644 -W ${worksrcpath}/doc COPYING CREDITS ChangeLog KNOWN_BUGS \
    43                 README TODO ${destroot}${prefix}/share/doc/${name}
     45destroot {
     46    xinstall -m 755 -s ${worksrcpath}/${name} ${destroot}${prefix}/bin
     47    xinstall -m 755 -s ${worksrcpath}/tools/${name}-client \
     48        ${destroot}${prefix}/bin
     49    xinstall -m 755 -s ${worksrcpath}/tools/${name}-sendsyn \
     50        ${destroot}${prefix}/bin
     51    xinstall -m 755 -s ${worksrcpath}/tools/${name}-sendsyn6 \
     52        ${destroot}${prefix}/bin
     53# the manpage is unavailable in version 3.05b, uncomment when provided again
     54#    xinstall -m 644 ${worksrcpath}/p0f.1 ${destroot}${prefix}/share/man/man1
     55    xinstall -m 755 -d ${destroot}${prefix}/share/doc/${name} \
     56        ${destroot}${prefix}/share/${name}
     57    xinstall -m 644 -W ${worksrcpath} p0f.fp ${destroot}${prefix}/share/${name}
     58    xinstall -m 644 -W ${worksrcpath}/docs COPYING ChangeLog README TODO \
     59        existential-notes.txt extra-sigs.txt \
     60        ${destroot}${prefix}/share/doc/${name}
     61    xinstall -m 644 -W ${worksrcpath}/tools README-TOOLS \
     62        ${destroot}${prefix}/share/doc/${name}
    4463}
    4564
    4665livecheck.regex ${name}-(\[0-9.\]+b?)${extract.suffix}
    4766livecheck.type  regex
    48 livecheck.url   http://lcamtuf.coredump.cx/p0f3/releases/
     67livecheck.url   [lindex ${master_sites} 0]