Hacker News new | ask | show | jobs
by dleslie 3561 days ago
Emacs being able to load shared/dynamic libraries is huge; it means we'll be able to load so files from a user's home directory, or the standard lib paths, and use foreign functions to extend Emacs. And with XWidgets...

Well, now you could write an OpenGL game that uses an OpenAL audio layer and displays in an Emacs frame, all in elisp. Because, why not?

2 comments

Interesting, I wrote such an emacs FFI about 15 years ago, but RMS was fundamentally opposed to it. Gtk-emacs was then based on a smaller scale FFI, but a more generic exposed FFI was still devilish. I wanted to use a proper AutoLISP environment then.
Since the dynlib support probably uses GPL3 headers and runtime symbols, I doubt the result can be licensed anything but GPL3, so I'm not sure what RMS would complain about. This is also the reason why LLVM's ld.gold support is a plugin IIRC, because it has to include a binutils header (/usr/include/plugin-api.h, which is weirdly generic name for such a thing to exist in /usr/include).
I don't remember any discussion of that 15 years ago, but there's a difference between some sort of general FFI and loadable modules of this sort that rms rejected on Moglen's legal advice. (Disappointingly, as the design was intended to make the copyright situation clear in a legal case.)

I don't know why the 2002 implementation was reimplemented (without credit and apparently without understanding it properly).

Actually, it turns out that what's there now is something totally different than what was trumpeted a while back, i.e. not like the original implementation.
RMS is no longer a maintainer of GNU Emacs.
Which has been a boon; Emacs 24 and 25 have moved at an incredible pace.
And he wasn't 15 years ago. He also didn't provide legal advice.
"Why not?" might involve not understanding what that sort of thing is likely to involve. That's not the sort of thing the original version of the feature was intended for, that this appeared to have copied when I last knew, and it didn't make extending Emacs any easier.