From: Gisle Aas Date: Mon, 15 Aug 2005 21:05:22 +0000 (-0700) Subject: Time::HiRes::nanosleep support for Solaris [PATCH] X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=3db79780c8c68c9c0d40bc69eacba51360a89b19;p=p5sagit%2Fp5-mst-13.2.git Time::HiRes::nanosleep support for Solaris [PATCH] Message-ID: p4raw-id: //depot/perl@25295 --- diff --git a/ext/Time/HiRes/hints/solaris.pl b/ext/Time/HiRes/hints/solaris.pl index 267cf58..6cc80e7 100644 --- a/ext/Time/HiRes/hints/solaris.pl +++ b/ext/Time/HiRes/hints/solaris.pl @@ -1,6 +1,7 @@ -use POSIX qw(uname); # 2.6 has nanosleep in -lposix4, after that it's in -lrt -if (substr((uname())[2], 2) <= 6) { +my $r = `/usr/bin/uname -r`; +chomp($r); +if (substr($r, 2) <= 6) { $self->{LIBS} = ['-lposix4']; } else { $self->{LIBS} = ['-lrt'];