[GRASS-user] ps.map: Error Using Fill Patterns

Hamish hamish_b at yahoo.com
Sat Feb 27 00:15:03 EST 2010


Rich Shepard wrote:
> Here's the error:
> 
> can't open eps file
> <$GISBASE/etc/paint/patterns/diag_up6.eps>
> 
>   But, from within grass64 I can successfully 'less
> $GISBASE/etc/paint/patterns/diag_up6.eps'


by the time it gets to that error message, the $GISBASE should have been
expanded to the full path, but for some reason it hasn't been. Shell
variables only work from the shell, so if you get ps.map instructions
from an input file you need the full path.

On the other hand if you do:

ps.map out=test.ps << EOF
...

  pattern $GISBASE/etc/paint/...
...
EOF

shell variables are ok & get expanded.


BUT, this is a PITA for version/machine portability of instruction files
so r_vareas.c scans the filename string for $GISBASE and expands it to
G_gisbase() if needed. For some reason in yours it gets past that
expansion somehow. I'm not sure why but the quick fix is to just spell
out the full path to the file and not use the variable.


Hamish



      


More information about the grass-user mailing list