chicken-users
[Top][All Lists]
Advanced

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

How to solve this import in an eval problem?


From: Matt Welland
Subject: How to solve this import in an eval problem?
Date: Mon, 11 Nov 2019 22:43:44 -0700

I'm working toward porting my various projects to chicken 5 and for one project I first want to convert a bunch of compilation units to modules. This has mostly gone well but I'm stuck on exposing module code in an eval. Without modules this worked great as everything was visible to the eval.

It actually works ok if I run in the directory where the .import.scm file lives but fails when the exe is run from a different directory.

I put together a testcase:

https://www.kiatoa.com/cgi-bin/fossils/megatest/uv/configf-testing.tar.gz

run make and then ./c in the directory where it was compiled and it works. Run from another directory and the module "a" is not found.
=============example============
mkdir tmp;cd tmp
../c
Can I run stuff from module "a":
/var/tmp

Run the non-modularized version

Error: (import) during expansion of (import ...) - cannot import from undefined module: a
...
==========end example===========
Thanks in advance for any help.
--
--
Complexity is your enemy. Any fool can make something complicated.
It is hard to keep things simple. - Richard Branson.

reply via email to

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