File: Makefile.PL

package info (click to toggle)
libapache-filter-perl 1.019-1
  • links: PTS
  • area: main
  • in suites: woody
  • size: 224 kB
  • ctags: 65
  • sloc: perl: 888; makefile: 36
file content (91 lines) | stat: -rw-r--r-- 2,196 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
use strict;
use ExtUtils::MakeMaker;
use lib 't/lib';  # distributed here until changes are incorporated into the real version
use Apache::test qw(have_httpd);

my %params = Apache::test->get_test_params();
chomp (my $cwd = `pwd`);
Apache::test->write_httpd_conf
    (%params,
     include => do {local $/; <DATA>});
*MY::test = sub { Apache::test->MM_test(%params) } if have_httpd();

my $module = 'Apache::Filter';
my ($name, $dir);
($name = $module) =~ s/.*::(\w+)/$1.pm/;
($dir = $module) =~ s/::/-/g;

WriteMakefile
  (
   'NAME'	=> $module,
   'VERSION_FROM' => $name, # finds $VERSION
   'dist' => { COMPRESS=>"gzip", 
	       SUFFIX=>"gz", 
               PREOP=>('rm -f README; '.
                       "pod2text -80 < $name > README; ".
                       "cp -f README $dir-\$(VERSION); "
                      ),
             },
   'clean' => {FILES => "t/httpd t/httpd.conf t/error_log"},
   'PREREQ_PM' => {
                   have_httpd() ? ('mod_perl' => '1.24_01') : (),
		  },
  );

##################################################################
__DATA__

PerlModule Apache::Filter
PerlModule Apache::RegistryFilter
PerlModule Apache::UC
PerlModule Apache::Reverse
PerlModule Apache::CacheTest
PerlModule Apache::FHandle
PerlModule Apache::ChangeHeader

# Default - this includes directories too
SetHandler perl-script
PerlHandler Apache::UC Apache::Reverse

PerlSetVar Filter on

<FilesMatch "\.ur$">
 SetHandler perl-script
 PerlHandler Apache::UC Apache::Reverse
</FilesMatch>

<FilesMatch "\.r$">
 SetHandler perl-script
 PerlHandler Apache::Reverse
</FilesMatch>

<FilesMatch "\.p$">
 SetHandler perl-script
 PerlHandler Apache::UC Apache::CacheTest
</FilesMatch>

<FilesMatch "\.fh$">
 SetHandler perl-script
 PerlHandler Apache::FHandle
</FilesMatch>

<FilesMatch "\.cp$">
 SetHandler perl-script
 PerlHandler Apache::RegistryFilter Apache::Compress
</FilesMatch>

<FilesMatch "\.h$">
 SetHandler perl-script
 PerlHandler Apache::ChangeHeader
</FilesMatch>

<FilesMatch "\.pl$">
 SetHandler perl-script
 PerlHandler Apache::RegistryFilter Apache::UC
</FilesMatch>

<FilesMatch "\.plr$">
 SetHandler perl-script
 PerlHandler Apache::RegistryFilter
</FilesMatch>