Changeset 21689 for Makefile.PL
- Timestamp:
- 08/01/08 14:59:56 (4 months ago)
- Files:
-
- 1 modified
-
Makefile.PL (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
Makefile.PL
r21686 r21689 19 19 my $setup_exe = File::Spec->catfile('.', "Setup$Config{_exe}"); 20 20 21 unlink $_ for qw(Setup.hi Setup.o); 22 unlink $setup_exe; 23 system($ghc, qw(--make -O0), -o => $setup_exe, 'Setup.lhs'); 21 rebuild_setup(); 24 22 my $app_dir = `$setup_exe -d`; 25 23 chomp $app_dir; … … 37 35 print "[Automatic Installation]\n"; 38 36 39 bootstrap_with(Cabal => qr/1\.4\./, '1.4.0'); 40 bootstrap_with(HTTP => qr/300[01]\./, '3000.0'); 41 bootstrap_with(zlib => qr/0\.(?:[4-9]|[1-9]\d)\./, '0.4'); 42 bootstrap_with('cabal-install' => qr/0\.(?:[5-9]|[1-9]\d)\./, '0.5'); 37 my $rebuilt; 38 $rebuilt ||= bootstrap_with(Cabal => qr/1\.4\./, '1.4.0'); 39 $rebuilt ||= bootstrap_with(HTTP => qr/300[01]\./, '3000.0'); 40 $rebuilt ||= bootstrap_with(zlib => qr/0\.(?:[4-9]|[1-9]\d)\./, '0.4'); 41 $rebuilt ||= bootstrap_with('cabal-install' => qr/0\.(?:[5-9]|[1-9]\d)\./, '0.5'); 42 43 if ($rebuilt) { 44 rebuild_setup(); 45 } 43 46 44 47 print "[Pugs Dependencies]\n"; … … 196 199 197 200 chdir $FindBin::RealBin; 201 return 1; 198 202 } 199 203 … … 214 218 return join("\n", @cmds); 215 219 } 220 221 sub rebuild_setup { 222 unlink $_ for qw(Setup.hi Setup.o); 223 unlink $setup_exe; 224 system($ghc, qw(--make -O0), -o => $setup_exe, 'Setup.lhs'); 225 }
