#! /opt/perlbrew/perls/perl-5.14.2/bin/perl
sub
magic_number_matches {
return
0
unless
-e
'_build/magicnum'
;
my
$FH
;
open
$FH
,
'<'
,
'_build/magicnum'
or
return
0;
my
$filenum
= <
$FH
>;
close
$FH
;
return
$filenum
== 918950;
}
my
$progname
;
my
$orig_dir
;
BEGIN {
$^W = 1;
$progname
= basename($0);
$orig_dir
= Cwd::cwd();
my
$base_dir
=
'/home/sam/dev/Text-Sequence'
;
if
(!magic_number_matches()) {
unless
(
chdir
(
$base_dir
)) {
die
(
"Couldn't chdir($base_dir), aborting\n"
);
}
unless
(magic_number_matches()) {
die
(
"Configuration seems to be out of date, please re-run 'perl Build.PL' again.\n"
);
}
}
unshift
@INC
,
(
);
}
close
(
*DATA
)
unless
eof
(
*DATA
);
Module::Build->VERSION(
q{0.42}
);
$^X = Module::Build->find_perl_interpreter;
if
(-e
'Build.PL'
and not Module::Build->up_to_date(
'Build.PL'
,
$progname
)) {
warn
"Warning: Build.PL has been altered. You may need to run 'perl Build.PL' again.\n"
;
}
my
$build
= Module::Build->resume (
properties
=> {
config_dir
=>
'_build'
,
orig_dir
=>
$orig_dir
,
},
);
$build
->dispatch;