Changeset 28575


Ignore:
Timestamp:
10/31/13 20:21:30 (7 years ago)
Author:
ak19
Message:

Removing the unused env_var variable from the set_gnomelib_env function introduced yesterday and commented out references to this variable in this function. Instead, doc.pm has a comment on how to set and use this env variable (if it's ever needed) before launching any binary dependent on it.

Location:
main/trunk/greenstone2/perllib
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • main/trunk/greenstone2/perllib/doc.pm

    r28560 r28575  
    376376    &util::set_gnomelib_env(); # gnomelib_env (particularly lib/libiconv2.dylib) required to run the hashfile executable on Mac Lions
    377377    # The subroutine will set the gnomelib env once for each subshell launched, by first testing if GEXTGNOME is not already set
     378
     379    # A different way to set the gnomelib env would be to do it more locally: exporting the necessary vars
     380    # (specifically DYLD/LD_LIB_PATH) for gnome_lib as part of the command executed.
     381    # E.g. $result=`export LD_LIBRARY_PATH=../ext/gnome-lib/darwin/lib; hashfile...`
    378382
    379383    my $result = "NULL";
  • main/trunk/greenstone2/perllib/util.pm

    r28560 r28575  
    16561656    # Though this is only needed for darwin Lion at this point (and android, though that is untested)
    16571657
    1658     my $env_vars="";
    1659 
    16601658    my $libext = "so";
    16611659    if ($ENV{'GSDLOS'} =~ m/^windows$/i) {
    1662     #return $env_vars;
    16631660    return;
    16641661    } elsif ($ENV{'GSDLOS'} =~ m/^darwin$/i) {
     
    16891686        if(-d $gnomelib_bin) { # no bin subfolder in GS binary's cutdown gnome-lib-minimal folder
    16901687        &util::envvar_prepend("PATH", $gnomelib_bin);
    1691         #$env_vars = "export PATH=".$ENV{'PATH'}.";";
    16921688        }
    16931689
     
    16971693        if($ENV{'GSDLOS'} eq "linux") {
    16981694        &util::envvar_prepend("LD_LIBRARY_PATH", $gextlib);
    1699         #$env_vars .= "export LD_LIBRARY_PATH=".$ENV{'LD_LIBRARY_PATH'};
    17001695        }
    17011696        elsif ($ENV{'GSDLOS'} eq "darwin") {
    17021697        #&util::envvar_prepend("DYLD_LIBRARY_PATH", $gextlib);
    17031698        &util::envvar_prepend("DYLD_FALLBACK_LIBRARY_PATH", $gextlib);
    1704         #$env_vars .= "export DYLD_FALLBACK_LIBRARY_PATH=".$ENV{'DYLD_FALLBACK_LIBRARY_PATH'};
    17051699        }
    17061700    }
     
    17181712    # if no GEXTGNOME, maybe users didn't need gnome-lib to run gnomelib/libiconv dependent binaries like hashfile, suffix, wget
    17191713    # (wvware is launched in a gnomelib env from its own script, but could possibly go through this script in future)
    1720 
    1721     #return $env_vars; #print STDOUT $env_vars;
    17221714}
    17231715
Note: See TracChangeset for help on using the changeset viewer.