[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.22, Wed May 4 21:42:50 2005 UTC revision 1.23, Fri May 6 22:03:03 2005 UTC
# Line 179  Line 179 
179    
180      push(@$Env, ["RTROOT", $ENV{FIG_HOME}, 0]);      push(@$Env, ["RTROOT", $ENV{FIG_HOME}, 0]);
181      push(@$Env, ["RTDIST", "\$RTROOT/dist", 0]);      push(@$Env, ["RTDIST", "\$RTROOT/dist", 0]);
182        push(@$Env, ["RTSITECONFIGDIR", "\$RTROOT/config", 0]);
183      push(@$Env, ["RTARCH", $ENV{FIGCONFIG_ENV}, 0]);      push(@$Env, ["RTARCH", $ENV{FIGCONFIG_ENV}, 0]);
184      push(@$Env, ["RTCURRENT", "`cat \$RTROOT/CURRENT_RELEASE`", 0]);      push(@$Env, ["RTCURRENT", "`cat \$RTROOT/CURRENT_RELEASE`", 0]);
185      push(@$Env, ["FIG_HOME", $ENV{FIG_HOME}, 0]);      push(@$Env, ["FIG_HOME", $ENV{FIG_HOME}, 0]);
# Line 201  Line 202 
202    
203      push(@$Env, ["LD_LIBRARY_PATH", "${env_lib}", 1]);      push(@$Env, ["LD_LIBRARY_PATH", "${env_lib}", 1]);
204    
205      my @perllib = grep({ $_ ne "." } @INC, "$fig_disk/config", $release_lib,      my @perllib = grep({ $_ ne "." } @INC,
206                        "$release_lib/FigKernelPackages");                         $release_lib,
207                           "$release_lib/FigKernelPackages",
208                           "$fig_disk/config");
209    
210      push(@$Env, ["PERL5LIB", join(":", @perllib), 1]);      push(@$Env, ["PERL5LIB", join(":", @perllib), 1]);
211  }  }
# Line 227  Line 230 
230      chomp $py_version;      chomp $py_version;
231      print "Python version $py_version\n";      print "Python version $py_version\n";
232    
233      $OtherConfig->{python_site_path} = "$ENV{FIGCONFIG_ENV_DIR}/lib/python$py_version/site-packages";      #
234        # Python figures this out for us.
235        #$OtherConfig->{python_site_path} = "$ENV{FIGCONFIG_ENV_DIR}/lib/python$py_version/site-packages";
236    
237      my @path = ();      my @path = ();
238      push(@path, $OtherConfig->{python_site_path});      #push(@path, $OtherConfig->{python_site_path});
239      push(@path, "$release_lib");      push(@path, "$release_lib");
240      push(@path, "$fig_disk/config");      push(@path, "$fig_disk/config");
241      push(@$Env, ["PYTHONPATH", join(":", @path), 1]);      push(@$Env, ["PYTHONPATH", join(":", @path), 1]);
# Line 594  Line 599 
599      # Append the perl path to the environment, for use later with CallPerl.      # Append the perl path to the environment, for use later with CallPerl.
600      #      #
601    
602      my $perlpath = join(":", @INC, "$fig_disk/config", $release_lib, "$release_lib/FigKernelPackages");      my $perlpath = join(":", @INC, $release_lib, "$release_lib/FigKernelPackages", "$fig_disk/config");
603      print $fh <<END;      print $fh <<END;
604  if os.getenv("PERL5LIB", "") != "":  if os.getenv("PERL5LIB", "") != "":
605      _delim = ":"      _delim = ":"
# Line 617  Line 622 
622      print $fh "#### END tool_hdr_py ####\n\n"      print $fh "#### END tool_hdr_py ####\n\n"
623  }  }
624    
625    sub write_rtconfig
626    {
627        my($fh) = @_;
628    
629        my $python = find_python();
630        my $perl = find_perl();
631    
632        print $fh "RTPYTHON=$python\n";
633        print $fh "RTPERL=$perl\n";
634        print $fh "RTPYTHONPATH=$OtherConfig->{pythonpath}\n";
635    
636        my $perlpath = join(":", @INC, "$fig_disk/config");
637    
638        print $fh "RTPERL5LIB=$perlpath\n";
639    
640        print $fh "RTPYTHONIMPORTS=FIG_Config\n";
641        print $fh "RTPERLIMPORTS=FIG_Config\n";
642    
643    }
644    
645  setup_directories("$fig_disk/bin",  setup_directories("$fig_disk/bin",
646                    "$fig_disk/config");                    "$fig_disk/config");
647    
# Line 668  Line 693 
693  write_tool_hdr_python(\*FH);  write_tool_hdr_python(\*FH);
694  close(FH);  close(FH);
695    
696    open(FH, ">$fig_disk/config/RTConfig") or die "Cannot write $fig_disk/config/RTConfig: $!";
697    write_rtconfig(\*FH);
698    close(FH);
699    
700  unshift(@INC, "$ENV{FIGCONFIG_RELEASE_DIR}");  unshift(@INC, "$ENV{FIGCONFIG_RELEASE_DIR}");
701    
702  require FigCommon::SwitchRelease;  require FigCommon::SwitchRelease;

Legend:
Removed from v.1.22  
changed lines
  Added in v.1.23

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3