[winGRASS] Running batch queries in grass on windows from inside another application
Buchan Milne
bgmilne at cae.co.za
Thu May 22 06:30:41 EDT 2003
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
My current project involves integrating some GIS functionality into a
simulation that can only run on Windows, preferably using grass. It also
involves pulling the coordinates to be queried from another system.
At present, I have the coordinate queries and grass queries working
under linux, however, I can't seem to get this to work on Windows with
grass/cygwin, and it seems to be related to environment variables.
I am developing my "glue code" with wxWindows, so I have code that is
almost identical under Windows and Linux. Under linux, I can just build
up a grass query (utilizing batch-grass to pass arguments that I want to
become the environment variables), and execute it, and can get the
results back in the form I want, and do the calculations necessary to
get the data in the form the simulation needs.
However, if I run the same program under Windows/cygwin, using a
shell->batch ported version of batch-grass, variables set in the command
prompt are not propagated to the grass programs (such as r.what).
Exporting varaibles in a cygwin bash shell also does not seem to affect
the grass query run from inside my application (which is started from
inside a cygwin shell). Launching a shell (ie sh -c 'batchgrass db
location query') also does not seem to work.
So, does anyone know how I can achieve this on Windows? I am kind of
missing a grass SDK ...
Regards,
Buchan
- --
|--------------Another happy Mandrake Club member--------------|
Buchan Milne Mechanical Engineer, Network Manager
Cellphone * Work +27 82 472 2231 * +27 21 8828820x202
Stellenbosch Automotive Engineering http://www.cae.co.za
GPG Key http://ranger.dnsalias.com/bgmilne.asc
1024D/60D204A7 2919 E232 5610 A038 87B1 72D6 AC92 BA50 60D2 04A7
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.2 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQE+zKbRrJK6UGDSBKcRAm7/AJ4jefKd/oNjsmeVqG1t0G7j5goPfACgmiDJ
W6550CUTPQYodQd5ggQl6e8=
=Cb8o
-----END PGP SIGNATURE-----
******************************************************************
Please click on http://www.cae.co.za/disclaimer.htm to read our
e-mail disclaimer.
******************************************************************
More information about the grass-windows
mailing list