Glynn,
g.parser appears to be one of those programs not on the CMD/list
so it wasn't compiled on my system. When I compile, I get an
undefined symbol reference (setenv) in main.o
I have enclosed to error message.
Let me ask a few more questions.
As an example:
my_script map=f00
my_script will define all the required parameters for the parser
in the top portion (as in test.sh) similar to a C program.
my_script will have on the command line none, some, or all of
the required parameters. The parser will get the command line
parameters and ask for any missing parameters. Is this
correct?
The rest looks straight forward.
John
(attachments)
parser.txt (1.25 KB)
John Gillette wrote:
g.parser appears to be one of those programs not on the CMD/list
so it wasn't compiled on my system. When I compile, I get an
undefined symbol reference (setenv) in main.o
Sorry, setenv() is a BSD-ism. Try the attached patch.
Let me ask a few more questions.
As an example:
my_script map=f00
my_script will define all the required parameters for the parser
in the top portion (as in test.sh) similar to a C program.
my_script will have on the command line none, some, or all of
the required parameters. The parser will get the command line
parameters and ask for any missing parameters. Is this
correct?
g.parser is a basically just a wrapper around G_parser() etc, so it
should have identical behaviour.
If you run the script with no arguments, G_parser() should use an
interactive question-and-answer session to obtain the values. If you
provide any arguments, then no interaction is performed; if any
required options were omitted, an error message will be printed and
the g.parser will terminate without running the script.
--
Glynn Clements <glynn.clements@virgin.net>
(attachments)
g.parser-putenv.diff (961 Bytes)