Hello, Mike Gran <[EMAIL PROTECTED]> writes:
> Idea 1 was to wrap as library_init() as a scheme function that gets > called when the scheme module is loaded, and then wrap library_end() > as a scheme function that gets called when the module is unloaded. > But, modules are never unloaded. Yeah, that detail was the fun part of my proposal. :-) > Idea 4: So ultimately I went with this. The C function library_init() > gets called in init_foo() in the call to (load-extension "libfoo.so" > "init_foo"). The C function library_end() gets registered using the > libc atexit() during the same call to init_foo(). That works fine. Indeed, couldn't be any simpler. Thanks, Ludo'.