[LON-CAPA-cvs] cvs: modules /matthew/systemperl prepare_systemperl.pl

matthew lon-capa-cvs@mail.lon-capa.org
Mon, 01 Nov 2004 16:18:30 -0000


matthew		Mon Nov  1 11:18:30 2004 EDT

  Modified files:              
    /modules/matthew/systemperl	prepare_systemperl.pl 
  Log:
  Updated to include WeakRef.
  
  
Index: modules/matthew/systemperl/prepare_systemperl.pl
diff -u modules/matthew/systemperl/prepare_systemperl.pl:1.8 modules/matthew/systemperl/prepare_systemperl.pl:1.9
--- modules/matthew/systemperl/prepare_systemperl.pl:1.8	Mon Jul 19 14:12:07 2004
+++ modules/matthew/systemperl/prepare_systemperl.pl	Mon Nov  1 11:18:29 2004
@@ -1,6 +1,6 @@
 #!/usr/bin/perl -w 
 #
-# $Id: prepare_systemperl.pl,v 1.8 2004/07/19 18:12:07 matthew Exp $
+# $Id: prepare_systemperl.pl,v 1.9 2004/11/01 16:18:29 matthew Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -66,7 +66,7 @@
 }
 
 
-my $basedir = "/root/systemperl/systemperl-3.11-rh7";
+my $basedir = "/root/systemperl/systemperl-3.14-rh7";
 my $builddir = $basedir."/modules";
 my $targetdir = $basedir."/root/usr";
 
@@ -98,8 +98,7 @@
 my $default_sysperl_install = 
     "perl ./Makefile.PL PREFIX=$targetdir < /dev/null; make; make install;";
 # No comment ...
-my $NetSSLeay_install = "perl ./Makefile.PL -- PREFIX=$targetdir; make; make ins
-tall;";
+my $NetSSLeay_install = "perl ./Makefile.PL -- PREFIX=$targetdir; make; make install;";
 
 my @Modules = ({ src => "Algorithm::Diff",
 		 dirname=> "Algorithm-Diff-*",
@@ -193,7 +192,7 @@
 		 compile=>$sysperl_install },
                # String::Similarity 1.0 does not work w/ perl 5.6
                # 
-               { extract => 'String-Similarity-0.02.tar'
+               { extract => 'String-Similarity-0.02.tar',
 		 src=>"String::Similarity",
                  dirname=>"String-Similarity-*",
                  compile=>$sysperl_install },
@@ -221,7 +220,9 @@
                { src=>"MIME::Types",
 	         dirname=>"MIME-Types-*",
                  compile=>$sysperl_install },
-               
+               { src=>"WeakRef",
+		 dirname=>"WeakRef*",
+		 compile=>$sysperl_install },
 	       );
 
 my @Libraries = (
@@ -242,7 +243,7 @@
 	    # (experimental code)
 	    # Extract locally instead of downloading
 	    system('cd '.$builddir.';'.
-		   'tar xf '.$basedir.'/'.$modinf->{'extract'}.';'.
+		   'tar xf '.$basedir.'/'.$modinfo->{'extract'}.';'.
 		   'cd '.$basedir);
 	    next;
 	}
@@ -294,5 +295,16 @@
 	    $modinfo->{'compile'};
 	print $compile_commands.$/;
     }
+    foreach my $library (@Libraries) {
+	next if ($library->{'src'} !~ /$printcmds/);
+	my $command;
+	if (exists($library->{'src'})) {
+	    $command .= 'cd '.$builddir.'/;'.
+		'tar zxf '.$library->{'src'}.';';
+	}
+	$command .= 'cd '.$builddir.'/'.$library->{'dirname'}.';'.
+	    $library->{'compile'};
+	print $command.$/;
+    }
 }