Tue, 28 Aug 2012 18:35:40 +0200
Update version, modernize packaging, accommodate libevent version 2 opaque
evbuffer datatype, port Linux style flock(2) to SVR4, include correct
non BSD and non SVR4 headers in DNS and resolving logic, correctly
include a arc4random(3) implementation for platforms lacking it,
conditionally implement the nonstandard MIN(a,b) macro, and use
parallel make for faster SMP and multicore builds.
1 #! @l_prefix@/bin/perl
2 ##
3 ## uptime.pl: provide formatted uptime(1) information
4 ##
6 $null = 0;
7 $uptime = `uptime`;
8 $hostname = `hostname`;
10 $uptime =~ /up (.*?) day/;
11 $up = int($1);
13 # According to http://oss.oetiker.ch/mrtg/doc/mrtg-reference.en.html
14 # 'the external command must return 4 lines of output.'
15 print "$up\n";
16 print "$up\n";
17 print "$null\n";
18 print "$null\n";