[svn:modperl-modules] rev 254 - in Apache-Peek/trunk: . t/response/TestApachePeek

[email protected]@cvs.perl.org 26 Jul 2005 06:56:13 -0000
Newsgroups perl.modperl.modules.svn
Message-ID <[email protected]>
Author: [email protected]
Date: Mon Jul 25 23:56:13 2005
New Revision: 254

Added:
   Apache-Peek/trunk/Peek.pm
Modified:
   Apache-Peek/trunk/Changes
   Apache-Peek/trunk/Makefile.PL
   Apache-Peek/trunk/TODO
   Apache-Peek/trunk/t/response/TestApachePeek/basic.pm
Log:
update distributtion to ship with place holder Peek.pm for PAUSE/CPAN indexer


Modified: Apache-Peek/trunk/Changes
==============================================================================
--- Apache-Peek/trunk/Changes	(original)
+++ Apache-Peek/trunk/Changes	Mon Jul 25 23:56:13 2005
@@ -3,7 +3,10 @@
 
 Revision history for Perl extension Apache::Peek.
 
-=head1 1.04 - 
+=head1 1.04 - Tues Jul 26 02:50:00 EST 2005
+- Distrubute placeholder Peek.pm to appease the PAUSE indexer
+  per Andreas J. Koenig <[email protected]>
+  [Philip M. Gollucci <[email protected]>]
 
 =head1 1.03 - Mon July 9 20:00:00 EST 2005
 - Adapt to the new mp2 API RC5+

Modified: Apache-Peek/trunk/Makefile.PL
==============================================================================
--- Apache-Peek/trunk/Makefile.PL	(original)
+++ Apache-Peek/trunk/Makefile.PL	Mon Jul 25 23:56:13 2005
@@ -123,6 +123,8 @@ sub prepare_build ($$) {
   }
 
   # adjust the version and glue the doc (open() for 5.005_03 support)
+  unlink "Peek.pm" if "Peek.pm";
+
   my ($in, $out) = ($pm, 'Peek.pm');
   my ($ifh, $ofh) = (Symbol::gensym(), Symbol::gensym());
   open $ifh,  "<$in"  or die "can't open $in: $!";

Added: Apache-Peek/trunk/Peek.pm
==============================================================================
--- (empty file)
+++ Apache-Peek/trunk/Peek.pm	Mon Jul 25 23:56:13 2005
@@ -0,0 +1,91 @@
+# WARNING: DO NOT EDIT THIS FILE, EDIT Peek.pm.mp2.perl5.8 instead
+
+package Apache::Peek;
+
+use strict;
+use warnings;
+
+use XSLoader ();
+use base qw(Exporter Devel::Peek);
+
+our $VERSION = 1.04;
+our @EXPORT = qw(Dump DumpArray);
+
+use mod_perl2;
+die "This module was built against mod_perl 2.0 ", 
+    "and can't be used with $mod_perl2::VERSION, "
+    unless $mod_perl2::VERSION > 1.99022;
+
+XSLoader::load 'Apache::Peek';
+
+1;
+__END__
+
+=head1 NAME
+
+Apache::Peek - A data debugging tool for the XS programmer (under mod_perl)
+
+=head1 SYNOPSIS
+
+        use Apache::Peek;
+        Dump( $a );
+        Dump( $a, 5 );
+        DumpArray( 5, $a, $b, ... );
+
+        # more functionality inherited from Devel::Peek
+
+=head1 DESCRIPTION
+
+C<Apache::Peek> is a sub-class of C<Devel::Peek>. The only difference
+is that it overrides the stderr stream, to which C<Devel::Peek> sends
+its output, and send the output to the client instead.
+
+Note: The following table summarizes what parts of the
+C<Devel::Peek>'s API are available, depending on the used Perl version
+and configurations:
+
+  5.005_0x                 all
+  5.6.x                    only Dump()
+  5.8.x (w/  -Duseperlio)  all
+  5.8.x (w/o -Duseperlio)  none
+
+Patches to complete the functionality under all configurations are
+welcome.
+
+C<Apache::Peek> works both with mod_perl 1.0 and 2.0.
+
+See the C<Devel::Peek> manpage for a complete documentation.
+
+
+
+=head1 Author
+
+Hacking the mod_perl versions:
+
+Philip M. Gollucci      [email protected]
+
+Previously: Doug MacEachern and Stas Bekman
+
+Writing the original C<Devel::Peek>
+
+Ilya Zakharevich	[email protected]
+
+
+
+=head1 Copyright
+
+Copyright (c) 1995-98 Ilya Zakharevich. All rights reserved.
+This program is free software; you can redistribute it and/or
+modify it under the same terms as Perl itself.
+
+Author of this software makes no claim whatsoever about suitability,
+reliability, edability, editability or usability of this product, and
+should not be kept liable for any damage resulting from the use of
+it. If you can use it, you are in luck, if not, I should not be kept
+responsible. Keep a handy copy of your backup tape at hand.
+
+=head1 SEE ALSO
+
+L<perlguts>, and L<perlguts>, again.
+
+=cut

Modified: Apache-Peek/trunk/TODO
==============================================================================
--- Apache-Peek/trunk/TODO	(original)
+++ Apache-Peek/trunk/TODO	Mon Jul 25 23:56:13 2005
@@ -1,22 +0,0 @@
-- the indexer fails to see the packages, due to their naming (not .pm)
- 
--------------------------------------
-The following report has been written by the PAUSE namespace indexer.
-Please contact [email protected] if there are any open questions.
-  Id: mldistwatch 528 2004-12-30 17:08:44Z k 
-
-               User: STAS (Stas Bekman)
-  Distribution  Apache-Peek-1.02.tar.gz
-    Number of files: 20
-         *.pm files: 1
-             README: Apache-Peek-1.02/README
-           META.yml: Apache-Peek-1.02/META.yml
-  Timestamp of  Mon Jan  3 18:37:30 2005 UTC
-   Time of this run: Mon Jan  3 20:00:23 2005 UTC
-
-No package statements could be found in the distro (maybe a script
-or documentation distribution?)
--------------------------------------
-
-check if META.yml can be used to workaround this problem. Or may be go back 
-to the sub-dirs approach.

Modified: Apache-Peek/trunk/t/response/TestApachePeek/basic.pm
==============================================================================
--- Apache-Peek/trunk/t/response/TestApachePeek/basic.pm	(original)
+++ Apache-Peek/trunk/t/response/TestApachePeek/basic.pm	Mon Jul 25 23:56:13 2005
@@ -3,8 +3,9 @@ package TestApachePeek::basic;
 use strict;
 use warnings FATAL => 'all';
 
-use mod_perl2;
-use constant MP2 => 1;
+eval { require mod_perl2 };
+
+use constant MP2 => $@ ? 0 : 1;
 
 BEGIN {
     if (MP2) {