source: trunk/dports/net/icmpmonitor/Portfile

Last change on this file was 112263, checked in by jmr@…, 4 years ago

icmpmonitor: license

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 1.3 KB
Line 
1# $Id: Portfile 112263 2013-10-16 06:14:00Z ryandesign@macports.org $
2
3PortSystem 1.0
4
5name                    icmpmonitor
6version                 1.2
7categories              net
8license                 GPL-2+
9platforms               darwin
10maintainers             nomaintainer
11description             simple network monitor using icmp to check for hosts
12long_description        Using the InterNet Control Message Protocol (ICMP) "ECHO" \
13                        facility, monitors several hosts, and notify admin if some of them \
14                        are down.
15
16homepage                http://icmpmonitor.sourceforge.net/
17master_sites    sourceforge
18checksums               md5 c6c9bfc14f914604232945185be387b3
19patchfiles              patch-icmpmonitor.c
20
21post-patch {
22        reinplace "s|__ETCDIR__|${prefix}/etc|g" ${worksrcpath}/icmpmonitor.c
23}
24
25configure.args  --mandir=\\\${prefix}/share/man
26
27destroot.destdir        prefix=${destroot}${prefix}
28post-destroot {
29        xinstall -m 755 -d ${destroot}${prefix}/share/doc/${name} \
30                ${destroot}${prefix}/var/run/
31        xinstall -m 644 ${worksrcpath}/sample.cfg \
32                ${destroot}${prefix}/etc/icmpmonitor.cfg.sample
33        xinstall -m 644 -W ${worksrcpath} ChangeLog NEWS README TODO \
34                ${destroot}${prefix}/share/doc/${name}
35        system "touch ${destroot}${prefix}/var/run/icmpmonitor.pid"
36}
37
38startupitem.create      yes
39startupitem.init        \
40        "PID=${prefix}/var/run/${name}.pid\nBIN=${prefix}/sbin/icmpmonitor"
41startupitem.start       "\[ -x \${BIN} \] && \${BIN} &; echo \$! > \${PID}"
42startupitem.stop        "\[ -r \${PID} \] && /bin/kill \$(cat \${PID})"
Note: See TracBrowser for help on using the repository browser.