This is the mail archive of the
guile@sourceware.cygnus.com
mailing list for the Guile project.
Defining modules
Steven Greenberg writes:
> Hi again, I have another question. Sorry if this is another RTFM,
> but I looked and didn't see it anywhere. I'm trying to define a
> module. I place the following define-module at the top of the file
>
> (define-module (rdf rdf-lib))
>
> and place the file into directory /usr/local/share/guile/1.3.4/rdf.
> The problem is that when I call (use-modules (rdf rdf-lib)) it
> returns without complaint but dosen't seem to be loading the module.
> I can't get to any of the forms or variables.
>
> Any assistance would be greatly appreciated.
assuming "/usr/local/share/guile/1.3.4" is an element of `%load-path',
the problem may lie in a lack of export for the definitions from that
module. in module `(rdf rdf-lib)' try doing either:
(define-public my-var ...)
or
(define my-var ...)
(export my-var)
there are other tricky ways to do the same job, but they are confusing
and may cause ulcers... :->
thi