[Bio] / FigCommon / bootstrap.pl Repository:
ViewVC logotype

Diff of /FigCommon/bootstrap.pl

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.25, Tue May 17 17:36:05 2005 UTC revision 1.26, Mon May 23 14:48:05 2005 UTC
# Line 200  Line 200 
200    
201      push(@$Env, ["PATH", join(":", @path), 1]);      push(@$Env, ["PATH", join(":", @path), 1]);
202    
203      push(@$Env, ["LD_LIBRARY_PATH", "${env_lib}", 1]);      #
204        # Compute  LD_LIBRARY_PATH.
205        #
206        # Some packages, like mysql, place their shared libs in subdirectories
207        # of the libdir.
208        #
209    
210        my @ld_path = ($env_lib);
211    
212        my $dh;
213        if (!opendir($dh, $env_lib))
214        {
215            warn "Could not opendir $env_lib: $!";
216        }
217    
218        while ($_ = readdir($dh))
219        {
220            next if /^\./;
221    
222            my $path = "$env_lib/$_";
223            next unless -d $path;
224    
225            #
226            # See if there are any .so's in here.
227            #
228    
229            my @solist = <$path/*.so*>;
230            if (@solist > 0)
231            {
232                push(@ld_path, $path);
233            }
234        }
235        closedir($dh);
236    
237        #
238        # And if perl is dynamically linked, we need to add the perl core directory
239        # to the path too.
240        #
241    
242        my @coredir = <$env_lib/perl5/*/*/CORE>;
243        if (@coredir)
244        {
245            if ( -f "$coredir[0]/libperl.so" )
246            {
247                print "Found libperl in $coredir[0]\n";
248                push(@ld_path, $coredir[0]);
249            }
250        }
251    
252        my $ld_path = join(":", @ld_path);
253        $OtherConfig->{ld_library_path} = $ld_path;
254    
255        push(@$Env, ["LD_LIBRARY_PATH", $ld_path, 1]);
256    
257      my @perllib = grep({ $_ ne "." } @INC,      my @perllib = grep({ $_ ne "." } @INC,
258                         $release_lib,                         $release_lib,
# Line 649  Line 701 
701      print $fh "RTPERLIMPORTS=FIG_Config\n";      print $fh "RTPERLIMPORTS=FIG_Config\n";
702      print $fh "RTSETENV=BLASTMAT=$fig_disk/BLASTMAT\n";      print $fh "RTSETENV=BLASTMAT=$fig_disk/BLASTMAT\n";
703      print $fh "RTSETENV=FIG_HOME=$fig_disk\n";      print $fh "RTSETENV=FIG_HOME=$fig_disk\n";
704        print $fh "#RTLD_LDPATH=$Otherconfig->{ld_library_path}\n";
705  }  }
706    
707  setup_directories("$fig_disk/bin",  setup_directories("$fig_disk/bin",

Legend:
Removed from v.1.25  
changed lines
  Added in v.1.26

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3