[GRASS-dev] Re: [GRASS GIS] #1235: ERROR: G_getenv(): Variable LOCATION_NAME not set

GRASS GIS trac at osgeo.org
Wed Dec 8 23:45:54 EST 2010


#1235: ERROR: G_getenv(): Variable LOCATION_NAME not set
-------------------------+--------------------------------------------------
 Reporter:  apgis        |       Owner:  grass-dev@…              
     Type:  defect       |      Status:  new                      
 Priority:  normal       |   Milestone:  6.4.1                    
Component:  LibGIS       |     Version:  unspecified              
 Keywords:               |    Platform:  MSWindows XP             
      Cpu:  Unspecified  |  
-------------------------+--------------------------------------------------
Changes (by hamish):

  * platform:  Unspecified => MSWindows XP
  * component:  Default => LibGIS


Comment:

 AFAIK, LD_LIBRARY_PATH is not used on non-UNIX systems. Are you using
 Cygwin?

 Is this your own code or part of the shipping binaries?

 G_getenv() actually gets GIS variables from the $HOME/.grassrc6 file.
 LD_LIBRARY_PATH is a UNIX environment variable. FWIW, environment
 variables are read by libc's getenv(). Yes, the names are similar, but the
 functionality is quite different, sorry for the confusion. See the
 "variables" grass help page for details on both.

 Typically LOCATION_NAME not being set is because it is missing from
 $HOME/.grassrc6. Probably the easiet way to fix that is to start grass
 from the command line with the full path to the mapset, e.g.
   grass64 c:\grassdata\spearfish60\user

 from then on you should be ok.


 Hamish

-- 
Ticket URL: <https://trac.osgeo.org/grass/ticket/1235#comment:1>
GRASS GIS <http://grass.osgeo.org>



More information about the grass-dev mailing list