[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Freetalk-dev] Possible freetalk plugins
From: |
Anand Babu |
Subject: |
Re: [Freetalk-dev] Possible freetalk plugins |
Date: |
Sun, 27 Aug 2006 22:58:15 -0700 |
User-agent: |
GNU/Emacs/Mutt |
On Sun, Aug 27, 2006 at 05:13:01PM +0200, Matthias Quasthoff wrote:
,----
| the freetalk extension stuff seems to allow for communication with
| other processes. I think only one new primitive like
| > (ft-load-plugin "freetalk-some-plugin.so")
| would be required. It would load the shared object and call
| something like ft_plugin_init() which then would introduce some new
| primitives and hooks. The freetalk-some-plugin.so would basically be
| some kind of interface to a service like galago or systray or
| something. The connection of the freetalk side and the plugin side
| would happen inside a new extension, freetalk-some-plugin.scm
|
| The advantage of this approach is that it would not introduce any
| new dependencies on freetalk. The same plugins could even be used
| for freetalk-loudmouth, freetalk-jingle, freehoo.
|
| What do you think?
| Matthias
`----
You can entirely do this in Scheme.
If you want to implement an extension that has some parts to be
written in C, you can do like this
(load-extension "libsystray" "init_systray")
or like this
(define libc-obj (dynamic-link "libc.so"))
(dynamic-args-call 'rand libc-obj '())
(dynamic-unlink libc-obj)
Happy Hacking,
--
Anand Babu
GPG Key ID: 0x62E15A31
Blog [http://ab.freeshell.org]
The GNU Operating System [http://www.gnu.org]