Subject: [clisp-list] dynamic loading of shared libraries/objects: delayed by known mod ule bug

From: "Hoehle, Joerg-Cyril" <[email-masked]>
Date: Thu Apr 4 06:20:20 2002

Hi,

> > and the dynamic CLISP FFI should also be doable. (truly a shame)
> It could be here by the end of the day...

A preliminary version is done (in 6KB of code).

However, I'm hitting the module__inittab... bug reported by Peter Wood,
for module__dynload__subr_tab_initdata[] this time, and it doesn't
seem to be a package issue this time.

...\src\clisp-2.28\src>lispd.exe -M lispinit.mem
*** - The value of *TERMINAL-IO* was not a stream: #<CLOSED TERMINAL-STREAM>. It has been changed to #<IO TERMINAL-STREAM>.
+ crash about #xfffffff8

...\src\clisp-2.28\src>lispd.exe
WARNING: No initialization file specified.
Please try: lispd.exe -M lispinit.mem

> (ffi::foreign-library 1 2)
*** - FFI::FOREIGN-LIBRARY: argument 1 is not a string
1. Break> (ffi::foreign-library "zlib.dll")
#<FOREIGN-POINTER #x10000000>
1. Break> (setq fz *)
#<FOREIGN-POINTER #x10000000>
1. Break> (ffi::foreign-library "foo.dll")
*** - FOREIGN-LIBRARY: cannot open "foo.dll"
2. Break> :a
:A
2. Break> (ffi::resolve-foreign-name "compress" fz)
#<FOREIGN-ADDRESS #x100018F0>
2. Break> (setq fc *)
#<FOREIGN-ADDRESS #x100018F0>
2. Break> (ffi::resolve-foreign-name "bar" fz)
*** - FFI::RESOLVE-FOREIGN-NAME: cannot locate "bar" in foreign library
3. Break> ^Z
[error.d:304] cannot handle the fatal error due to a fatal error in the fatal error handler!

Hmm...
	Jorg Hohle