File: Makefile.PL

package info (click to toggle)
libcgi-expand-perl 2.05-7
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 136 kB
  • sloc: perl: 457; makefile: 2
file content (38 lines) | stat: -rw-r--r-- 974 bytes parent folder | download | duplicates (4)
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
use ExtUtils::MakeMaker;
# See lib/ExtUtils/MakeMaker.pm for details of how to influence
# the contents of the Makefile that is written.

BEGIN { 
    *MY::postamble = \&postamble if $^O =~ /^linux/i;
}

WriteMakefile(
    'NAME'		=> 'CGI::Expand',
    'VERSION_FROM'	=> 'Expand.pm', # finds $VERSION
    'PREREQ_PM'		=> {
		'Test::Exception' => 0,
		'Test::More' => 0,
	}, # e.g., Module::Name => 1.1
    LICENSE => 'perl',

    ($] >= 5.005 ?    ## Add these new keywords supported since 5.005
      (ABSTRACT_FROM => 'Expand.pm', # retrieve abstract from module
       AUTHOR     => 'Brad Bowman <cgi-expand@bereft.net>') : ()),

);

# Appended to the end of the Makefile for linux (debian) only
sub postamble {
    return <<'POSTAMBLE';
DEBVNAME = $(shell $(PERLRUN) -le 'print lc(shift)' $(DISTVNAME))
deb : debdir
	-cd $(DEBVNAME) && debuild -us -uc

debdir : distdir
	$(RM_RF) $(DEBVNAME)
	$(MV) $(DISTVNAME) $(DEBVNAME)
	$(CP) -r debian $(DEBVNAME)

POSTAMBLE
}