Hi Chris,

Christopher Baines <m...@cbaines.net> writes:

> I'm having some trouble with Guile module loading. I've got a
> (use-modules ...) call which results in some warnings, which seem to be
> actually more like errors, as the modules aren't  loaded.
>
> From loading one module, I get two errors in the form:
>
>   warning: failed to load '...':
>   Unbound variable: ...

When I search for "failed to load" in the guile-2.2 sources, the only
match is "WARNING: failed to load compiled file ...".  Was that the
actual message?

Exact output is generally more useful than approximate messages typed
from human memory.

> The modules and variables all exist, but as far as I understand Guile
> modules, they shouldn't be required for loading the module requested.

I'm sorry, but you haven't provided enough information to tell what the
problem is.  Can you provide the source code for a small self-contained
example, along with a list of commands needed to reproduce the problem?

> Any tips on debugging use-modules? Initially it would be good to work
> out what modules it's attempting to load.

Running Guile within 'strace' would show you what system calls are being
executed, including 'open' calls attempting to open files, whether the
attempts were successful, and what the error codes were on failures.
While Guile loads modules, it attempts to open *.scm and *.go files in
the directories of Guile's load path (%load-path).  You may find useful
clues there.

     Mark

Reply via email to