[GRASS-dev] Error while compiling i.pr Windows GRASS6.4

Glynn Clements glynn at gclements.plus.com
Mon Dec 7 10:56:43 EST 2009


António Rocha wrote:

> Just one question: during compilation i got these errors: ERROR: 
> G_getenv(): Variable LOCATION_NAME not set
> Is this associated with manual html page that is created with the 
> compilation?

Yes.

The process for generating HTML pages involves running the module with
the --html-description flag. Running any GRASS module requires a
minimal GRASS "session" to be established, which essentially means
that $GISRC must point to a file containing settings for the GISDBASE,
LOCATION_NAME and MAPSET variables

In the case where the module is being run with the --html-description
flag (or --help, etc), the actual value don't matter, but the
variables must be set.

Running make with e.g.:

	GISRC=$HOME/.grassrc6 make ...

should suffice.

In GRASS 7.0, the demolocation directory (which is used to provide a
minimal GRASS session for the normal build process) is installed, so
the rules to build HTML files should work even when building add-on
modules, but this isn't the case for 6.x.

[Actually, most of the problems relating to building add-ons should be
fixed in 7.0, but the existing add-ons are written for 6.x.]

-- 
Glynn Clements <glynn at gclements.plus.com>


More information about the grass-dev mailing list