1 use ExtUtils::MakeMaker;
7 'gutsy' => '--bindmounts /media/hosk_1'
12 if ($^O eq 'linux' && !defined $opt_d)
14 $opt_d = `lsb_release -c`;
15 $opt_d =~ s/^.*?(\w+)\s*$/$1/o;
18 @theselibs = (grep {-f } glob("lib/Font/TTF/*"), "lib/Font/TTF.pm");
20 # incantation to enable MY::pm_to_blib later on
23 push(@ExtUtils::MakeMaker::Overridable, qw(pm_to_blib));
24 @extras = ('dist' => { 'TO_UNIX' => 'perl -Mtounix -e "tounix(\"$(DISTVNAME)\")"' });
29 VERSION_FROM => 'lib/Font/TTF.pm',
31 # HTMLLIBPODS => {map {my $t = $_; $t=~s/\..*?$/.html/o; $t='blib/Html/'.$t; $_ => $t;} @theselibs},
32 # HTMLSCRIPTPODS => {map {my $t=$_; $t=~s/\..*?$/.html/o; $t='blib/Html/'.$t; $_ => $t;} @scripts},
33 AUTHOR => "martin_hosken\@sil.org",
34 ABSTRACT => "TTF font support for Perl",
38 WriteMakefile(%makeinfo);
40 if ($^O eq 'MSWin32') {
41 # incantation to solve the problem of everyone's $Config{make} being 'nmake'
42 # when we want 'pmake'. And $Config{} is read only.
43 # actually, this is just a copy of the code from ExtUtiles::MM_Win32 tidied
44 # up (to expose tabs) and the dependency on Config removed
48 my($autodir) = $self->catdir('$(INST_LIB)','auto');
51 pm_to_blib: \$(TO_INST_PM)
52 \t$self->{NOECHO}\$(PERL) \"-I\$(INST_ARCHLINE)\" \"-I\$(INST_LIB)\" \\
53 \t\"-I\$(PERL_ARCHLIB)\" \"-I\$(PERL_LIB)\" -MExtUtils::Install \\
54 \t-e \"pm_to_blib({ qw[\$(PM_TO_BLIB)] }, '$autodir')
55 \t$self->{NOECHO}\$(TOUCH) \$@
61 elsif ($^O eq 'linux')
68 my ($package) = lc($self->{'NAME'});
69 my ($pversion) = $self->{'VERSION'};
70 my ($svn) = `svnversion`;
71 my ($sign) = '--auto-debsign' if ($opt_r);
74 $svn =~ s/[0-9]*://og;
77 $package = "lib${package}-perl";
78 $pversion .= "+$svn" unless ($opt_r);
79 $fpackage = "$package-$pversion";
83 rm -fr $self->{'DISTVNAME'}
85 tar xvzf $self->{'DISTVNAME'}.tar.gz
86 mv $self->{'DISTVNAME'} $fpackage
87 tar cfz "${package}_$pversion.orig.tar.gz" $fpackage
88 cp -a debian $fpackage
89 cd $fpackage && find . -name .svn | xargs rm -rf
91 # make deb builds an interim deb from svn source for release
95 foreach $d (split(' ', $opt_d))
99 dch -D $d -v $pversion-$opt_v -m -b -c $fpackage/debian/changelog "Auto build from perl for $d"
100 cd $fpackage && pdebuild --buildresult ../dists/$d -- --basetgz /var/cache/pbuilder/base-$d.tgz $pbuilderopts{$d}