Once an interface has been created, the object code defining those functions (and indeed any variables) must be made available to LispWorks.
LispWorks for Windows can load Windows Dynamic Link Libraries (
.DLL
files).
LispWorks for Linux can load shared libraries (typically
.so
files).
LispWorks for Macintosh can load Mach-O dynamically-linked shared libraries (typically
.dylib
files).
LispWorks for UNIX can either load object files (usually suffixed with "
.o
") directly into the Lisp image, extract any required object files from the available archive libraries (usually suffixed with "
.a
"), or load in shared libraries (usually suffixed with "
.so
").
Throughout this manual we shall refer to these dynamic libraries as DLLs.
On all platforms the function register-module is the LispWorks interface to DLL files. It is used to specify which DLLs are looked up when searching for foreign symbols. Here are example forms to register a connection to a DLL.
(fli:register-module
"
MYDLL.DLL
"
)
(fli:register-module
"
mylib.so
"
)
(fli:register-module
"
mylib.dylib
"
)
Note: LispWorks for UNIX 5.0 also provides the loader function
link-load:read-foreign-modules
familiar to users of LispWorks 4.3 and earlier. However, this is now deprecated in favor of register-module.