File: Makefile.PL

package info (click to toggle)
libmail-imapclient-perl 2.2.9%2Bdeb-2
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 680 kB
  • ctags: 179
  • sloc: perl: 3,914; makefile: 56
file content (47 lines) | stat: -rwxr-xr-x 1,096 bytes parent folder | download | duplicates (2)
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
use ExtUtils::MakeMaker;
use Parse::RecDescent;
unlink './Thread.pm' if -f './Thread.pm';
sub MY::top_targets {
	package MY;

	my $inherit = shift->SUPER::top_targets(@_);
	my @inherit = split("\n",$inherit);
	for (@inherit) {
		if ( /^\s*all\s*:{1,2}/  ) {
			s/(all\s*:{1,2}\s*)/$1Thread\.pm /;
		}
	}
	return join("\n",@inherit);
}

sub MY::clean {
	package MY;

	my $inherit = shift->SUPER::clean(@_);
	return join("\n",$inherit,"	rm Thread.pm") ;
}

sub MY::postamble {
	my $string = 
		'@$(PERL) "-MParse::RecDescent" "-" ' .
		'"Thread.grammar" '. 
		'"Mail::IMAPClient::Thread"' ;
	return "Thread.pm: Thread.grammar\n\t$string\n\n";
}

# See lib/ExtUtils/MakeMaker.pm for details of how to influence
# the contents of the Makefile that is written.
#print "",MY->top_target;

WriteMakefile(
    'NAME'		=> 'Mail::IMAPClient::Thread',
    'VERSION_FROM'	=> '../IMAPClient.pm', 		
    'PREREQ_PM'		=> {"Parse::RecDescent" => 0 }, 
    'PM'		=> {
		'Thread.pm' => 
		'$(INST_LIBDIR)/Thread.pm' 
   	},
    'MAN3PODS' => {'Thread.pod' => 
	'$(INST_MAN3DIR)/Mail::IMAPClient::Thread.3pm'},
);