[plt-scheme] Accessing modules in a stand-alone executable
At Sun, 11 May 2003 13:25:26 -0700 (PDT), Ulf Leopold wrote:
> However, once a module has been compiled and linked
> with the application it can no longer be referred to
> the following way:
>
> (require (lib "mymodule.scm" "mycollection"))
>
> Instead it must be referred to using its identifier:
>
> (require mymodule)
>
> [...]
>
> I have been thinking in terms of modifying the module
> name resolver, but I'm not sure how to access the
> module identifier (i.e. mymodule) so that it can be
> returned from the module name resolver.
The resolver doesn't return a module. It only returns a symbolic name.
For example, it resolves `(lib "mymodule.scm" "mycollect")' to just
`mymodule'.
This is fairly easy if you know all of the `lib' paths that you want to
resolve. In fact, this is how mzc's --exe/--gui-exe works (after
embedding a number of modules in .zo form).
Matthew