[Koha-cvs] CVS: koha koha.upgrade,1.1.2.11,1.1.2.12

Steve Tonnesen tonnesen at users.sourceforge.net
Thu Jul 11 20:43:53 CEST 2002


Update of /cvsroot/koha/koha
In directory usw-pr-cvs1:/tmp/cvs-serv7751

Modified Files:
      Tag: rel-1-2
	koha.upgrade 
Log Message:
Added module check to koha.upgrade and added HTML::Template and Digest::MD5 to
the list of required modules.


Index: koha.upgrade
===================================================================
RCS file: /cvsroot/koha/koha/koha.upgrade,v
retrieving revision 1.1.2.11
retrieving revision 1.1.2.12
diff -C2 -r1.1.2.11 -r1.1.2.12
*** koha.upgrade	9 Jul 2002 20:16:41 -0000	1.1.2.11
--- koha.upgrade	11 Jul 2002 18:43:51 -0000	1.1.2.12
***************
*** 102,105 ****
--- 102,162 ----
  };
  
+ 
+ 
+ #
+ # Test for Perl and Modules
+ #
+ print qq|
+ 
+ PERL & MODULES
+ ==============
+ 
+ |;
+ 
+ print "\nChecking perl modules ...\n";
+     unless (eval "require 5.004") {
+     die "Sorry, you need at least Perl 5.004\n";
+ }
+ 
+ my @missing = ();
+ unless (eval {require DBI})               { push @missing,"DBI" };
+ unless (eval {require Date::Manip})       { push @missing,"Date::Manip" };
+ unless (eval {require DBD::mysql})        { push @missing,"DBD::mysql" };
+ unless (eval {require Set::Scalar})       { push @missing,"Set::Scalar" };
+ unless (eval {require Digest::MD5})       { push @missing,"Digest::MD5" };
+ unless (eval {require HTML::Template})       { push @missing,"HTML::Template" };
+ #unless (eval {require Net::Z3950})        { 
+ #    print qq|
+ #
+ #The Net::Z3950 module is missing.  This module is necessary if you want to use
+ #Koha's Z39.50 client to download bibliographic records from other libraries.
+ #To install this module, you will need the yaz client installed from
+ #http://www.indexdata.dk/yaz/ and then you can install the perl module with the
+ #command:
+ #
+ #perl -MCPAN -e 'install Net::Z3950'
+ #
+ #Press the <ENTER> key to continue:
+ #|;
+ #    <STDIN>;
+ #}
+ 
+ #
+ # Print out a list of any missing modules
+ #
+ if (@missing > 0) {
+     print "\n\n";
+     print "You are missing some Perl modules which are required by Koha.\n";
+     print "Once these modules have been installed, rerun this installer.\n";
+     print "They can be installed by running (as root) the following:\n";
+     foreach my $module (@missing) {
+ 	print "   perl -MCPAN -e 'install \"$module\"'\n";
+ 	exit(1);
+     }} else{
+     print "All modules appear to be installed, continuing...\n";
+ };
+ 
+ 
+ 
  my $backupdir='/usr/local/koha/backups';
  print "Please specify a backup directory [$backupdir]: ";  





More information about the Koha-cvs mailing list