Next: main shell-process, Up: Generated main [Contents][Index]
When the main-type is specified to be guile,
a main() procedure is generated that calls gh_enter(), providing
it with a generated inner_main() to invoke. If you must perform
certain tasks before calling gh_enter(), you may specify such code
in the value for the
before-guile-boot attribute.
The inner_main() procedure itself will process the command line
arguments (by calling optionProcess(),
see libopts-optionProcess), and then either invoke the code
specified with the
guile-main attribute, or else export the parsed options to Guile
symbols and invoke the scm_shell() function from the Guile library.
This latter will render the program nearly identical to the stock
guile(1) program.