Revision history for Perl extension Time::HiRes.
+1.72 - going back to the 1.68 loader setup (using DynaLoader)
+ since too many weird things starting breaking
+ - fix a typo in José Auguste-Etienne's name
+
1.71 - a thinko in the nanosleep() detection
- move more changes stuff from the README to Changes
- add -w to the Makefile.PL
(realtime POSIX?) libs and whatnot, but in the general case
running a real test case is better. (Of course, this change
will no doubt run into portability problems because of the
- execution step...)
- (from José Auguste-tienne)
+ execution step...) Note that because of hysterical raisins
+ most Perls do NOT have $Config{d_nanosleep} (scanning for
+ it by Configure would in many platforms require linking in
+ things like -lrt, which would in many platforms be a bad idea
+ for Perl itself).
+ (from José Auguste-Etienne)
- support XSLoader also since it's much faster
(from Alexey Tourbin)
- add SEE ALSO (BSD::Resource and Time::TAI64)
require Exporter;
require DynaLoader;
-@ISA = qw(Exporter);
+@ISA = qw(Exporter DynaLoader);
@EXPORT = qw( );
@EXPORT_OK = qw (usleep sleep ualarm alarm gettimeofday time tv_interval
d_usleep d_ualarm d_gettimeofday d_getitimer d_setitimer
d_nanosleep);
-$VERSION = '1.71';
+$VERSION = '1.72';
$XS_VERSION = $VERSION;
$VERSION = eval $VERSION;
($constname = $AUTOLOAD) =~ s/.*:://;
die "&Time::HiRes::constant not defined" if $constname eq 'constant';
my ($error, $val) = constant($constname);
- if ($error) { die $error; }
+ if ($error) {
+ my (undef,$file,$line) = caller;
+ die "$error at $file line $line.\n";
+ }
{
no strict 'refs';
*$AUTOLOAD = sub { $val };
goto &$AUTOLOAD;
}
-eval {
- require XSLoader;
- XSLoader::load('Time::HiRes', $XS_VERSION);
- 1;
-} or do {
- require DynaLoader;
- local @ISA = qw(DynaLoader);
- bootstrap Time::HiRes $XS_VERSION;
-};
+bootstrap Time::HiRes;
# Preloaded methods go here.
then carefully read your C<nanosleep()> C API documentation for any
peculiarities.
-Unless using C<nanosleep> for mixing sleeping with signals, give
-some thought to whether Perl is the tool you should be using for
-work requiring nanosecond accuracies.
+If you are using C<nanosleep> for something else than mixing sleeping
+with signals, give some thought to whether Perl is the tool you should
+be using for work requiring nanosecond accuracies.
The following functions can be imported from this module.
No functions are exported by default.
Copyright (c) 1996-2002 Douglas E. Wegscheid. All rights reserved.
-Copyright (c) 2002,2003,2004,2005 Jarkko Hietaniemi. All rights reserved.
+Copyright (c) 2002, 2003, 2004, 2005 Jarkko Hietaniemi. All rights reserved.
This program is free software; you can redistribute it and/or modify
it under the same terms as Perl itself.