Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

load a dynamic library from elisp

Tags:

emacs

elisp

I need to use some native code and I would like to try elisp as a scripting language. Is it possible to call native functions which are implemented in dynamic library (dll in windows)? Or the only possibility to do it is to implement native code, wrap it with DEFUN (...) macros and recompile emacs?

like image 838
Oleg Pavliv Avatar asked Feb 13 '09 08:02

Oleg Pavliv


1 Answers

You can not dynamically load a library with Emacs Lisp code. To work around this people usually call out to an external program (process) and control it by sending commands to it and reading its output.

You can look at slime, tramp, gnuserv, movemail and some other similar hacks for examples.

like image 70
kmkaplan Avatar answered Sep 19 '22 13:09

kmkaplan