chicken-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Chicken-users] csi and using modules in a different directory


From: arc
Subject: [Chicken-users] csi and using modules in a different directory
Date: Thu, 16 Feb 2017 22:08:10 +1300


Hi,

I'm a bit baffled by this behaviour.

I have a file called amodule.scm:

(module amodule (afunc)
 (import chicken scheme)
 (define (afunc x)
  (* x x)))


I've made an import library using csc -analyze-only -emit-import-library

doing (use amodule) when executing from the containing directory works as expected.

However, from outside, I execute csi -I ./lib

and then this happens:


#;1> (use amodule)
; loading /home/ajt/Projects/Scheme/chicken-include-path-investigation/lib/amodule.import.scm ...
; loading /usr/local/lib/chicken/8/chicken.import.so ...

Error: (require) cannot load extension: amodule

        Call history:

        <syntax>    (##core#undefined)
<syntax> (##sys#register-compiled-module (quote amodule) (list) (quote ((afunc . amodule#afunc))) (list) (lis...
        <syntax>    (quote amodule)
        <syntax>    (##core#quote amodule)
        <syntax>    (list)
        <syntax>    (quote ((afunc . amodule#afunc)))
        <syntax>    (##core#quote ((afunc . amodule#afunc)))
        <syntax>    (list)
        <syntax>    (list)
<eval> (##sys#register-compiled-module (quote amodule) (list) (quote ((afunc . amodule#afunc))) (list) (lis...
        <eval>      (list)
        <eval>      (list)
        <eval>      (list)
        <syntax>    (##core#undefined)
        <syntax>    (##core#undefined)
        <eval>      (##sys#require (quote amodule))       <--

the file looks to be loaded, but the module isn't accessed somehow.

I've tried using the absolute path and also setting LD_LIBRARY_PATH.

I've also tried loading the file with load-relative and ,l , and the behaviour is similar.

I'm using 4.12.0rc2.

thanks,

-arc.

Attachment: 0x869D6043.asc
Description: application/pgp-keys


reply via email to

[Prev in Thread] Current Thread [Next in Thread]