joes 2004/07/23 00:11:09
Modified: glue/perl Makefile.PL
Log:
Try to make doc_tests work on Win32 by replacing Makefile patterns with a
test_docs sub.
Revision Changes Path
1.12 +12 -6 httpd-apreq-2/glue/perl/Makefile.PL
Index: Makefile.PL
===================================================================
RCS file: /home/cvs/httpd-apreq-2/glue/perl/Makefile.PL,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -r1.11 -r1.12
--- Makefile.PL 23 Jul 2004 05:37:57 -0000 1.11
+++ Makefile.PL 23 Jul 2004 07:11:09 -0000 1.12
@@ -63,17 +63,23 @@
return join "", @lines;
}
+sub test_docs {
+ my ($pods, $tests) = @_;
+return join "", map <<EOT, 0..$#$pods;
+$$tests[$_]: $$pods[$_]
+ pod2test $$pods[$_] $$tests[$_]
+
+EOT
+}
+
sub MY::postamble {
my @docs = <docs/*.pod>;
my @tests = @docs;
s/pod$/t/ for @tests;
- return copy_docs(@docs) . sprintf <<'EOT', "@tests";
-%%.t : %%.pod
- pod2test $< $@
-
-doc_test : %s
- $(FULLPERL) -Mblib -MTest::Harness -e 'runtests(@ARGV)' "@tests"
+ return copy_docs(@docs) . test_docs([EMAIL PROTECTED],[EMAIL PROTECTED])
. <<EOT;
+doc_test : @tests
+ \$(FULLPERL) -Mblib -MTest::Harness -e 'runtests([EMAIL PROTECTED])'
@tests
test :: doc_test