Show
Ignore:
Timestamp:
19.03.2010 22:20:20 (10 years ago)
Author:
ak19
Message:

Dr Bainbridge modified the section setting Perl to bring it in line with what setup.bash does when Perl 5.8.9 has been downloaded and extracted into the bin linux folder. Need perlpath property in gsdlsite.cfg set, for the Remote Greenstone to do the same, though.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • main/trunk/greenstone2/cgi-bin/gsdlCGI.pm

    r20573 r21804  
    454454    # prepended to PATH only if the same perl bin dir path is not already on PATH env 
    455455    my $perl_bin_dir = $self->get_perl_path($optional); 
    456     if(defined $perl_bin_dir)  
     456    if(defined $perl_bin_dir) 
    457457    { 
    458     &util::envvar_prepend("PATH", $perl_bin_dir);    
     458    &util::envvar_prepend("PATH", $perl_bin_dir); 
     459 
     460    #my ($perl_home) = ($perl_bin_dir =~ m/(.*)[\\|\/]bin[\\|\/]?$/); 
     461    my ($tailname,$perl_home) = File::Basename::fileparse($perl_bin_dir, "\\.(?:[^\\.]+?)\$"); 
     462    $ENV{'PERL5LIB'} = &util::filename_cat($perl_home, "lib"); 
     463 
     464    if($gsdlos eq "darwin") { 
     465        &util::envvar_prepend("DYLD_LIBRARY_PATH", &util::filename_cat($perl_home,"5.8.9","darwin-thread-multi-2level","CORE")); 
     466    } elsif($gsdlos eq "linux") { 
     467        &util::envvar_prepend("LD_LIBRARY_PATH", &util::filename_cat($perl_home,"5.8.9","i686-linux-thread-multi","CORE")); 
     468    } 
    459469    } 
    460470    elsif ($gsdlos eq "windows")