Ignore:
Timestamp:
06/21/09 03:47:53 (3 years ago)
Author:
waxhead
Message:

Fixed path issue in NYTPROF environment variable for win32 systems for the initial profiling. Fix for generating report still to be done.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Padre-Plugin-NYTProf/lib/Padre/Plugin/NYTProf/ProfilingTask.pm

    r5405 r5428  
    4545     
    4646    my $nytprof_env_vars = ""; 
     47    my $drive = ""; 
    4748    foreach my $env( keys( %{ $self->{nytprof_envars} }  ) ) { 
     49        # we can't use the full file path because the colon 
     50        # in the file path is the same delimiter NYTProf uses 
     51        # for NYTPROF environment variable. 
     52        # not the best but: 
     53        print "env: $env\n"; 
     54        if( ($env eq 'file') && ($^O eq 'MSWin32') ) { 
     55            print "setting drive for win32\n"; 
     56            $self->{nytprof_envars}->{$env} =~ /(\w\:)(.*$)/; 
     57            $drive = $1; 
     58            $self->{nytprof_envars}->{$env} = $2; 
     59        } 
    4860        $nytprof_env_vars .= "$env=" . $self->{nytprof_envars}->{$env} . ":"; 
    4961    } 
     
    6072    if( $^O eq "MSWin32" ) { 
    6173        print "Running on windows\n"; 
    62         $cmd = "set NYTPROF=$nytprof_env_vars && "; 
    63          
     74        $cmd = "$drive && set NYTPROF=$nytprof_env_vars && "; 
    6475    } 
    6576    elsif( $^O eq "darwin" ) { 
Note: See TracChangeset for help on using the changeset viewer.